summaryrefslogtreecommitdiff
path: root/roles/kubernetes/standalone/base/templates
diff options
context:
space:
mode:
authorChristian Pointner <equinox@spreadspace.org>2020-06-30 21:46:18 +0200
committerChristian Pointner <equinox@spreadspace.org>2020-06-30 21:46:18 +0200
commitd89e58a60ff8350b1650610c14996ca0a69e0d70 (patch)
treec567f913b031898cdd8f4c7fb94609f21587fef6 /roles/kubernetes/standalone/base/templates
parentresync preseed files (diff)
parentfix pod manifest permissions (diff)
Merge branch 'topic/standalone-kubelet'
Diffstat (limited to 'roles/kubernetes/standalone/base/templates')
-rw-r--r--roles/kubernetes/standalone/base/templates/cni-no-portmap.conflist.j217
-rw-r--r--roles/kubernetes/standalone/base/templates/cni-with-localonly-portmap.conflist.j225
-rw-r--r--roles/kubernetes/standalone/base/templates/cni-with-portmap.conflist.j223
-rw-r--r--roles/kubernetes/standalone/base/templates/kubelet-config.yml.j225
-rw-r--r--roles/kubernetes/standalone/base/templates/kubelet.service.override.j210
5 files changed, 100 insertions, 0 deletions
diff --git a/roles/kubernetes/standalone/base/templates/cni-no-portmap.conflist.j2 b/roles/kubernetes/standalone/base/templates/cni-no-portmap.conflist.j2
new file mode 100644
index 00000000..be47f216
--- /dev/null
+++ b/roles/kubernetes/standalone/base/templates/cni-no-portmap.conflist.j2
@@ -0,0 +1,17 @@
+{
+ "cniVersion": "0.3.1",
+ "name": "kube-standalone",
+ "plugins": [
+ {
+ "type": "bridge",
+ "bridge": "kube-bridge",
+ "isDefaultGateway": true,
+ "ipMasq": true,
+ "hairpinMode": false,
+ "ipam": {
+ "type": "host-local",
+ "subnet": "{{ kubernetes_standalone_pod_cidr }}"
+ }
+ }
+ ]
+}
diff --git a/roles/kubernetes/standalone/base/templates/cni-with-localonly-portmap.conflist.j2 b/roles/kubernetes/standalone/base/templates/cni-with-localonly-portmap.conflist.j2
new file mode 100644
index 00000000..acaf7eba
--- /dev/null
+++ b/roles/kubernetes/standalone/base/templates/cni-with-localonly-portmap.conflist.j2
@@ -0,0 +1,25 @@
+{
+ "cniVersion": "0.3.1",
+ "name": "kube-standalone",
+ "plugins": [
+ {
+ "type": "bridge",
+ "bridge": "kube-bridge",
+ "isDefaultGateway": true,
+ "ipMasq": true,
+ "hairpinMode": false,
+ "ipam": {
+ "type": "host-local",
+ "subnet": "{{ kubernetes_standalone_pod_cidr }}"
+ }
+ }, {
+ "type": "portmap",
+ "capabilities": {
+ "portMappings": true
+ },
+ "snat": true,
+ "conditionsV4": ["-s", "127.0.0.1", "-d", "127.0.0.1"],
+ "conditionsV6": ["-s", "::1", "-d", "::1"]
+ }
+ ]
+}
diff --git a/roles/kubernetes/standalone/base/templates/cni-with-portmap.conflist.j2 b/roles/kubernetes/standalone/base/templates/cni-with-portmap.conflist.j2
new file mode 100644
index 00000000..9f9b2b9a
--- /dev/null
+++ b/roles/kubernetes/standalone/base/templates/cni-with-portmap.conflist.j2
@@ -0,0 +1,23 @@
+{
+ "cniVersion": "0.3.1",
+ "name": "kube-standalone",
+ "plugins": [
+ {
+ "type": "bridge",
+ "bridge": "kube-bridge",
+ "isDefaultGateway": true,
+ "ipMasq": true,
+ "hairpinMode": false,
+ "ipam": {
+ "type": "host-local",
+ "subnet": "{{ kubernetes_standalone_pod_cidr }}"
+ }
+ }, {
+ "type": "portmap",
+ "capabilities": {
+ "portMappings": true
+ },
+ "snat": true
+ }
+ ]
+}
diff --git a/roles/kubernetes/standalone/base/templates/kubelet-config.yml.j2 b/roles/kubernetes/standalone/base/templates/kubelet-config.yml.j2
new file mode 100644
index 00000000..d6af0f24
--- /dev/null
+++ b/roles/kubernetes/standalone/base/templates/kubelet-config.yml.j2
@@ -0,0 +1,25 @@
+{# https://godoc.org/k8s.io/kubelet/config/v1beta1#KubeletConfiguration #}
+{# #}
+kind: KubeletConfiguration
+apiVersion: kubelet.config.k8s.io/v1beta1
+staticPodPath: /etc/kubernetes/manifests
+address: {{ kubernetes_standalone_address }}
+port: {{ kubernetes_standalone_port }}
+readOnlyPort: {{ kubernetes_standalone_readonly_port }}
+healthzBindAddress: {{ kubernetes_standalone_healthz_address }}
+healthzPort: {{ kubernetes_standalone_healthz_port }}
+authentication:
+ anonymous:
+ enabled: true
+ webhook:
+ enabled: false
+authorization:
+ mode: AlwaysAllow
+maxPods: {{ kubernetes_standalone_max_pods }}
+makeIPTablesUtilChains: false
+hairpinMode: none
+resolvConf: {{ kubernetes_standalone_resolv_conf }}
+cgroupDriver: systemd
+enableControllerAttachDetach: false
+featureGates:
+ RuntimeClass: false
diff --git a/roles/kubernetes/standalone/base/templates/kubelet.service.override.j2 b/roles/kubernetes/standalone/base/templates/kubelet.service.override.j2
new file mode 100644
index 00000000..fe8bfb4c
--- /dev/null
+++ b/roles/kubernetes/standalone/base/templates/kubelet.service.override.j2
@@ -0,0 +1,10 @@
+[Service]
+ExecStart=
+ExecStart=/usr/bin/kubelet \
+ --config=/etc/kubernetes/kubelet.yml \
+{% if kubernetes_cri_socket %}
+ --container-runtime=remote \
+ --container-runtime-endpoint={{ kubernetes_cri_socket }} \
+{% endif %}
+ --network-plugin=cni \
+ --cloud-provider=