summaryrefslogtreecommitdiffstats
path: root/playbooks/openshift-node/scaleup.yml
blob: cc03b72a2af5a708c263bbe1b6c534efb15d8b71 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
---
- import_playbook: ../init/evaluate_groups.yml

- name: Ensure there are new_nodes
  hosts: localhost
  connection: local
  gather_facts: no
  tasks:
  - fail:
      msg: >
        Detected no new_nodes in inventory. Please add hosts to the
        new_nodes host group to add nodes.
    when:
    - g_new_node_hosts | default([]) | length == 0

# if g_new_node_hosts is not empty, oo_nodes_to_config will be set to
# g_new_node_hosts via evaluate_groups.yml

- import_playbook: ../prerequisites.yml
  vars:
    l_scale_up_hosts: "oo_nodes_to_config"
    l_init_fact_hosts: "oo_masters_to_config:oo_etcd_to_config:oo_lb_to_config:oo_nodes_to_config"
    l_sanity_check_hosts: "{{ groups['oo_nodes_to_config'] | union(groups['oo_masters_to_config']) }}"

- import_playbook: ../init/version.yml
  vars:
    l_openshift_version_set_hosts: "oo_nodes_to_config:!oo_first_master"
    l_openshift_version_check_hosts: "oo_nodes_to_config"

- import_playbook: private/config.yml