mirror of
https://github.com/kubernetes-sigs/kubespray.git
synced 2025-12-15 22:34:21 +03:00
Refactor etcd role
- Run docker run from script rather than directly from systemd target - Refactoring styling/templates Signed-off-by: Sergii Golovatiuk <sgolovatiuk@mirantis.com>
This commit is contained in:
@@ -30,14 +30,20 @@
|
||||
mode: 0600
|
||||
|
||||
- name: Backup etcd v2 data
|
||||
command: "{{ bin_dir }}/etcdctl backup --data-dir {{ etcd_data_dir }} --backup-dir {{ etcd_backup_directory }}"
|
||||
command: >-
|
||||
{{ bin_dir }}/etcdctl backup
|
||||
--data-dir {{ etcd_data_dir }}
|
||||
--backup-dir {{ etcd_backup_directory }}
|
||||
environment:
|
||||
ETCDCTL_API: 2
|
||||
retries: 3
|
||||
delay: "{{ retry_stagger | random + 3 }}"
|
||||
|
||||
- name: Backup etcd v3 data
|
||||
command: "{{ bin_dir }}/etcdctl --endpoints={{ etcd_access_addresses }} snapshot save {{ etcd_backup_directory }}/snapshot.db"
|
||||
command: >-
|
||||
{{ bin_dir }}/etcdctl
|
||||
--endpoints={{ etcd_access_addresses }}
|
||||
snapshot save {{ etcd_backup_directory }}/snapshot.db
|
||||
environment:
|
||||
ETCDCTL_API: 3
|
||||
retries: 3
|
||||
|
||||
Reference in New Issue
Block a user