X-Git-Url: https://gerrit.linuxfoundation.org/infra/gitweb?a=blobdiff_plain;f=jenkins-admin%2Fcreate_jenkins_clouds_openstack_yaml.py;h=ea92aa7cdcef6e221162e204b39a77175925cf11;hb=86f276e966e01b037d96a1a87cb6ad1fce18f7cc;hp=ae51bd8ea6bee0b4603da17dc5500ea8c5dbfb6f;hpb=33f5bf5ae760a7c815e39092a216f42ffcc42fbb;p=releng%2Fglobal-jjb.git diff --git a/jenkins-admin/create_jenkins_clouds_openstack_yaml.py b/jenkins-admin/create_jenkins_clouds_openstack_yaml.py index ae51bd8e..ea92aa7c 100755 --- a/jenkins-admin/create_jenkins_clouds_openstack_yaml.py +++ b/jenkins-admin/create_jenkins_clouds_openstack_yaml.py @@ -58,7 +58,7 @@ jenkins: credentialsId: {{ cloud_credential_id }} endPointUrl: {{ cloud_url }} ignoreSsl: {{ cloud_ignore_ssl }} - name: "cattle" + name: {{ cloud_name }} slaveOptions: availabilityZone: {{ availability_zone }} bootSource: @@ -117,6 +117,8 @@ def parse_arguments(): parser.add_argument('--path', type=dir_path, help="Path to jenkins-admin directory") + parser.add_argument('--name', type=str, + help="cloud name IE: cattle") parser.add_argument( "-s", "--sandbox", @@ -178,7 +180,9 @@ for filename in glob.iglob(path, recursive=True): # Global cloud config section for section in config_parser_merged.sections(): if section == "cloud": - final = (config.items(section)) + afinal = (config.items(section)) + name = parsed_args.name + final = (*afinal, ("cloud_name", name)) for index, _ in enumerate(final):