diff --git a/charts/plex-media-server/README.md b/charts/plex-media-server/README.md index a33641d6..e014acc1 100644 --- a/charts/plex-media-server/README.md +++ b/charts/plex-media-server/README.md @@ -111,6 +111,10 @@ Before contributing, please read the [Code of Conduct](../../CODE_OF_CONDUCT.md) | fullnameOverride | string | `""` | | | global.imageRegistry | string | `""` | Allow parent charts to override registry hostname | | hostNetwork | bool | `false` | Set to true to run the Pod in the host's network namespace. This may be required for specific networking setups or accessing local resources. | +| httpRoute.annotations | object | `{}` | Custom annotations to put on the HTTPRoute resource | +| httpRoute.enabled | bool | `false` | Specify if an HTTPRoute resource for the pms server should be created or not | +| httpRoute.hostnames | list | `[]` | Hostnames to match for the HTTPRoute | +| httpRoute.parentRefs | list | `[]` | Gateway API parent references (required when enabled) | | image | object | `{"pullPolicy":"IfNotPresent","registry":"index.docker.io","repository":"plexinc/pms-docker","sha":"","tag":"1.42.2.10156-f737b826c"}` | The docker image information for the pms application | | image.registry | string | `"index.docker.io"` | The public dockerhub registry | | imagePullSecrets | list | `[]` | | diff --git a/charts/plex-media-server/templates/httproute.yaml b/charts/plex-media-server/templates/httproute.yaml new file mode 100644 index 00000000..8fe2618d --- /dev/null +++ b/charts/plex-media-server/templates/httproute.yaml @@ -0,0 +1,26 @@ +{{- if .Values.httpRoute.enabled -}} +apiVersion: gateway.networking.k8s.io/v1 +kind: HTTPRoute +metadata: + name: {{ include "pms-chart.fullname" . }} + labels: {{ include "pms-chart.labels" . | nindent 4 }} + {{- with .Values.httpRoute.annotations }} + annotations: {{ toYaml . | nindent 4 }} + {{- end }} + +spec: + {{- with .Values.httpRoute.parentRefs }} + parentRefs: {{ toYaml . | nindent 4 }} + {{- end }} + {{- with .Values.httpRoute.hostnames }} + hostnames: {{ toYaml . | nindent 4 }} + {{- end }} + rules: + - matches: + - path: + type: PathPrefix + value: / + backendRefs: + - name: {{ include "pms-chart.fullname" . }} + port: {{ .Values.service.port }} +{{- end }} diff --git a/charts/plex-media-server/values.yaml b/charts/plex-media-server/values.yaml index 4eb67e48..c0325363 100644 --- a/charts/plex-media-server/values.yaml +++ b/charts/plex-media-server/values.yaml @@ -44,6 +44,25 @@ ingress: # -- Custom annotations to put on the ingress resource annotations: {} +httpRoute: + # -- Specify if an HTTPRoute resource for the pms server should be created or not + enabled: false + + # -- Gateway API parent references (required when enabled) + # @default -- `[]` + parentRefs: [] + # - name: my-gateway + # namespace: gateway-namespace + # sectionName: https + + # -- Hostnames to match for the HTTPRoute + # @default -- `[]` + hostnames: [] + # - plex.example.com + + # -- Custom annotations to put on the HTTPRoute resource + annotations: {} + pms: # -- The storage class to use when provisioning the pms config volume # this needs to be created manually, null will use the default