restart.yml 917 B

1234567891011121314151617181920212223242526272829303132
  1. ---
  2. - hosts: localhost
  3. connection: local
  4. become: no
  5. gather_facts: no
  6. tasks:
  7. - include_vars: ../../byo/openshift-cluster/cluster_hosts.yml
  8. - name: Evaluate group l_oo_all_hosts
  9. add_host:
  10. name: "{{ item }}"
  11. groups: l_oo_all_hosts
  12. with_items: "{{ g_all_hosts | default([]) }}"
  13. changed_when: False
  14. - hosts: l_oo_all_hosts
  15. gather_facts: no
  16. tasks:
  17. - include_vars: ../../byo/openshift-cluster/cluster_hosts.yml
  18. - include: ../../common/openshift-cluster/evaluate_groups.yml
  19. - include: ../../common/openshift-master/validate_restart.yml
  20. - name: Restart masters
  21. hosts: oo_masters_to_config
  22. vars:
  23. openshift_master_ha: "{{ groups.oo_masters_to_config | length > 1 }}"
  24. serial: 1
  25. tasks:
  26. - include: restart_hosts.yml
  27. when: openshift.common.rolling_restart_mode == 'system'
  28. - include: restart_services.yml
  29. when: openshift.common.rolling_restart_mode == 'services'