From 8a0626a67cf023195c12b0373cfbb63b4e95c409 Mon Sep 17 00:00:00 2001 From: David Barrat Date: Fri, 26 Sep 2025 13:44:50 +0200 Subject: [PATCH 1/2] Enable hostPort only if podHostNetwork is enabled --- livekit-server/templates/deployment.yaml | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/livekit-server/templates/deployment.yaml b/livekit-server/templates/deployment.yaml index 7b35cee..a94cc0a 100644 --- a/livekit-server/templates/deployment.yaml +++ b/livekit-server/templates/deployment.yaml @@ -67,32 +67,42 @@ spec: {{- if .Values.livekit.rtc.udp_port }} - name: rtc-udp containerPort: {{ .Values.livekit.rtc.udp_port }} + {{- if .Values.podHostNetwork }} hostPort: {{ .Values.livekit.rtc.udp_port }} + {{- end }} protocol: UDP {{- end }} {{- if .Values.livekit.rtc.tcp_port }} - name: rtc-tcp containerPort: {{ .Values.livekit.rtc.tcp_port }} + {{- if .Values.podHostNetwork }} hostPort: {{ .Values.livekit.rtc.tcp_port }} + {{- end }} protocol: TCP {{- end }} {{- if .Values.livekit.prometheus_port }} - name: metrics containerPort: {{ .Values.livekit.prometheus_port }} + {{- if .Values.podHostNetwork }} hostPort: {{ .Values.livekit.prometheus_port }} + {{- end }} protocol: TCP {{- end }} {{- if .Values.livekit.turn.enabled }} {{- if .Values.livekit.turn.tls_port }} - name: turn-tls containerPort: {{ .Values.livekit.turn.tls_port }} + {{- if .Values.podHostNetwork }} hostPort: {{ .Values.livekit.turn.tls_port }} + {{- end }} protocol: TCP {{- end }} {{- if .Values.livekit.turn.udp_port }} - name: turn-udp containerPort: {{ .Values.livekit.turn.udp_port }} + {{- if .Values.podHostNetwork }} hostPort: {{ .Values.livekit.turn.udp_port }} + {{- end }} protocol: UDP {{- end }} {{- end }} @@ -144,4 +154,4 @@ spec: {{- with .Values.tolerations }} tolerations: {{- toYaml . | nindent 8 }} - {{- end }} + {{- end }} \ No newline at end of file From 8aec0c1c2a7388e9e92cefe25ded044f0c52bac5 Mon Sep 17 00:00:00 2001 From: David Barrat Date: Fri, 26 Sep 2025 13:58:25 +0200 Subject: [PATCH 2/2] Fix new line end of file --- livekit-server/templates/deployment.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/livekit-server/templates/deployment.yaml b/livekit-server/templates/deployment.yaml index a94cc0a..2acad25 100644 --- a/livekit-server/templates/deployment.yaml +++ b/livekit-server/templates/deployment.yaml @@ -154,4 +154,4 @@ spec: {{- with .Values.tolerations }} tolerations: {{- toYaml . | nindent 8 }} - {{- end }} \ No newline at end of file + {{- end }}