summaryrefslogtreecommitdiffstats
path: root/playbooks/openstack
diff options
context:
space:
mode:
authorWesley Hearn <whearn@redhat.com>2015-07-20 16:20:12 -0400
committerWesley Hearn <whearn@redhat.com>2015-07-23 11:30:48 -0400
commitc4cca1d7184ae859706b5854a04f18095c12f1d6 (patch)
treed0637086194fcc303226ff7d3f98684c8d427a44 /playbooks/openstack
parent0cbeae4df062af3e2c1a4cb08ef3b4e742394ed6 (diff)
downloadopenshift-c4cca1d7184ae859706b5854a04f18095c12f1d6.tar.gz
openshift-c4cca1d7184ae859706b5854a04f18095c12f1d6.tar.bz2
openshift-c4cca1d7184ae859706b5854a04f18095c12f1d6.tar.xz
openshift-c4cca1d7184ae859706b5854a04f18095c12f1d6.zip
Infra node support
Diffstat (limited to 'playbooks/openstack')
-rw-r--r--playbooks/openstack/openshift-cluster/launch.yml22
-rw-r--r--playbooks/openstack/openshift-cluster/vars.yml1
2 files changed, 21 insertions, 2 deletions
diff --git a/playbooks/openstack/openshift-cluster/launch.yml b/playbooks/openstack/openshift-cluster/launch.yml
index 3cdd2ae4d..d41448dc0 100644
--- a/playbooks/openstack/openshift-cluster/launch.yml
+++ b/playbooks/openstack/openshift-cluster/launch.yml
@@ -27,10 +27,13 @@
-P ssh_incoming={{ openstack_ssh_access_from }}
-P num_masters={{ num_masters }}
-P num_nodes={{ num_nodes }}
+ -P num_infra={{ num_infra }}
-P master_image={{ deployment_vars[deployment_type].image }}
-P node_image={{ deployment_vars[deployment_type].image }}
+ -P infra_image={{ deployment_vars[deployment_type].image }}
-P master_flavor={{ openstack_flavor["master"] }}
-P node_flavor={{ openstack_flavor["node"] }}
+ -P infra_flavor={{ openstack_flavor["infra"] }}
-P ssh_public_key="{{ openstack_ssh_public_key }}"
openshift-ansible-{{ cluster_id }}-stack'
when: stack_show_result.rc == 1
@@ -43,10 +46,13 @@
-P ssh_incoming={{ openstack_ssh_access_from }}
-P num_masters={{ num_masters }}
-P num_nodes={{ num_nodes }}
+ -P num_infra={{ num_infra }}
-P master_image={{ deployment_vars[deployment_type].image }}
-P node_image={{ deployment_vars[deployment_type].image }}
+ -P infra_image={{ deployment_vars[deployment_type].image }}
-P master_flavor={{ openstack_flavor["master"] }}
-P node_flavor={{ openstack_flavor["node"] }}
+ -P infra_flavor={{ openstack_flavor["infra"] }}
-P ssh_public_key="{{ openstack_ssh_public_key }}"
openshift-ansible-{{ cluster_id }}-stack'
when: stack_show_result.rc == 0
@@ -72,7 +78,7 @@
ansible_ssh_host: '{{ item[2] }}'
ansible_ssh_user: "{{ deployment_vars[deployment_type].ssh_user }}"
ansible_sudo: "{{ deployment_vars[deployment_type].sudo }}"
- groups: 'tag_env_{{ cluster_id }}, tag_host-type_master, tag_env-host-type_{{ cluster_id }}-openshift-master'
+ groups: 'tag_env_{{ cluster_id }}, tag_host-type_master, tag_env-host-type_{{ cluster_id }}-openshift-master, tag_sub-host-type_default'
with_together:
- parsed_outputs.master_names
- parsed_outputs.master_ips
@@ -84,12 +90,24 @@
ansible_ssh_host: '{{ item[2] }}'
ansible_ssh_user: "{{ deployment_vars[deployment_type].ssh_user }}"
ansible_sudo: "{{ deployment_vars[deployment_type].sudo }}"
- groups: 'tag_env_{{ cluster_id }}, tag_host-type_node, tag_env-host-type_{{ cluster_id }}-openshift-node'
+ groups: 'tag_env_{{ cluster_id }}, tag_host-type_node, tag_env-host-type_{{ cluster_id }}-openshift-node, tag_sub-host-type_node'
with_together:
- parsed_outputs.node_names
- parsed_outputs.node_ips
- parsed_outputs.node_floating_ips
+ - name: Add new infra instances groups and variables
+ add_host:
+ hostname: '{{ item[0] }}'
+ ansible_ssh_host: '{{ item[2] }}'
+ ansible_ssh_user: "{{ deployment_vars[deployment_type].ssh_user }}"
+ ansible_sudo: "{{ deployment_vars[deployment_type].sudo }}"
+ groups: 'tag_env_{{ cluster_id }}, tag_host-type_node, tag_env-host-type_{{ cluster_id }}-openshift-node, tag_sub-host-type_infra'
+ with_together:
+ - parsed_outputs.infra_names
+ - parsed_outputs.infra_ips
+ - parsed_outputs.infra_floating_ips
+
- name: Wait for ssh
wait_for:
host: '{{ item }}'
diff --git a/playbooks/openstack/openshift-cluster/vars.yml b/playbooks/openstack/openshift-cluster/vars.yml
index d077a6ced..43e25f2e6 100644
--- a/playbooks/openstack/openshift-cluster/vars.yml
+++ b/playbooks/openstack/openshift-cluster/vars.yml
@@ -19,6 +19,7 @@ openstack_ssh_access_from: "{{ lookup('oo_option', 'ssh_from') |
default('0.0.0.0/0', True) }}"
openstack_flavor:
master: "{{ lookup('oo_option', 'master_flavor' ) | default('m1.small', True) }}"
+ infra: "{{ lookup('oo_option', 'infra_flavor' ) | default('m1.small', True) }}"
node: "{{ lookup('oo_option', 'node_flavor' ) | default('m1.medium', True) }}"
deployment_vars: