Browse Source
fix ETCD_INITIAL_CLUSTER config in etcd.env and etcd-events.env (#12342)
pull/12285/head
刘旭
3 months ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with
2 additions and
2 deletions
-
roles/etcd/tasks/join_etcd-events_member.yml
-
roles/etcd/tasks/join_etcd_member.yml
|
|
@ -19,7 +19,7 @@ |
|
|
|
etcd_events_peer_addresses: >- |
|
|
|
{% for host in groups['etcd'] -%} |
|
|
|
{%- if hostvars[host]['etcd_events_member_in_cluster'].rc == 0 -%} |
|
|
|
{{ "etcd" + loop.index | string }}="https://{{ hostvars[host].etcd_events_access_address | default(hostvars[host]['main_ip']) | ansible.utils.ipwrap }}:2382", |
|
|
|
{{ "etcd" + loop.index | string }}=https://{{ hostvars[host].etcd_events_access_address | default(hostvars[host]['main_ip']) | ansible.utils.ipwrap }}:2382, |
|
|
|
{%- endif -%} |
|
|
|
{%- if loop.last -%} |
|
|
|
{{ etcd_member_name }}={{ etcd_events_peer_url }} |
|
|
|
|
|
@ -20,7 +20,7 @@ |
|
|
|
etcd_peer_addresses: >- |
|
|
|
{% for host in groups['etcd'] -%} |
|
|
|
{%- if hostvars[host]['etcd_member_in_cluster'].rc == 0 -%} |
|
|
|
{{ "etcd" + loop.index | string }}="https://{{ hostvars[host].etcd_access_address | default(hostvars[host]['main_ip']) | ansible.utils.ipwrap }}:2380", |
|
|
|
{{ "etcd" + loop.index | string }}=https://{{ hostvars[host].etcd_access_address | default(hostvars[host]['main_ip']) | ansible.utils.ipwrap }}:2380, |
|
|
|
{%- endif -%} |
|
|
|
{%- if loop.last -%} |
|
|
|
{{ etcd_member_name }}={{ etcd_peer_url }} |
|
|
|