From 61b6ed513078139d3d8ab007d624515e9445d640 Mon Sep 17 00:00:00 2001 From: Sandesh Koirala Date: Sat, 30 Nov 2024 18:24:18 -0600 Subject: [PATCH] added externalTrafficPolicy to service --- charts/plex-media-server/Chart.yaml | 2 +- charts/plex-media-server/templates/service.yaml | 3 +++ charts/plex-media-server/values.yaml | 9 +++++++++ 3 files changed, 13 insertions(+), 1 deletion(-) diff --git a/charts/plex-media-server/Chart.yaml b/charts/plex-media-server/Chart.yaml index a86fef98..e2ba9c83 100644 --- a/charts/plex-media-server/Chart.yaml +++ b/charts/plex-media-server/Chart.yaml @@ -22,7 +22,7 @@ type: application # This is the chart version. This version number should be incremented each time you make changes # to the chart and its templates, including the app version. # Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 0.5.0 +version: 0.6.0 # This is the version number of the application being deployed. This version number should be # incremented each time you make changes to the application. Versions are not expected to diff --git a/charts/plex-media-server/templates/service.yaml b/charts/plex-media-server/templates/service.yaml index 2911d59f..de264597 100644 --- a/charts/plex-media-server/templates/service.yaml +++ b/charts/plex-media-server/templates/service.yaml @@ -10,6 +10,9 @@ metadata: {{- end }} spec: type: {{ .Values.service.type }} + {{- if .Values.service.externalTrafficPolicy }} + externalTrafficPolicy: {{ .Values.service.externalTrafficPolicy }} + {{- end }} ports: - port: {{ .Values.service.port }} targetPort: 32400 diff --git a/charts/plex-media-server/values.yaml b/charts/plex-media-server/values.yaml index 05503c16..7c9040a0 100644 --- a/charts/plex-media-server/values.yaml +++ b/charts/plex-media-server/values.yaml @@ -165,6 +165,15 @@ service: # Port to use when type of service is "NodePort" (32400 by default) # nodePort: 32400 + # when NodePort is used, plex is unable to determine user IP + # all traffic seems to come from within the cluster + # setting this to 'Local' will allow Plex to determine the actual IP of user. + # used to determine bitrate for remote transcoding + # but the pods can only be accessed by the Node IP where the pod is running + # Read more here: https://kubernetes.io/docs/tasks/access-application-cluster/create-external-load-balancer/#preserving-the-client-source-ip + # https://access.redhat.com/solutions/7028639 + # externalTrafficPolicy: Local + # optional extra annotations to add to the service resource annotations: {}