init.yml 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. ---
  2. - include: ../verify_ansible_version.yml
  3. - hosts: localhost
  4. connection: local
  5. become: no
  6. gather_facts: no
  7. tasks:
  8. - include_vars: ../../../byo/openshift-cluster/cluster_hosts.yml
  9. - add_host:
  10. name: "{{ item }}"
  11. groups: l_oo_all_hosts
  12. with_items: g_all_hosts | default([])
  13. - hosts: l_oo_all_hosts
  14. gather_facts: no
  15. tasks:
  16. - include_vars: ../../../byo/openshift-cluster/cluster_hosts.yml
  17. - include: ../evaluate_groups.yml
  18. vars:
  19. # Do not allow adding hosts during upgrade.
  20. g_new_master_hosts: []
  21. g_new_node_hosts: []
  22. openshift_cluster_id: "{{ cluster_id | default('default') }}"
  23. openshift_deployment_type: "{{ deployment_type }}"
  24. - name: Set oo_options
  25. hosts: oo_all_hosts
  26. tasks:
  27. - set_fact:
  28. openshift_docker_additional_registries: "{{ lookup('oo_option', 'docker_additional_registries') }}"
  29. when: openshift_docker_additional_registries is not defined
  30. - set_fact:
  31. openshift_docker_insecure_registries: "{{ lookup('oo_option', 'docker_insecure_registries') }}"
  32. when: openshift_docker_insecure_registries is not defined
  33. - set_fact:
  34. openshift_docker_blocked_registries: "{{ lookup('oo_option', 'docker_blocked_registries') }}"
  35. when: openshift_docker_blocked_registries is not defined
  36. - set_fact:
  37. openshift_docker_options: "{{ lookup('oo_option', 'docker_options') }}"
  38. when: openshift_docker_options is not defined
  39. - set_fact:
  40. openshift_docker_log_driver: "{{ lookup('oo_option', 'docker_log_driver') }}"
  41. when: openshift_docker_log_driver is not defined
  42. - set_fact:
  43. openshift_docker_log_options: "{{ lookup('oo_option', 'docker_log_options') }}"
  44. when: openshift_docker_log_options is not defined
  45. - include: ../initialize_facts.yml