From c8ce7e98ec2da0bfad43272adab71a2b43df2303 Mon Sep 17 00:00:00 2001 From: Nico Schottelius Date: Thu, 8 Sep 2011 14:45:54 +0200 Subject: [PATCH] use -e to shell Signed-off-by: Nico Schottelius --- bin/cdist | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/bin/cdist b/bin/cdist index 58ddcb3f..a5902472 100755 --- a/bin/cdist +++ b/bin/cdist @@ -101,6 +101,10 @@ class Cdist: kargs['shell'] = True log.debug("Shell exec: " + " ".join(*args)) + # Fail if the script fails + args[0].insert(0,"-e") + print(args) + try: subprocess.check_call(*args, **kargs) except subprocess.CalledProcessError: @@ -219,7 +223,6 @@ if __name__ == "__main__": for host in args.host: c = Cdist(host) c.deploy_to() - print(c.list_global_explorers()) c.cleanup() except KeyboardInterrupt: sys.exit(0)