diff options
author | Paul Sherwood <paul.sherwood@codethink.co.uk> | 2016-02-10 20:35:00 +0000 |
---|---|---|
committer | Paul Sherwood <paul.sherwood@codethink.co.uk> | 2016-02-10 20:35:00 +0000 |
commit | e970fd17f7fb086079003282ef8a3799a8fd789c (patch) | |
tree | 0a6216afd6daa724b39e4748967dea767de39e10 | |
parent | b89174aaa5b5a6f3a3d569639fd28eb82a26e8c2 (diff) | |
download | ybd-e970fd17f7fb086079003282ef8a3799a8fd789c.tar.gz |
Pep8
-rwxr-xr-x | kbas/__main__.py | 2 | ||||
-rwxr-xr-x | ybd/__main__.py | 1 | ||||
-rw-r--r-- | ybd/cache.py | 2 | ||||
-rw-r--r-- | ybd/deployment.py | 7 |
4 files changed, 6 insertions, 6 deletions
diff --git a/kbas/__main__.py b/kbas/__main__.py index 7ffca44..1926f29 100755 --- a/kbas/__main__.py +++ b/kbas/__main__.py @@ -123,7 +123,7 @@ class KeyedBinaryArtifactServer(object): cache_id = request.forms.get('filename') if os.path.isdir(os.path.join(app.config['artifact-dir'], cache_id)): if cache.check(cache_id) == request.forms.get('checksum', 'XYZ'): - response.status = 777 # this is the same binary we have + response.status = 777 # this is the same binary we have return response.status = 405 # method not allowed, this artifact exists return diff --git a/ybd/__main__.py b/ybd/__main__.py index 6fe3977..5f283d7 100755 --- a/ybd/__main__.py +++ b/ybd/__main__.py @@ -83,7 +83,6 @@ with app.timer('TOTAL'): app.log('REPRODUCED', 'Reproduced %s of' % app.config['reproduced'], app.config['tasks']) - if target.get('kind') == 'cluster' and app.config.get('fork') is None: with app.timer(target, 'cluster deployment'): deploy(defs, target) diff --git a/ybd/cache.py b/ybd/cache.py index f6caaa5..c54cb98 100644 --- a/ybd/cache.py +++ b/ybd/cache.py @@ -281,7 +281,7 @@ def cull(artifact_dir): def check(artifact): try: artifact = os.path.join(app.config['artifact-dir'], artifact, - artifact) + artifact) checkfile = artifact + '.md5' if not os.path.exists(checkfile): checksum = md5(artifact) diff --git a/ybd/deployment.py b/ybd/deployment.py index 277a403..71704ef 100644 --- a/ybd/deployment.py +++ b/ybd/deployment.py @@ -47,7 +47,8 @@ def deploy_system(defs, system_spec, parent_location=''): with sandbox.setup(system): app.log(system, 'Extracting system artifact into', system['sandbox']) with open(cache.get_cache(defs, system), 'r') as artifact: - call(['tar', 'x', '--directory', system['sandbox']], stdin=artifact) + call(['tar', 'x', '--directory', system['sandbox']], + stdin=artifact) for subsystem in system_spec.get('subsystems', []): if deploy_defaults: @@ -64,7 +65,7 @@ def deploy_system(defs, system_spec, parent_location=''): location = deployment.get('location') or \ deployment.get('upgrade-location') deployment['location'] = os.path.join(parent_location, - location.lstrip('/')) + location.lstrip('/')) try: sandbox.run_extension(system, deployment, 'check', method) except KeyError: @@ -72,7 +73,7 @@ def deploy_system(defs, system_spec, parent_location=''): for ext in system.get('configuration-extensions', []): sandbox.run_extension(system, deployment, 'configure', - os.path.basename(ext)) + os.path.basename(ext)) os.chmod(system['sandbox'], 0o755) sandbox.run_extension(system, deployment, 'write', method) |