You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

37 lines
763 B

  1. ---
  2. - name: restart etcd
  3. command: /bin/true
  4. notify:
  5. - etcd | reload systemd
  6. - reload etcd
  7. - wait for etcd up
  8. - name: restart etcd-proxy
  9. command: /bin/true
  10. notify:
  11. - etcd | reload systemd
  12. - reload etcd-proxy
  13. - wait for etcd up
  14. - name: etcd | reload systemd
  15. command: systemctl daemon-reload
  16. when: ansible_service_mgr == "systemd"
  17. - name: wait for etcd up
  18. uri: url="http://{% if is_etcd_master %}{{ etcd_address }}{% else %}127.0.0.1{% endif %}:2379/health"
  19. register: result
  20. until: result.status == 200
  21. retries: 10
  22. delay: 5
  23. - name: reload etcd
  24. service:
  25. name: etcd
  26. state: restarted
  27. when: is_etcd_master
  28. - name: reload etcd-proxy
  29. service:
  30. name: etcd-proxy
  31. state: restarted
  32. when: is_etcd_proxy