Backup etcd data before restarting etcd

etcd is crucial part of kubernetes cluster. Ansible restarts etcd on
reconfiguration. Backup helps operator to restore cluster manually in
case of any issues.

Signed-off-by: Sergii Golovatiuk <sgolovatiuk@mirantis.com>
This commit is contained in:
Sergii Golovatiuk
2017-03-16 20:38:13 +01:00
parent 859c08620b
commit c04a6254b9
2 changed files with 48 additions and 0 deletions

View File

@@ -2,10 +2,13 @@
- name: restart etcd
command: /bin/true
notify:
- Backup etcd data
- etcd | reload systemd
- reload etcd
- wait for etcd up
- include: backup.yml
- name: etcd | reload systemd
command: systemctl daemon-reload