From 6516432473b6500441c894e45e296f13435fafc1 Mon Sep 17 00:00:00 2001 From: kemv Date: Wed, 31 May 2023 14:21:58 +0200 Subject: [PATCH 1/4] Added podAnnotations feature --- .../ci/with-additional-annotations-values.yaml | 4 +++- charts/bifrost-gateway-controller/templates/deployment.yaml | 3 +++ charts/bifrost-gateway-controller/values.yaml | 4 ++++ 3 files changed, 10 insertions(+), 1 deletion(-) diff --git a/charts/bifrost-gateway-controller/ci/with-additional-annotations-values.yaml b/charts/bifrost-gateway-controller/ci/with-additional-annotations-values.yaml index 115a027b..8e85e1bc 100644 --- a/charts/bifrost-gateway-controller/ci/with-additional-annotations-values.yaml +++ b/charts/bifrost-gateway-controller/ci/with-additional-annotations-values.yaml @@ -1,3 +1,5 @@ controllerManager: annotations: - tv2.dk/gateway-controller/annontations: true + tv2.dk/gateway-controller/annotations: true + podAnnotations: + tv2.dk/gateway-controller/podAnnotations: true diff --git a/charts/bifrost-gateway-controller/templates/deployment.yaml b/charts/bifrost-gateway-controller/templates/deployment.yaml index b24b48a2..0f336928 100644 --- a/charts/bifrost-gateway-controller/templates/deployment.yaml +++ b/charts/bifrost-gateway-controller/templates/deployment.yaml @@ -22,6 +22,9 @@ spec: control-plane: manager {{- include "gateway-controller.selectorLabels" . | nindent 8 }} annotations: + {{- with .Values.controllerManager.podAnnotations }} + {{- toYaml . | nindent 8 }} + {{- end }} kubectl.kubernetes.io/default-container: manager spec: containers: diff --git a/charts/bifrost-gateway-controller/values.yaml b/charts/bifrost-gateway-controller/values.yaml index ea84c247..57bc2ee6 100644 --- a/charts/bifrost-gateway-controller/values.yaml +++ b/charts/bifrost-gateway-controller/values.yaml @@ -50,6 +50,10 @@ controllerManager: # Annotations to add to the deployment annotations: {} + + # Annotations to add to the pod + podAnnotations: {} + replicas: 1 deploymentStrategy: From 12213cf1ec7454dd36a62357baa7b67a3a9eae0f Mon Sep 17 00:00:00 2001 From: kemv Date: Wed, 31 May 2023 14:32:56 +0200 Subject: [PATCH 2/4] Update CHANGELOG --- charts/bifrost-gateway-controller/CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/charts/bifrost-gateway-controller/CHANGELOG.md b/charts/bifrost-gateway-controller/CHANGELOG.md index e41b1b9b..c88bdee5 100644 --- a/charts/bifrost-gateway-controller/CHANGELOG.md +++ b/charts/bifrost-gateway-controller/CHANGELOG.md @@ -3,6 +3,7 @@ ## [UNRELEASED] - Example text, add your PR info according to example below below this line. Do not bump chart version in Chart.yaml. +- Added podAnnotations to chart, allowing users to set annotations for the controller pod ## [0.1.6] From 84674af80dbd851e3e1d4247fe19289f790960ef Mon Sep 17 00:00:00 2001 From: kemv Date: Wed, 31 May 2023 14:43:48 +0200 Subject: [PATCH 3/4] Update README --- charts/bifrost-gateway-controller/README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/charts/bifrost-gateway-controller/README.md b/charts/bifrost-gateway-controller/README.md index a5b13819..f0a2246d 100644 --- a/charts/bifrost-gateway-controller/README.md +++ b/charts/bifrost-gateway-controller/README.md @@ -27,6 +27,7 @@ Gateway API driven management of network infrastructure across Kubernetes and cl | controllerManager.manager.resources.limits.memory | string | `"128Mi"` | | | controllerManager.manager.resources.requests.cpu | string | `"10m"` | | | controllerManager.manager.resources.requests.memory | string | `"64Mi"` | | +| controllerManager.podAnnotations | object | `{}` | | | controllerManager.replicas | int | `1` | | | metricsService.ports[0].name | string | `"http"` | | | metricsService.ports[0].port | int | `8080` | | From 8dd341ec0df7159dc946556d818381a0450bbf7c Mon Sep 17 00:00:00 2001 From: Michael Vittrup Larsen Date: Wed, 31 May 2023 14:54:18 +0200 Subject: [PATCH 4/4] Update chart testing to skip version increment test --- .github/configs/ct-lint.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/configs/ct-lint.yaml b/.github/configs/ct-lint.yaml index 75c0d8c0..c1d3e9de 100644 --- a/.github/configs/ct-lint.yaml +++ b/.github/configs/ct-lint.yaml @@ -5,3 +5,4 @@ chart-dirs: - charts helm-extra-args: --timeout 600s validate-maintainers: false +check-version-increment: false