feat: allow for configuring security context of all components (#410)

This commit is contained in:
Chris 2020-09-02 18:09:17 +02:00 committed by GitHub
parent 196ab4f281
commit d32e27edc8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 19 additions and 2 deletions

View file

@ -2,7 +2,7 @@ apiVersion: v1
appVersion: v2.8.0 appVersion: v2.8.0
description: A Helm chart for Argo Workflows description: A Helm chart for Argo Workflows
name: argo name: argo
version: 0.10.0 version: 0.10.1
icon: https://raw.githubusercontent.com/argoproj/argo/master/docs/assets/argo.png icon: https://raw.githubusercontent.com/argoproj/argo/master/docs/assets/argo.png
home: https://github.com/argoproj/argo-helm home: https://github.com/argoproj/argo-helm
maintainers: maintainers:

View file

@ -26,6 +26,10 @@ spec:
{{ toYaml .Values.server.podAnnotations | indent 8}}{{- end }} {{ toYaml .Values.server.podAnnotations | indent 8}}{{- end }}
spec: spec:
serviceAccountName: {{ .Values.server.serviceAccount | quote }} serviceAccountName: {{ .Values.server.serviceAccount | quote }}
{{- if .Values.server.podSecurityContext }}
securityContext:
{{- toYaml .Values.server.podSecurityContext | nindent 8 }}
{{- end }}
containers: containers:
- name: argo-server - name: argo-server
args: args:

View file

@ -16,7 +16,7 @@ data:
{{- end }} {{- end }}
{{- end }} {{- end }}
containerRuntimeExecutor: {{ .Values.controller.containerRuntimeExecutor }} containerRuntimeExecutor: {{ .Values.controller.containerRuntimeExecutor }}
{{- if or .Values.executor.resources .Values.executor.env }} {{- if or .Values.executor.resources .Values.executor.env .Values.executor.securityContext}}
executor: executor:
{{- with .Values.executor.resources }} {{- with .Values.executor.resources }}
resources: {{- toYaml . | nindent 8 }} resources: {{- toYaml . | nindent 8 }}
@ -24,6 +24,9 @@ data:
{{- with .Values.executor.env }} {{- with .Values.executor.env }}
env: {{- toYaml . | nindent 8 }} env: {{- toYaml . | nindent 8 }}
{{- end }} {{- end }}
{{- with .Values.executor.securityContext }}
securityContext: {{- toYaml . | nindent 8 }}
{{- end }}
{{- end }} {{- end }}
{{- if or .Values.minio.install .Values.useDefaultArtifactRepo }} {{- if or .Values.minio.install .Values.useDefaultArtifactRepo }}
artifactRepository: artifactRepository:

View file

@ -26,6 +26,10 @@ spec:
{{ toYaml .Values.controller.podAnnotations | indent 8}}{{- end }} {{ toYaml .Values.controller.podAnnotations | indent 8}}{{- end }}
spec: spec:
serviceAccountName: {{ .Values.controller.serviceAccount | quote }} serviceAccountName: {{ .Values.controller.serviceAccount | quote }}
{{- if .Values.controller.podSecurityContext }}
securityContext:
{{- toYaml .Values.controller.podSecurityContext | nindent 8 }}
{{- end }}
containers: containers:
- name: controller - name: controller
image: "{{ .Values.images.namespace }}/{{ .Values.images.controller }}:{{ default .Values.images.tag .Values.controller.image.tag }}" image: "{{ .Values.images.namespace }}/{{ .Values.images.controller }}:{{ default .Values.images.tag .Values.controller.image.tag }}"

View file

@ -31,6 +31,8 @@ controller:
podAnnotations: {} podAnnotations: {}
# Optional labels to add to the controller pods # Optional labels to add to the controller pods
podLabels: {} podLabels: {}
# SecurityContext to set on the controller pods
podSecurityContext: {}
# podPortName: http # podPortName: http
metricsConfig: metricsConfig:
enabled: false enabled: false
@ -121,6 +123,8 @@ executor:
resources: {} resources: {}
# Adds environment variables for the executor. # Adds environment variables for the executor.
env: {} env: {}
# sets security context for the executor container
securityContext: {}
server: server:
enabled: true enabled: true
@ -135,6 +139,8 @@ server:
podAnnotations: {} podAnnotations: {}
# Optional labels to add to the UI pods # Optional labels to add to the UI pods
podLabels: {} podLabels: {}
# SecurityContext to set on the server pods
podSecurityContext: {}
name: server name: server
serviceType: ClusterIP serviceType: ClusterIP
servicePort: 2746 servicePort: 2746