From bed59cec5e5a9a5668cf2c7df3a24545b1e76c09 Mon Sep 17 00:00:00 2001 From: Łukasz Gardoń Date: Tue, 8 Aug 2017 10:18:11 +0200 Subject: Add option '--no-cert-checks' for 'upload' sub command. This option allow to bypass verification ssl certification while establishing connection with Gerrit to upload review. Change-Id: If2e15f5a273c18a700eb5093ca8a4d5a4cbf80cd --- subcmds/upload.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'subcmds/upload.py') diff --git a/subcmds/upload.py b/subcmds/upload.py index 61b18bc2..60feff7a 100644 --- a/subcmds/upload.py +++ b/subcmds/upload.py @@ -181,6 +181,9 @@ Gerrit Code Review: http://code.google.com/p/gerrit/ # Never run upload hooks, but upload anyway (AKA bypass hooks). # - no-verify=True, verify=True: # Invalid + p.add_option('--no-cert-checks', + dest='validate_certs', action='store_false', default=True, + help='Disable verifying ssl certs (unsafe).') p.add_option('--no-verify', dest='bypass_hooks', action='store_true', help='Do not run the upload hook.') @@ -389,7 +392,9 @@ Gerrit Code Review: http://code.google.com/p/gerrit/ draft=opt.draft, private=opt.private, wip=opt.wip, - dest_branch=destination) + dest_branch=destination, + validate_certs=opt.validate_certs) + branch.uploaded = True except UploadError as e: branch.error = e -- cgit v1.2.3-54-g00ecf