You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

73 lines
1.2 KiB

  1. {% set node1 = gce.instance_data[0].name %}
  2. {{node1}} ansible_ssh_host={{gce.instance_data[0].public_ip}}
  3. {% if mode != "aio" %}
  4. {% set node2 = gce.instance_data[1].name %}
  5. {{node2}} ansible_ssh_host={{gce.instance_data[1].public_ip}}
  6. {% endif %}
  7. {% if mode is defined and mode in ["ha", "ha-scale", "separate", "separate-scale"] %}
  8. {% set node3 = gce.instance_data[2].name %}
  9. {{node3}} ansible_ssh_host={{gce.instance_data[2].public_ip}}
  10. {% endif %}
  11. {% if mode is defined and mode in ["separate", "separate-scale"] %}
  12. [kube_control_plane]
  13. {{node1}}
  14. [kube_node]
  15. {{node2}}
  16. [etcd]
  17. {{node3}}
  18. {% elif mode is defined and mode in ["ha", "ha-scale"] %}
  19. [kube_control_plane]
  20. {{node1}}
  21. {{node2}}
  22. [kube_node]
  23. {{node3}}
  24. [etcd]
  25. {{node1}}
  26. {{node2}}
  27. {{node3}}
  28. [broken_kube_control_plane]
  29. {{node2}}
  30. [etcd]
  31. {{node2}}
  32. {{node3}}
  33. {% elif mode == "default" %}
  34. [kube_control_plane]
  35. {{node1}}
  36. [kube_node]
  37. {{node2}}
  38. [etcd]
  39. {{node1}}
  40. {% elif mode == "aio" %}
  41. [kube_control_plane]
  42. {{node1}}
  43. [kube_node]
  44. {{node1}}
  45. [etcd]
  46. {{node1}}
  47. {% endif %}
  48. [k8s_cluster:children]
  49. kube_node
  50. kube_control_plane
  51. calico_rr
  52. [calico_rr]
  53. {% if mode is defined and mode in ["scale", "separate-scale", "ha-scale"] %}
  54. [fake_hosts]
  55. fake_scale_host[1:200]
  56. [kube_node:children]
  57. fake_hosts
  58. {% endif %}