feat: distribution is a dict and nodes and cluster are top level (#1288)

* feat: distribution is a dict and nodes and cluster are top level

Signed-off-by: Devin Buhl <devin@buhl.casa>

* chore: housekeeping

Signed-off-by: Devin Buhl <devin@buhl.casa>

---------

Signed-off-by: Devin Buhl <devin@buhl.casa>
This commit is contained in:
Devin Buhl authored and GitHub committed 2024-02-01 20:31:42 -05:00
1 parent cba35dc66a
commit 89673cd17b
55 files changed
+330 -302

No files matched your search

@@ -6,9 +6,9 @@ cluster:
id: 1
containerRuntime:
integration: containerd
{% if distribution in ['k3s'] %}
{% if distribution.type in ["k3s"] %}
socketPath: /var/run/k3s/containerd/containerd.sock
{% elif distribution in ['k0s'] %}
{% elif distribution.type in ["k0s"] %}
socketPath: /var/run/k0s/containerd.sock
{% endif %}
endpointRoutes:
@@ -60,13 +60,13 @@ ipv6NativeRoutingCIDR: "${CLUSTER_CIDR_V6}"
ipv6:
enabled: true
{% endif %}
{% if distribution in ['k3s'] %}
{% if distribution.type in ["k3s"] %}
k8sServiceHost: 127.0.0.1
k8sServicePort: 6444
{% elif distribution in ['k0s'] %}
{% elif distribution.type in ["k0s"] %}
k8sServiceHost: localhost
k8sServicePort: 7443
{% elif distribution in ['talos'] %}
{% elif distribution.type in ["talos"] %}
k8sServiceHost: 127.0.0.1
k8sServicePort: 7445
{% endif %}
@@ -6,9 +6,9 @@ cluster:
id: 1
containerRuntime:
integration: containerd
{% if distribution in ['k3s'] %}
{% if distribution.type in ["k3s"] %}
socketPath: /var/run/k3s/containerd/containerd.sock
{% elif distribution in ['k0s'] %}
{% elif distribution.type in ["k0s"] %}
socketPath: /var/run/k0s/containerd.sock
{% endif %}
endpointRoutes:
@@ -23,13 +23,13 @@ ipv6NativeRoutingCIDR: "{{ cluster.pod_network_v6 }}"
ipv6:
enabled: true
{% endif %}
{% if distribution in ['k3s'] %}
{% if distribution.type in ["k3s"] %}
k8sServiceHost: 127.0.0.1
k8sServicePort: 6444
{% elif distribution in ['k0s'] %}
{% elif distribution.type in ["k0s"] %}
k8sServiceHost: localhost
k8sServicePort: 7443
{% elif distribution in ['talos'] %}
{% elif distribution.type in ["talos"] %}
k8sServiceHost: 127.0.0.1
k8sServicePort: 7445
{% endif %}
@@ -1,2 +1,2 @@
providerRegex: ^({{ (cluster.nodes.inventory | map(attribute='name') | join('|')) }})$
providerRegex: ^({{ (nodes.inventory | map(attribute='name') | join('|')) }})$
bypassDnsResolution: true