feat: remove the need for raw jinja blocks (#1158)

Signed-off-by: Devin Buhl <devin@buhl.casa>
This commit is contained in:
Devin Buhl authored and GitHub committed 2024-01-15 00:03:41 -05:00
1 parent f9481d6202
commit e6fbc6e128
92 files changed
+430 -441

No files matched your search

@@ -1,4 +1,4 @@
{% if bootstrap_distribution == 'k3s' %}
<% if bootstrap_distribution == 'k3s' %>
---
# https://docs.k3s.io/helm
apiVersion: helm.cattle.io/v1
@@ -31,29 +31,29 @@ spec:
enabled: false
ipam:
mode: kubernetes
ipv4NativeRoutingCIDR: "{% raw %}{{ cluster_cidr }}{% endraw %}"
{% if bootstrap_ipv6_enabled | default(false) %}
ipv6NativeRoutingCIDR: "{% raw %}{{ cluster_cidr_v6 }}{% endraw %}"
ipv4NativeRoutingCIDR: "{{ cluster_cidr }}"
<% if bootstrap_ipv6_enabled | default(false) %>
ipv6NativeRoutingCIDR: "{{ cluster_cidr_v6 }}"
ipv6:
enabled: true
{% endif %}
k8sServiceHost: "{% raw %}{{ kube_api_addr }}{% endraw %}"
<% endif %>
k8sServiceHost: "{{ kube_api_addr }}"
k8sServicePort: 6443
kubeProxyReplacement: true
kubeProxyReplacementHealthzBindAddr: 0.0.0.0:10256
l2announcements:
{% if bootstrap_ipv6_enabled | default(false) %}
<% if bootstrap_ipv6_enabled | default(false) %>
enabled: false
{% else %}
<% else %>
enabled: true
# https://github.com/cilium/cilium/issues/26586
leaseDuration: 120s
leaseRenewDeadline: 60s
leaseRetryPeriod: 1s
{% endif %}
<% endif %>
loadBalancer:
algorithm: maglev
mode: {{ bootstrap_cilium_loadbalancer_mode | default('dsr', true) }}
mode: << bootstrap_cilium_loadbalancer_mode | default('dsr', true) >>
localRedirectPolicy: true
operator:
replicas: 1
@@ -62,4 +62,4 @@ spec:
routingMode: native
securityContext:
privileged: true
{% endif %}
<% endif %>
@@ -1,4 +1,4 @@
{% if bootstrap_distribution == 'k3s' %}
<% if bootstrap_distribution == 'k3s' %>
---
# https://docs.k3s.io/helm
apiVersion: helm.cattle.io/v1
@@ -19,7 +19,7 @@ spec:
k8sAppLabelOverride: kube-dns
service:
name: kube-dns
clusterIP: "{% raw %}{{ coredns_addr }}{% endraw %}"
clusterIP: "{{ coredns_addr }}"
serviceAccount:
create: true
deployment:
@@ -76,4 +76,4 @@ spec:
labelSelector:
matchLabels:
app.kubernetes.io/instance: coredns
{% endif %}
<% endif %>
@@ -1,4 +1,4 @@
{% if bootstrap_distribution == 'k3s' and bootstrap_nodes.master | length > 1 and not bootstrap_kube_api_addr %}
<% if bootstrap_distribution == 'k3s' and bootstrap_nodes.master | length > 1 and not bootstrap_kube_api_addr %>
---
apiVersion: v1
kind: Pod
@@ -16,7 +16,7 @@ spec:
args: ["manager"]
env:
- name: address
value: "{% raw %}{{ kube_api_addr }}{% endraw %}"
value: "{{ kube_api_addr }}"
- name: vip_arp
value: "true"
- name: lb_enable
@@ -58,4 +58,4 @@ spec:
- name: kubeconfig
hostPath:
path: /etc/rancher/k3s/k3s.yaml
{% endif %}
<% endif %>