From c860b4c3aeebe5850633c377ab9e5934ab1fe017 Mon Sep 17 00:00:00 2001 From: Engin Diri Date: Wed, 30 Mar 2022 09:51:29 +0200 Subject: [PATCH] fix: add annotation support for deployment manifest (#91) Signed-off-by: Engin Diri --- charts/node-red/Chart.yaml | 4 ++-- charts/node-red/README.md | 5 +++-- charts/node-red/templates/deployment.yaml | 4 ++++ charts/node-red/values.yaml | 3 +++ 4 files changed, 12 insertions(+), 4 deletions(-) diff --git a/charts/node-red/Chart.yaml b/charts/node-red/Chart.yaml index 7e41d350..c549a7da 100644 --- a/charts/node-red/Chart.yaml +++ b/charts/node-red/Chart.yaml @@ -9,7 +9,7 @@ icon: https://nodered.org/about/resources/media/node-red-icon-2.png type: application -version: 0.13.2 +version: 0.14.0 appVersion: 2.2.2 keywords: @@ -29,7 +29,7 @@ maintainers: annotations: artifacthub.io/containsSecurityUpdates: "false" artifacthub.io/changes: | - - change port name of servicemonitor to default port + - add annotation support for deployment manifest artifacthub.io/images: | - name: node-red image: docker.io/nodered/node-red:2.2.2 diff --git a/charts/node-red/README.md b/charts/node-red/README.md index dda5a9f8..9b2101c2 100644 --- a/charts/node-red/README.md +++ b/charts/node-red/README.md @@ -1,6 +1,6 @@ # node-red ⚙ -![Version: 0.13.2](https://img.shields.io/badge/Version-0.13.2-informational?style=for-the-badge) +![Version: 0.14.0](https://img.shields.io/badge/Version-0.14.0-informational?style=for-the-badge) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=for-the-badge) ![AppVersion: 2.2.2](https://img.shields.io/badge/AppVersion-2.2.2-informational?style=for-the-badge) @@ -26,7 +26,7 @@ helm repo update To install the chart with the release name node-red run: ```bash -helm install node-red node-red/node-red --version 0.13.2 +helm install node-red node-red/node-red --version 0.14.0 ``` After a few seconds, node-red should be running. @@ -55,6 +55,7 @@ The command removes all the Kubernetes components associated with the chart and | Key | Type | Default | Description | |-----|------|---------|-------------| | affinity | object | `{}` | The affinity constraint | +| deploymentAnnotations | object | `{}` | Deployment annotations | | deploymentStrategy | string | `""` | Specifies the strategy used to replace old Pods by new ones, default: `RollingUpdate` | | env | list | `[]` | node-red env, see more environment variables in the [node-red documentation](https://nodered.org/docs/getting-started/docker) | | extraVolumeMounts | string | `nil` | Extra Volume Mounts for the node-red pod | diff --git a/charts/node-red/templates/deployment.yaml b/charts/node-red/templates/deployment.yaml index 50e89122..0db5ab9e 100644 --- a/charts/node-red/templates/deployment.yaml +++ b/charts/node-red/templates/deployment.yaml @@ -1,6 +1,10 @@ apiVersion: apps/v1 kind: Deployment metadata: + {{- with .Values.deploymentAnnotations }} + annotations: + {{- toYaml . | nindent 4 }} + {{- end }} name: {{ include "node-red.fullname" . }} labels: {{- include "node-red.labels" . | nindent 4 }} diff --git a/charts/node-red/values.yaml b/charts/node-red/values.yaml index 534a55d4..1cebd76e 100644 --- a/charts/node-red/values.yaml +++ b/charts/node-red/values.yaml @@ -58,6 +58,9 @@ serviceAccount: # -- Pod annotations podAnnotations: {} +# -- Deployment annotations +deploymentAnnotations: {} + # -- Pod Security Context see [values.yaml](values.yaml) podSecurityContext: {} # fsGroup: 2000