--peers DEPRECATED - --endpoints should be used instead (#1943)

This commit is contained in:
chenhonggc 2017-11-14 05:28:35 -06:00 committed by Matthew Mosesohn
parent 5e558c361b
commit c7910b51a1
3 changed files with 4 additions and 4 deletions

View file

@ -1,6 +1,6 @@
--- ---
- name: Configure | Check if member is in cluster - name: Configure | Check if member is in cluster
shell: "{{ bin_dir }}/etcdctl --no-sync --peers={{ etcd_access_addresses }} member list | grep -q {{ etcd_access_address }}" shell: "{{ bin_dir }}/etcdctl --no-sync --endpoints={{ etcd_access_addresses }} member list | grep -q {{ etcd_access_address }}"
register: etcd_member_in_cluster register: etcd_member_in_cluster
ignore_errors: true ignore_errors: true
changed_when: false changed_when: false

View file

@ -1,6 +1,6 @@
--- ---
- name: Join Member | Add member to cluster - name: Join Member | Add member to cluster
shell: "{{ bin_dir }}/etcdctl --peers={{ etcd_access_addresses }} member add {{ etcd_member_name }} {{ etcd_peer_url }}" shell: "{{ bin_dir }}/etcdctl --endpoints={{ etcd_access_addresses }} member add {{ etcd_member_name }} {{ etcd_peer_url }}"
register: member_add_result register: member_add_result
until: member_add_result.rc == 0 until: member_add_result.rc == 0
retries: 4 retries: 4
@ -32,7 +32,7 @@
when: target_node == inventory_hostname when: target_node == inventory_hostname
- name: Join Member | Ensure member is in cluster - name: Join Member | Ensure member is in cluster
shell: "{{ bin_dir }}/etcdctl --no-sync --peers={{ etcd_access_addresses }} member list | grep -q {{ etcd_access_address }}" shell: "{{ bin_dir }}/etcdctl --no-sync --endpoints={{ etcd_access_addresses }} member list | grep -q {{ etcd_access_address }}"
register: etcd_member_in_cluster register: etcd_member_in_cluster
changed_when: false changed_when: false
check_mode: no check_mode: no

View file

@ -1,6 +1,6 @@
--- ---
- name: Configure | Check if cluster is healthy - name: Configure | Check if cluster is healthy
shell: "{{ bin_dir }}/etcdctl --peers={{ etcd_access_addresses }} cluster-health | grep -q 'cluster is healthy'" shell: "{{ bin_dir }}/etcdctl --endpoints={{ etcd_access_addresses }} cluster-health | grep -q 'cluster is healthy'"
register: etcd_cluster_is_healthy register: etcd_cluster_is_healthy
ignore_errors: true ignore_errors: true
changed_when: false changed_when: false