mirror of https://github.com/easzlab/kubeasz.git
20 lines
387 B
YAML
20 lines
387 B
YAML
|
# to clean 'etcd' nodes
|
||
|
- hosts:
|
||
|
- etcd
|
||
|
- new-etcd
|
||
|
tasks:
|
||
|
- name: stop and disable etcd service
|
||
|
service:
|
||
|
name: etcd
|
||
|
state: stopped
|
||
|
enabled: no
|
||
|
ignore_errors: true
|
||
|
|
||
|
- name: remove files and dirs
|
||
|
file: name={{ item }} state=absent
|
||
|
with_items:
|
||
|
- "/var/lib/etcd"
|
||
|
- "/etc/etcd/"
|
||
|
- "/backup/k8s"
|
||
|
- "/etc/systemd/system/etcd.service"
|