restart.yml 837 B

123456789101112131415161718192021222324252627
  1. ---
  2. - name: Restart docker
  3. service: name=docker state=restarted
  4. register: l_docker_restart_docker_in_upgrade_result
  5. until: not l_docker_restart_docker_in_upgrade_result | failed
  6. retries: 3
  7. delay: 30
  8. - name: Restart containerized services
  9. service: name={{ item }} state=started
  10. with_items:
  11. - etcd_container
  12. - openvswitch
  13. - "{{ openshift.common.service_type }}-master-api"
  14. - "{{ openshift.common.service_type }}-master-controllers"
  15. - "{{ openshift.common.service_type }}-node"
  16. failed_when: false
  17. when: openshift.common.is_containerized | bool
  18. - name: Wait for master API to come back online
  19. wait_for:
  20. host: "{{ openshift.common.hostname }}"
  21. state: started
  22. delay: 10
  23. port: "{{ openshift.master.api_port }}"
  24. timeout: 600
  25. when: inventory_hostname in groups.oo_masters_to_config