Skip to content

Commit 4f1e21d

Browse files
fix: mount Hubble TLS volume in Cilium configuration make it optional to prevent pod startup issues when no TLS secret is provided (#3803)
closes #3794 Signed-off-by: tobstone <tobias@stonehope.de> Co-authored-by: tobstone <tobias@stonehope.de>
1 parent 7fab19d commit 4f1e21d

File tree

2 files changed

+42
-6
lines changed

2 files changed

+42
-6
lines changed

addons/cni-cilium/Kustomization

Lines changed: 25 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,12 @@ kind: Kustomization
33
namespace: kube-system
44

55
helmCharts:
6-
- name: cilium
7-
repo: https://helm.cilium.io/
8-
version: 1.17.3
9-
releaseName: cilium
10-
namespace: kube-system
11-
valuesFile: helm-values
6+
- name: cilium
7+
repo: https://helm.cilium.io/
8+
version: 1.17.3
9+
releaseName: cilium
10+
namespace: kube-system
11+
valuesFile: helm-values
1212

1313
patches:
1414
- patch: |-
@@ -55,6 +55,10 @@ patches:
5555
name: cilium-config
5656
key: KUBERNETES_SERVICE_PORT
5757
optional: true
58+
volumeMounts:
59+
- name: hubble-tls
60+
mountPath: /var/lib/cilium/tls/hubble
61+
readOnly: true
5862
initContainers:
5963
- name: config
6064
image: '{{ .InternalImages.Get "Cilium" }}'
@@ -94,6 +98,21 @@ patches:
9498
optional: true
9599
- name: install-cni-binaries
96100
image: '{{ .InternalImages.Get "Cilium" }}'
101+
volumes:
102+
- name: hubble-tls
103+
projected:
104+
defaultMode: 256
105+
sources:
106+
- secret:
107+
name: hubble-server-certs
108+
optional: true
109+
items:
110+
- key: tls.crt
111+
path: server.crt
112+
- key: tls.key
113+
path: server.key
114+
- key: ca.crt
115+
path: client-ca.crt
97116
- patch: |-
98117
apiVersion: apps/v1
99118
kind: Deployment

addons/cni-cilium/cilium.yaml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1198,6 +1198,9 @@ spec:
11981198
successThreshold: 1
11991199
terminationMessagePolicy: FallbackToLogsOnError
12001200
volumeMounts:
1201+
- mountPath: /var/lib/cilium/tls/hubble
1202+
name: hubble-tls
1203+
readOnly: true
12011204
- mountPath: /var/run/cilium/envoy/sockets
12021205
name: envoy-sockets
12031206
readOnly: false
@@ -1429,6 +1432,20 @@ spec:
14291432
tolerations:
14301433
- operator: Exists
14311434
volumes:
1435+
- name: hubble-tls
1436+
projected:
1437+
defaultMode: 256
1438+
sources:
1439+
- secret:
1440+
items:
1441+
- key: tls.crt
1442+
path: server.crt
1443+
- key: tls.key
1444+
path: server.key
1445+
- key: ca.crt
1446+
path: client-ca.crt
1447+
name: hubble-server-certs
1448+
optional: true
14321449
- emptyDir: {}
14331450
name: tmp
14341451
- hostPath:

0 commit comments

Comments
 (0)