0500f27db8
* Set ETCD_INITIAL_CLUSTER_STATE from `new` to `existing`, because parameter `new` makes sense only on cluster assembly stage. * If cluster exists and current node is not a part of the cluster, add it with command `etcdctl add member name url`. Closes kubespray/kargo/#270
26 lines
603 B
YAML
26 lines
603 B
YAML
---
|
|
- include: set_facts.yml
|
|
- include: install.yml
|
|
- include: set_cluster_health.yml
|
|
- include: configure.yml
|
|
- include: refresh_config.yml
|
|
|
|
- name: Restart etcd if binary changed
|
|
command: /bin/true
|
|
notify: restart etcd
|
|
when: etcd_copy.stdout_lines
|
|
|
|
# Reload systemd before starting service
|
|
- meta: flush_handlers
|
|
|
|
- name: Ensure etcd is running
|
|
service:
|
|
name: etcd
|
|
state: started
|
|
enabled: yes
|
|
|
|
# After etcd cluster is assembled, make sure that
|
|
# initial state of the cluster is in `existing`
|
|
# state insted of `new`.
|
|
- include: set_cluster_health.yml
|
|
- include: refresh_config.yml
|