summaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authorAndrew Butcher <abutcher@afrolegs.com>2016-09-26 14:20:13 -0400
committerGitHub <noreply@github.com>2016-09-26 14:20:13 -0400
commitf7ba21be241e9a3f3354b44332611fe5095fc57f (patch)
tree4f981163b3b792d2af3de610e66f4eac2a65f1f9 /bin
parentb7aaf7bd860625a1dc929a2397c28c3e33aab94f (diff)
parent1f2276fff1e41c1d9440ee8b589042ee249b95d7 (diff)
downloadopenshift-f7ba21be241e9a3f3354b44332611fe5095fc57f.tar.gz
openshift-f7ba21be241e9a3f3354b44332611fe5095fc57f.tar.bz2
openshift-f7ba21be241e9a3f3354b44332611fe5095fc57f.tar.xz
openshift-f7ba21be241e9a3f3354b44332611fe5095fc57f.zip
Merge pull request #2501 from lhuard1A/fix_openstack_cloudprovider
Fix openstack cloudprovider
Diffstat (limited to 'bin')
-rwxr-xr-xbin/cluster11
1 files changed, 11 insertions, 0 deletions
diff --git a/bin/cluster b/bin/cluster
index 080bf244a..92174954f 100755
--- a/bin/cluster
+++ b/bin/cluster
@@ -68,6 +68,15 @@ class Cluster(object):
cluster['num_etcd'] = args.etcd
cluster['cluster_env'] = args.env
+ if args.cloudprovider and args.provider == 'openstack':
+ cluster['openshift_cloudprovider_kind'] = 'openstack'
+ cluster['openshift_cloudprovider_openstack_auth_url'] = os.getenv('OS_AUTH_URL')
+ cluster['openshift_cloudprovider_openstack_username'] = os.getenv('OS_USERNAME')
+ cluster['openshift_cloudprovider_openstack_password'] = os.getenv('OS_PASSWORD')
+ cluster['openshift_cloudprovider_openstack_tenant_id'] = os.getenv('OS_PROJECT_ID',os.getenv('OS_TENANT_ID'))
+ cluster['openshift_cloudprovider_openstack_tenant_name'] = os.getenv('OS_PROJECT_NAME',os.getenv('OS_TENANT_NAME'))
+ cluster['openshift_cloudprovider_openstack_region'] = os.getenv('OS_REGION_NAME')
+
self.action(args, inventory, cluster, playbook)
def add_nodes(self, args):
@@ -332,6 +341,8 @@ This wrapper is overriding the following ansible variables:
create_parser = action_parser.add_parser('create', help='Create a cluster',
parents=[meta_parser])
+ create_parser.add_argument('-c', '--cloudprovider', action='store_true',
+ help='Enable the cloudprovider')
create_parser.add_argument('-m', '--masters', default=1, type=int,
help='number of masters to create in cluster')
create_parser.add_argument('-n', '--nodes', default=2, type=int,