12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152 |
- ---
- - name: Ensure there are new_nodes
- hosts: localhost
- connection: local
- gather_facts: no
- tasks:
- - fail:
- msg: >
- Detected no new_workers in inventory. Please add hosts to the
- new_workers host group to add nodes.
- when:
- - groups.new_workers | default([]) | length == 0
- - name: run the init
- import_playbook: ../init/main.yml
- vars:
- l_init_fact_hosts: "new_workers"
- l_openshift_version_set_hosts: "new_workers"
- l_install_base_packages: True
- l_repo_hosts: "new_workers"
- l_base_packages_hosts: "new_workers"
- - name: install nodes
- hosts: new_workers
- roles:
- - role: container_runtime
- tasks:
- - import_role:
- name: container_runtime
- tasks_from: docker_storage_setup_overlay.yml
- - import_role:
- name: container_runtime
- tasks_from: extra_storage_setup.yml
- - import_role:
- name: container_runtime
- tasks_from: package_crio.yml
- - import_role:
- name: openshift_node40
- tasks_from: install.yml
- - name: Wait for bootstrap endpoint to show up
- uri:
- url: "{{ openshift_bootstrap_endpoint }}"
- validate_certs: false
- delay: 10
- retries: 60
- register: result
- until:
- - "'status' in result"
- - result.status == 200
- - import_role:
- name: openshift_node40
- tasks_from: config.yml
|