2017-02-20 23:51:48 +08:00
|
|
|
{% for instance in droplets.results %}
|
2017-02-22 21:27:30 +08:00
|
|
|
{{instance.droplet.name}} ansible_ssh_host={{instance.droplet.ip_address}}
|
2017-02-20 23:51:48 +08:00
|
|
|
{% endfor %}
|
|
|
|
|
|
|
|
{% if mode is defined and mode == "separate" %}
|
2021-03-24 08:26:05 +08:00
|
|
|
[kube_control_plane]
|
2017-02-22 21:27:30 +08:00
|
|
|
{{droplets.results[0].droplet.name}}
|
2017-02-20 23:51:48 +08:00
|
|
|
|
2021-04-29 20:20:50 +08:00
|
|
|
[kube_node]
|
2017-02-22 21:27:30 +08:00
|
|
|
{{droplets.results[1].droplet.name}}
|
2017-02-20 23:51:48 +08:00
|
|
|
|
|
|
|
[etcd]
|
2017-02-22 21:27:30 +08:00
|
|
|
{{droplets.results[2].droplet.name}}
|
2017-02-20 23:51:48 +08:00
|
|
|
{% elif mode is defined and mode == "ha" %}
|
2021-03-24 08:26:05 +08:00
|
|
|
[kube_control_plane]
|
2017-02-22 21:27:30 +08:00
|
|
|
{{droplets.results[0].droplet.name}}
|
|
|
|
{{droplets.results[1].droplet.name}}
|
2017-02-20 23:51:48 +08:00
|
|
|
|
2021-04-29 20:20:50 +08:00
|
|
|
[kube_node]
|
2017-02-22 21:27:30 +08:00
|
|
|
{{droplets.results[2].droplet.name}}
|
2017-02-20 23:51:48 +08:00
|
|
|
|
|
|
|
[etcd]
|
2017-02-22 21:27:30 +08:00
|
|
|
{{droplets.results[1].droplet.name}}
|
|
|
|
{{droplets.results[2].droplet.name}}
|
2017-02-20 23:51:48 +08:00
|
|
|
|
2021-03-24 08:26:05 +08:00
|
|
|
[broken_kube_control_plane]
|
2020-02-11 17:38:01 +08:00
|
|
|
{{droplets.results[1].droplet.name}}
|
|
|
|
|
|
|
|
[broken_etcd]
|
|
|
|
{{droplets.results[2].droplet.name}}
|
2017-02-20 23:51:48 +08:00
|
|
|
{% else %}
|
2021-03-24 08:26:05 +08:00
|
|
|
[kube_control_plane]
|
2017-02-22 21:27:30 +08:00
|
|
|
{{droplets.results[0].droplet.name}}
|
2017-02-20 23:51:48 +08:00
|
|
|
|
2021-04-29 20:20:50 +08:00
|
|
|
[kube_node]
|
2017-02-22 21:27:30 +08:00
|
|
|
{{droplets.results[1].droplet.name}}
|
2017-02-20 23:51:48 +08:00
|
|
|
|
|
|
|
[etcd]
|
2017-02-22 21:27:30 +08:00
|
|
|
{{droplets.results[0].droplet.name}}
|
2017-02-20 23:51:48 +08:00
|
|
|
{% endif %}
|
|
|
|
|
2021-04-29 20:20:50 +08:00
|
|
|
[calico_rr]
|
2019-08-08 22:37:22 +08:00
|
|
|
|
2021-04-29 20:20:50 +08:00
|
|
|
[k8s_cluster:children]
|
|
|
|
kube_node
|
2021-03-24 08:26:05 +08:00
|
|
|
kube_control_plane
|
2021-04-29 20:20:50 +08:00
|
|
|
calico_rr
|