From 86f54eccf95af01a4da096ed1ed7384a08315315 Mon Sep 17 00:00:00 2001 From: Lex Rivera Date: Wed, 13 Oct 2021 18:52:12 +0300 Subject: [PATCH] Add annotations support --- README.md | 1 + charts/factorio-server-charts/templates/service.yaml | 4 ++++ charts/factorio-server-charts/values.yaml | 1 + 3 files changed, 6 insertions(+) diff --git a/README.md b/README.md index e1ddb99..35a68dd 100644 --- a/README.md +++ b/README.md @@ -54,6 +54,7 @@ The following table lists the configurable parameters of the `factorio-server-ch | image.tag | Overrides the image tag whose default is the chart appVersion. | `"latest"` | | securityContext.runAsUser | | `1000` | | securityContext.fsGroup | | `2000` | +| service.annotations | Annotations for service | `{}` | | service.type | | `LoadBalancer` | | service.port | | `30000` | | resources | Compute Resources required by the operator container | `{"requests":{"cpu":"500m","memory":"512Mi"}}` | diff --git a/charts/factorio-server-charts/templates/service.yaml b/charts/factorio-server-charts/templates/service.yaml index 71c3d08..4129b7f 100644 --- a/charts/factorio-server-charts/templates/service.yaml +++ b/charts/factorio-server-charts/templates/service.yaml @@ -7,6 +7,10 @@ metadata: chart: "{{ .Chart.Name }}-{{ .Chart.Version }}" release: "{{ .Release.Name }}" heritage: "{{ .Release.Service }}" + annotations: + {{- range $key, $value := .Values.service.annotations }} + {{ $key }}: {{ $value | quote }} + {{- end }} spec: type: {{ .Values.service.type }} ports: diff --git a/charts/factorio-server-charts/values.yaml b/charts/factorio-server-charts/values.yaml index f31a8b9..c61627c 100644 --- a/charts/factorio-server-charts/values.yaml +++ b/charts/factorio-server-charts/values.yaml @@ -41,6 +41,7 @@ service: # port: 34197 ## LoadBalancer setup # type: LoadBalancer + annotations: {} ## Compute Resources required by the operator container