From 6d688f4377b4a43a6ce0b77f0fac244cc487a96a Mon Sep 17 00:00:00 2001 From: Fabien Boucher Date: Jan 30 2020 15:27:02 +0000 Subject: align gating options --- diff --git a/tools/project-settings-helper/helper.py b/tools/project-settings-helper/helper.py index 0c05fe9..e442ab8 100755 --- a/tools/project-settings-helper/helper.py +++ b/tools/project-settings-helper/helper.py @@ -85,7 +85,6 @@ def set_zuul_settings(client, project, gating, host): config = client.get_config(project) config['Web-hooks'] = BASE_WH_URL % host config['pull_requests'] = True - config['notify_on_pull-request_flag'] = True if gating: config['Minimum_score_to_merge_pull-request'] = 0 config['open_metadata_access_to_all'] = False @@ -96,13 +95,14 @@ def set_zuul_settings(client, project, gating, host): config[k] = 1 if v else 0 client.set_config(project, config) logging.debug("Applying new setting set on %s" % project) - acls = { - 'user_type': 'user', - 'name': 'zuul', - 'acl': 'commit' - } - client.set_acl(project, acls) - logging.debug("Adding zuul user as admin on %s" % project) + if gating: + acls = { + 'user_type': 'user', + 'name': 'zuul', + 'acl': 'commit' + } + client.set_acl(project, acls) + logging.debug("Adding zuul user as admin on %s" % project) def process(client, projects, gating, host):