diff options
author | Kenny Woodson <kwoodson@redhat.com> | 2017-08-24 22:13:07 -0400 |
---|---|---|
committer | Kenny Woodson <kwoodson@redhat.com> | 2017-09-07 11:23:24 -0400 |
commit | 63ecca817c45242f3db0495d99b947ba0471789e (patch) | |
tree | bc79709891115ed9a1c4e2ecbafa63b71a487714 /playbooks/aws/openshift-cluster/provision.yml | |
parent | 6da235f41a31776b1bc253a34dc14a30307e331e (diff) | |
download | openshift-63ecca817c45242f3db0495d99b947ba0471789e.tar.gz openshift-63ecca817c45242f3db0495d99b947ba0471789e.tar.bz2 openshift-63ecca817c45242f3db0495d99b947ba0471789e.tar.xz openshift-63ecca817c45242f3db0495d99b947ba0471789e.zip |
Fixing variables and allowing custom ami.
Diffstat (limited to 'playbooks/aws/openshift-cluster/provision.yml')
-rw-r--r-- | playbooks/aws/openshift-cluster/provision.yml | 49 |
1 files changed, 28 insertions, 21 deletions
diff --git a/playbooks/aws/openshift-cluster/provision.yml b/playbooks/aws/openshift-cluster/provision.yml index dfbf61cc7..88ab0ecb1 100644 --- a/playbooks/aws/openshift-cluster/provision.yml +++ b/playbooks/aws/openshift-cluster/provision.yml @@ -16,6 +16,27 @@ r_openshift_aws_vpc_tags: "{{ provision.vpc.tags }}" r_openshift_aws_vpc_name: "{{ provision.vpc.name | default(provision.clusterid) }}" + - name: bring iam_cert23 into scope + include_role: + name: lib_utils + + - name: upload certificates to AWS IAM + iam_cert23: + state: present + name: "{{ provision.clusterid }}-master-external" + cert: "{{ provision.iam_cert_ca.cert_path }}" + key: "{{ provision.iam_cert_ca.key_path }}" + cert_chain: "{{ provision.iam_cert_ca.chain_path | default(omit) }}" + register: elb_cert_chain + failed_when: + - "'failed' in elb_cert_chain" + - elb_cert_chain.failed + - "'msg' in elb_cert_chain" + - "'already exists' not in elb_cert_chain.msg" + when: provision.iam_cert_ca is defined + + - debug: var=elb_cert_chain + - name: create aws ssh keypair include_role: name: openshift_aws_ssh_keys @@ -36,6 +57,13 @@ include: build_node_group.yml vars: openshift_build_node_type: master + openshift_clusterid: "{{ provision.clusterid }}" + openshift_region: "{{ provision.region }}" + openshift_use_custom_ami: "{{ provision.use_custom_ami }}" + openshift_ami_name: "{{ provision.build.ami_name }}" + openshift_ami_tags: "{{ provision.build.ami_tags }}" + openshift_node_group_config: "{{ provision.node_group_config }}" + openshift_subnet_name: "{{ provision.vpc.subnets[provision.region][0].az }}" - name: fetch new master instances ec2_remote_facts: @@ -49,27 +77,6 @@ delay: 3 until: instancesout.instances|length > 0 - - name: bring iam_cert23 into scope - include_role: - name: lib_utils - - - name: upload certificates to AWS IAM - iam_cert23: - state: present - name: "{{ provision.clusterid }}-master-external" - cert: "{{ provision.iam_cert_ca.cert_path }}" - key: "{{ provision.iam_cert_ca.key_path }}" - cert_chain: "{{ provision.iam_cert_ca.chain_path | default(omit) }}" - register: elb_cert_chain - failed_when: - - "'failed' in elb_cert_chain" - - elb_cert_chain.failed - - "'msg' in elb_cert_chain" - - "'already exists' not in elb_cert_chain.msg" - when: provision.iam_cert_ca is defined - - - debug: var=elb_cert_chain - - name: create our master external and internal load balancers include_role: name: openshift_aws_elb |