diff options
author | Radostin Stoyanov <rstoyanov1@gmail.com> | 2017-06-26 07:28:47 +0100 |
---|---|---|
committer | Cédric Bosdonnat <cbosdonnat@suse.com> | 2017-06-28 11:47:18 +0200 |
commit | 6903f23563549f8d81fa911103594f9f472ab3c7 (patch) | |
tree | 49b235c1eb73360a35fe4c39b88594af622ec199 /src/virtBootstrap/sources.py | |
parent | 34a25916646108454fac8dd490ae5d70eb7ce6bd (diff) | |
download | virt-bootstrap.git-6903f23563549f8d81fa911103594f9f472ab3c7.tar.gz virt-bootstrap.git-6903f23563549f8d81fa911103594f9f472ab3c7.tar.xz virt-bootstrap.git-6903f23563549f8d81fa911103594f9f472ab3c7.zip |
Improve logging of virt-sandbox
Diffstat (limited to 'src/virtBootstrap/sources.py')
-rw-r--r-- | src/virtBootstrap/sources.py | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/virtBootstrap/sources.py b/src/virtBootstrap/sources.py index 6e54a96..2d910fc 100644 --- a/src/virtBootstrap/sources.py +++ b/src/virtBootstrap/sources.py @@ -27,7 +27,7 @@ import tempfile import getpass import os import logging -from subprocess import call, CalledProcessError, PIPE, Popen +from subprocess import CalledProcessError, PIPE, Popen # Default virtual size of qcow2 image DEF_QCOW2_SIZE = '5G' @@ -86,9 +86,7 @@ def safe_untar(src, dest): # Compression type is auto detected from tar # Exclude files under /dev to avoid "Cannot mknod: Operation not permitted" params = ['--', '/bin/tar', 'xf', src, '-C', '/mnt', '--exclude', 'dev/*'] - if call(virt_sandbox + params) != 0: - logging.error(_('virt-sandbox exit with non-zero code. ' - 'Please check if "libvirtd" is running.')) + execute(virt_sandbox + params) def get_layer_info(digest, image_dir): |