summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCédric Bosdonnat <cbosdonnat@suse.com>2017-04-14 16:17:17 +0200
committerCédric Bosdonnat <cbosdonnat@suse.com>2017-04-14 16:17:17 +0200
commit0208ee3a87ea3bc2be408420b1efa8c223885cb4 (patch)
treec748f0a7d88804864ba056f411e41d6dd5699a0b
parent7343816a5c6de7e54bfa21317239af4380c792b4 (diff)
downloadvirt-bootstrap.git-0208ee3a87ea3bc2be408420b1efa8c223885cb4.tar.gz
virt-bootstrap.git-0208ee3a87ea3bc2be408420b1efa8c223885cb4.tar.xz
virt-bootstrap.git-0208ee3a87ea3bc2be408420b1efa8c223885cb4.zip
File source fixes
-rw-r--r--sources.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/sources.py b/sources.py
index a7f1eb0..a799e09 100644
--- a/sources.py
+++ b/sources.py
@@ -39,14 +39,14 @@ def checksum(path, sum_type, sum_expected):
class FileSource:
- def __init__(self, url, insecure):
+ def __init__(self, url, username, password, insecure):
self.path = url.path
- def unpack(dest):
+ def unpack(self, dest):
# We assume tar is intelligent enough to find out
# the compression type to use and to strip leading '/',
# not sure if this is safe enough
- subprocess.check_call(["tar", "-C", dest, "xf", self.path])
+ subprocess.check_call(["tar", "xf", self.path, "-C", dest])
class DockerSource:
def __init__(self, url, username, password, insecure):