2016-01-19 22:23:19 +08:00
|
|
|
---
|
2016-01-25 09:01:25 +08:00
|
|
|
- name: restart etcd
|
2016-01-19 22:23:19 +08:00
|
|
|
command: /bin/true
|
|
|
|
notify:
|
|
|
|
- reload systemd
|
2016-01-25 09:01:25 +08:00
|
|
|
- reload etcd
|
2016-07-19 21:45:37 +08:00
|
|
|
- wait for etcd up
|
2016-01-19 22:23:19 +08:00
|
|
|
|
2016-07-11 22:05:05 +08:00
|
|
|
- name: restart etcd-proxy
|
|
|
|
command: /bin/true
|
|
|
|
notify:
|
|
|
|
- reload systemd
|
|
|
|
- reload etcd-proxy
|
2016-07-19 21:45:37 +08:00
|
|
|
- wait for etcd up
|
2016-07-11 22:05:05 +08:00
|
|
|
|
2016-01-19 22:23:19 +08:00
|
|
|
- name: reload systemd
|
|
|
|
command: systemctl daemon-reload
|
2016-02-13 18:17:20 +08:00
|
|
|
when: ansible_service_mgr == "systemd"
|
2016-01-19 22:23:19 +08:00
|
|
|
|
2016-07-19 21:45:37 +08:00
|
|
|
- name: wait for etcd up
|
|
|
|
uri: url=http://localhost:2379/health
|
|
|
|
register: result
|
|
|
|
until: result.status == 200
|
|
|
|
retries: 10
|
|
|
|
delay: 5
|
2016-06-24 20:25:16 +08:00
|
|
|
|
2016-01-25 09:01:25 +08:00
|
|
|
- name: reload etcd
|
2016-01-19 22:23:19 +08:00
|
|
|
service:
|
|
|
|
name: etcd
|
2016-07-19 21:45:37 +08:00
|
|
|
state: restarted
|
2016-07-11 22:05:05 +08:00
|
|
|
when: is_etcd_master
|
|
|
|
|
|
|
|
- name: reload etcd-proxy
|
|
|
|
service:
|
|
|
|
name: etcd-proxy
|
2016-07-19 21:45:37 +08:00
|
|
|
state: restarted
|
2016-07-11 22:05:05 +08:00
|
|
|
when: is_etcd_proxy
|