summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorScott Moser <smoser@ubuntu.com>2011-03-03 17:12:27 -0500
committerScott Moser <smoser@ubuntu.com>2011-03-03 17:12:27 -0500
commit616b0b297a7383b5c77c8b886aaf62f37c2a8c95 (patch)
treeba31738fdd8ac4426bdafa015c921c1bae5f4fdd
parent26c031c125cac88eb830a835ba52a1bc97bbf3df (diff)
downloadvyos-cloud-init-616b0b297a7383b5c77c8b886aaf62f37c2a8c95.tar.gz
vyos-cloud-init-616b0b297a7383b5c77c8b886aaf62f37c2a8c95.zip
in subp, put output and stderr into the raised error
-rw-r--r--cloudinit/util.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/cloudinit/util.py b/cloudinit/util.py
index 3a40cc99..fc4233de 100644
--- a/cloudinit/util.py
+++ b/cloudinit/util.py
@@ -147,7 +147,7 @@ def subp(args, input=None):
sp = subprocess.Popen(args, stdout=subprocess.PIPE, stderr=subprocess.PIPE, stdin=s_in)
out,err = sp.communicate(input)
if sp.returncode is not 0:
- raise subprocess.CalledProcessError(sp.returncode,args)
+ raise subprocess.CalledProcessError(sp.returncode,args, (out,err))
return(out,err)
def render_to_file(template, outfile, searchList):