Fix helm securityContext (#640)
* Helm Chart version bump Signed-off-by: Aleksandrs Markevics <amarkevics@onairent.live> * fsGroup moved under podSecurityContext Signed-off-by: Aleksandrs Markevics <amarkevics@onairent.live> --------- Signed-off-by: Aleksandrs Markevics <amarkevics@onairent.live> Co-authored-by: Aleksandrs Markevics <amarkevics@onairent.live>
This commit is contained in:
parent
fdf0977be2
commit
c7fd631f86
3 changed files with 20 additions and 9 deletions
|
|
@ -2,8 +2,8 @@ apiVersion: v2
|
||||||
name: pulse
|
name: pulse
|
||||||
description: Helm chart for deploying the Pulse hub and optional Docker monitoring agent.
|
description: Helm chart for deploying the Pulse hub and optional Docker monitoring agent.
|
||||||
type: application
|
type: application
|
||||||
version: 4.26.0
|
version: 4.26.1
|
||||||
appVersion: "4.26.0"
|
appVersion: "4.26.1"
|
||||||
icon: https://raw.githubusercontent.com/rcourtman/Pulse/main/docs/images/pulse-logo.svg
|
icon: https://raw.githubusercontent.com/rcourtman/Pulse/main/docs/images/pulse-logo.svg
|
||||||
keywords:
|
keywords:
|
||||||
- monitoring
|
- monitoring
|
||||||
|
|
|
||||||
|
|
@ -23,10 +23,14 @@ spec:
|
||||||
{{- end }}
|
{{- end }}
|
||||||
spec:
|
spec:
|
||||||
serviceAccountName: {{ include "pulse.serviceAccountName" . }}
|
serviceAccountName: {{ include "pulse.serviceAccountName" . }}
|
||||||
{{- $podSecurityContext := merge (dict) .Values.podSecurityContext .Values.server.podSecurityContext }}
|
{{- $podSecurityContext :=
|
||||||
|
ternary
|
||||||
|
(merge (dict) .Values.podSecurityContext .Values.server.podSecurityContext)
|
||||||
|
.Values.server.podSecurityContext
|
||||||
|
.Values.podSecurityContext.enabled }}
|
||||||
{{- if $podSecurityContext }}
|
{{- if $podSecurityContext }}
|
||||||
securityContext:
|
securityContext:
|
||||||
{{- toYaml $podSecurityContext | nindent 8 }}
|
{{- omit $podSecurityContext "enabled" | toYaml | nindent 8 }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- with .Values.imagePullSecrets }}
|
{{- with .Values.imagePullSecrets }}
|
||||||
imagePullSecrets:
|
imagePullSecrets:
|
||||||
|
|
@ -39,10 +43,14 @@ spec:
|
||||||
ports:
|
ports:
|
||||||
- name: http
|
- name: http
|
||||||
containerPort: 7655
|
containerPort: 7655
|
||||||
{{- $containerSecurityContext := merge (dict) .Values.securityContext .Values.server.securityContext }}
|
{{- $containerSecurityContext :=
|
||||||
|
ternary
|
||||||
|
(merge (dict) .Values.containerSecurityContext .Values.server.securityContext)
|
||||||
|
.Values.server.securityContext
|
||||||
|
.Values.containerSecurityContext.enabled }}
|
||||||
{{- if $containerSecurityContext }}
|
{{- if $containerSecurityContext }}
|
||||||
securityContext:
|
securityContext:
|
||||||
{{- toYaml $containerSecurityContext | nindent 12 }}
|
{{- omit $containerSecurityContext "enabled" | toYaml | nindent 12 }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- $envList := list }}
|
{{- $envList := list }}
|
||||||
{{- range .Values.server.env }}
|
{{- range .Values.server.env }}
|
||||||
|
|
|
||||||
|
|
@ -22,13 +22,16 @@ serviceAccount:
|
||||||
podAnnotations: {}
|
podAnnotations: {}
|
||||||
podLabels: {}
|
podLabels: {}
|
||||||
|
|
||||||
podSecurityContext: {}
|
podSecurityContext:
|
||||||
|
enabled: true
|
||||||
|
fsGroup: 1000
|
||||||
|
|
||||||
securityContext:
|
containerSecurityContext:
|
||||||
|
enabled: true
|
||||||
runAsNonRoot: true
|
runAsNonRoot: true
|
||||||
runAsUser: 1000
|
runAsUser: 1000
|
||||||
runAsGroup: 1000
|
runAsGroup: 1000
|
||||||
fsGroup: 1000
|
|
||||||
|
|
||||||
service:
|
service:
|
||||||
type: ClusterIP
|
type: ClusterIP
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue