From 3f123092da8d5d89973bc52a775650500ee8ca36 Mon Sep 17 00:00:00 2001 From: pierremahot Date: Thu, 31 Oct 2024 15:05:50 +0100 Subject: [PATCH 1/4] add pod context security --- charts/metabase/README.md | 3 ++- charts/metabase/templates/deployment.yaml | 3 +++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/charts/metabase/README.md b/charts/metabase/README.md index 40cf562..3608db0 100644 --- a/charts/metabase/README.md +++ b/charts/metabase/README.md @@ -151,6 +151,7 @@ The following table lists the configurable parameters of the Metabase chart and | extraEnv | Mapping of extra environment variables | {} | | envFrom | Mapping of extra environment variables from secret and/or configMap | [] | | sidecars | Mapping of container sidecars for the main deployment | [] | -| securityContext | Security Context for the Metabase pod | {} | +| securityContext | Security Context for the Metabase container | {} | +| podSecurityContext | Security Context for the Metabase pod | {} | The above parameters map to the env variables defined in [metabase](http://github.com/metabase/metabase). For more information please refer to the [metabase documentations](https://www.metabase.com/docs/v0.41/operations-guide/environment-variables.html). diff --git a/charts/metabase/templates/deployment.yaml b/charts/metabase/templates/deployment.yaml index 9df3fe6..b33b080 100644 --- a/charts/metabase/templates/deployment.yaml +++ b/charts/metabase/templates/deployment.yaml @@ -311,6 +311,9 @@ spec: {{- if .Values.sidecars }} {{ toYaml .Values.sidecars | nindent 8 }} {{- end }} + {{- if .Values.podSecurityContext}} + securityContext: + {{- .Values.securityContext | toYaml | nindent 8 }} {{- with .Values.nodeSelector }} nodeSelector: {{ toYaml . | indent 8 }} From a029b165c3cfabb08983ca0c7d0c961dc2520c1f Mon Sep 17 00:00:00 2001 From: pierre mahot Date: Wed, 6 Nov 2024 23:07:19 +0100 Subject: [PATCH 2/4] bump chart version --- charts/metabase/Chart.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/charts/metabase/Chart.yaml b/charts/metabase/Chart.yaml index 20949cf..e6b3a0a 100644 --- a/charts/metabase/Chart.yaml +++ b/charts/metabase/Chart.yaml @@ -3,7 +3,7 @@ description: The easy, open source way for everyone in your company to ask questions and learn from data. name: metabase -version: 2.16.7 +version: 2.16.8 appVersion: v0.50.6 maintainers: - name: pmint93 From 59fa5762701aa4fd26f24ab8c07d8e50e0f04401 Mon Sep 17 00:00:00 2001 From: pierremahot Date: Mon, 11 Nov 2024 00:38:05 +0100 Subject: [PATCH 3/4] fix wonrg variable used --- charts/metabase/templates/deployment.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/charts/metabase/templates/deployment.yaml b/charts/metabase/templates/deployment.yaml index b33b080..996718c 100644 --- a/charts/metabase/templates/deployment.yaml +++ b/charts/metabase/templates/deployment.yaml @@ -313,7 +313,7 @@ spec: {{- end }} {{- if .Values.podSecurityContext}} securityContext: - {{- .Values.securityContext | toYaml | nindent 8 }} + {{- .Values.podSecurityContext | toYaml | nindent 8 }} {{- with .Values.nodeSelector }} nodeSelector: {{ toYaml . | indent 8 }} From 3ba4e36dbd443f535d40276c6ff87374dc0f47cc Mon Sep 17 00:00:00 2001 From: Pierre MAHOT Date: Thu, 14 Nov 2024 09:26:01 +0100 Subject: [PATCH 4/4] add end and add in values --- charts/metabase/templates/deployment.yaml | 1 + charts/metabase/values.yaml | 1 + 2 files changed, 2 insertions(+) diff --git a/charts/metabase/templates/deployment.yaml b/charts/metabase/templates/deployment.yaml index 996718c..c352e17 100644 --- a/charts/metabase/templates/deployment.yaml +++ b/charts/metabase/templates/deployment.yaml @@ -314,6 +314,7 @@ spec: {{- if .Values.podSecurityContext}} securityContext: {{- .Values.podSecurityContext | toYaml | nindent 8 }} + {{- end }} {{- with .Values.nodeSelector }} nodeSelector: {{ toYaml . | indent 8 }} diff --git a/charts/metabase/values.yaml b/charts/metabase/values.yaml index 17570e4..0fbc81b 100644 --- a/charts/metabase/values.yaml +++ b/charts/metabase/values.yaml @@ -23,6 +23,7 @@ deploymentAnnotations: {} deploymentLabels: {} podAnnotations: {} podLabels: {} +podSecurityContext: {} image: repository: metabase/metabase # Overrides the image tag whose default is the chart appVersion.