diff options
author | Krzysztof Opasiak <k.opasiak@samsung.com> | 2020-11-25 16:54:36 +0100 |
---|---|---|
committer | Sylvain Desbureaux <sylvain.desbureaux@orange.com> | 2020-12-01 15:39:12 +0000 |
commit | 775b166148ff8f4abb2e667a9824a66f5bd674c0 (patch) | |
tree | a05e4e7f4452dcf0be0a97aaadf50456ac73e098 /kubernetes/consul/charts/consul-server/templates/statefulset.yaml | |
parent | 30d1d3a6eff0985ac1553da015c04f063d1607cc (diff) |
[CONSUL] Make consul run as non-root
Use our recently build consul image (still based on the same old
consul version) and modify the deployment to make sure that it is able
to run as non-root user.
Yes, I know that moving consul-server to component would be more
proper solution but as this commit is supposed to be cherry-picked to
guilin I've tried to make as little changes as possible.
Issue-ID: REQ-362
Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com>
Change-Id: Idfc09ee225d4f89bb699683fa5e4ae3b86491c08
Diffstat (limited to 'kubernetes/consul/charts/consul-server/templates/statefulset.yaml')
-rw-r--r-- | kubernetes/consul/charts/consul-server/templates/statefulset.yaml | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/kubernetes/consul/charts/consul-server/templates/statefulset.yaml b/kubernetes/consul/charts/consul-server/templates/statefulset.yaml index 430b6dd1bd..872ef13f95 100644 --- a/kubernetes/consul/charts/consul-server/templates/statefulset.yaml +++ b/kubernetes/consul/charts/consul-server/templates/statefulset.yaml @@ -42,6 +42,9 @@ spec: containers: - name: {{ include "common.name" . }} image: "{{ include "common.repository" . }}/{{ .Values.image }}" + securityContext: + runAsUser: {{ .Values.securityContext.runAsUser }} + runAsGroup: {{ .Values.securityContext.runAsGroup }} command: ["/usr/local/bin/docker-entrypoint.sh"] args: - "agent" |