From 422cf9cecaf7accbdd00913032123458b2d3d2db Mon Sep 17 00:00:00 2001 From: Lars Wirzenius Date: Wed, 25 Apr 2012 12:31:15 +0100 Subject: Log installed artifacts; do not log shell commands The -x to sh didn't actually produce any output to help in my debugging, so I remove it now. --- morphlib/stagingarea.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'morphlib/stagingarea.py') diff --git a/morphlib/stagingarea.py b/morphlib/stagingarea.py index 1d8b6ef1..a34daede 100644 --- a/morphlib/stagingarea.py +++ b/morphlib/stagingarea.py @@ -87,7 +87,9 @@ class StagingArea(object): the artifact is a tarball. ''' - + + logging.debug('Installing artifact %s' % + getattr(handle, 'name', 'unknown name')) tf = tarfile.open(fileobj=handle) tf.extractall(path=self.dirname) @@ -111,7 +113,7 @@ class StagingArea(object): del kwargs['cwd'] else: cwd = '/' - real_argv = ['/usr/sbin/chroot', self.dirname, 'sh', '-xc', + real_argv = ['/usr/sbin/chroot', self.dirname, 'sh', '-c', 'cd "$1" && shift && exec "$@"', '--', cwd] + argv return ex.runv(real_argv, **kwargs) -- cgit v1.2.1