From 7fc4b1cb35d6f0e160e98571e5a0e590c3ac6b26 Mon Sep 17 00:00:00 2001 From: David Baker Date: Fri, 16 Sep 2016 18:26:46 +0100 Subject: [PATCH] Actually ad the arg to argparse --- deploy/redeploy.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/deploy/redeploy.py b/deploy/redeploy.py index 95ef31dd21..2839422bde 100755 --- a/deploy/redeploy.py +++ b/deploy/redeploy.py @@ -122,7 +122,8 @@ def on_receive_jenkins_poke(): create_symlink(source=os.path.join(untar_location, "vector"), linkname=arg_symlink) - create_symlink(source=arg_config_location, linkname=os.path.join(untar_location, "vector", 'config.json')) + if arg_config_location: + create_symlink(source=arg_config_location, linkname=os.path.join(untar_location, "vector", 'config.json')) return jsonify({}) @@ -156,6 +157,12 @@ if __name__ == "__main__": to the /vector directory INSIDE the tarball." ) ) + parser.add_argument( + "--config", dest="config", help=( + "Write a symlink to config.json in the extracted tarball. \ + To this location." + ) + ) args = parser.parse_args() if args.jenkins.endswith("/"): # important for urljoin arg_jenkins_url = args.jenkins