diff --git a/bitnami/memcached/Chart.yaml b/bitnami/memcached/Chart.yaml index ff990d40ff..b2c2e34df2 100644 --- a/bitnami/memcached/Chart.yaml +++ b/bitnami/memcached/Chart.yaml @@ -1,5 +1,5 @@ name: memcached -version: 1.0.2 +version: 1.1.0 appVersion: 1.5.11 description: Chart for Memcached keywords: diff --git a/bitnami/memcached/README.md b/bitnami/memcached/README.md index 2ce795ea57..93e97395eb 100644 --- a/bitnami/memcached/README.md +++ b/bitnami/memcached/README.md @@ -45,17 +45,20 @@ The command removes all the Kubernetes components associated with the chart and The following tables lists the configurable parameters of the Memcached chart and their default values. -| Parameter | Description | Default | -|---------------------|-------------------------------------|---------------------------------------------------------- | -| `image.registry` | Memcached image registry | `docker.io` | -| `image.repository` | Memcached Image name | `bitnami/memcached` | -| `image.tag` | Memcached Image tag | `{VERSION}` | -| `image.pullPolicy` | Memcached image pull policy | `Always` if `imageTag` is `latest`, else `IfNotPresent` | -| `image.pullSecrets` | Specify image pull secrets | `nil` (does not add image pull secrets to deployed pods) | -| `memcachedUsername` | Memcached admin user | `nil` | -| `memcachedPassword` | Memcached admin password | `nil` | -| `serviceType` | Kubernetes Service type | `ClusterIP` | -| `resources` | CPU/Memory resource requests/limits | Memory: `256Mi`, CPU: `250m` | +| Parameter | Description | Default | +|-----------------------------|-------------------------------------|---------------------------------------------------------- | +| `image.registry` | Memcached image registry | `docker.io` | +| `image.repository` | Memcached Image name | `bitnami/memcached` | +| `image.tag` | Memcached Image tag | `{VERSION}` | +| `image.pullPolicy` | Memcached image pull policy | `Always` if `imageTag` is `latest`, else `IfNotPresent` | +| `image.pullSecrets` | Specify image pull secrets | `nil` (does not add image pull secrets to deployed pods) | +| `securityContext.enabled` | Enable security context | `true` | +| `securityContext.fsGroup` | Group ID for the container | `1001` | +| `securityContext.runAsUser` | User ID for the container | `1001` | +| `memcachedUsername` | Memcached admin user | `nil` | +| `memcachedPassword` | Memcached admin password | `nil` | +| `serviceType` | Kubernetes Service type | `ClusterIP` | +| `resources` | CPU/Memory resource requests/limits | Memory: `256Mi`, CPU: `250m` | The above parameters map to the env variables defined in [bitnami/memcached](http://github.com/bitnami/bitnami-docker-memcached). For more information please refer to the [bitnami/memcached](http://github.com/bitnami/bitnami-docker-memcached) image documentation. diff --git a/bitnami/memcached/templates/deployment.yaml b/bitnami/memcached/templates/deployment.yaml index aa5852ac2c..5e0344ec18 100644 --- a/bitnami/memcached/templates/deployment.yaml +++ b/bitnami/memcached/templates/deployment.yaml @@ -19,6 +19,11 @@ spec: chart: "{{ .Chart.Name }}-{{ .Chart.Version }}" release: "{{ .Release.Name }}" spec: + {{- if .Values.securityContext.enabled }} + securityContext: + fsGroup: {{ .Values.securityContext.fsGroup }} + runAsUser: {{ .Values.securityContext.runAsUser }} + {{- end }} {{- if .Values.image.pullSecrets }} imagePullSecrets: {{- range .Values.image.pullSecrets }} diff --git a/bitnami/memcached/values.yaml b/bitnami/memcached/values.yaml index 20674598b4..bd20d1d22a 100644 --- a/bitnami/memcached/values.yaml +++ b/bitnami/memcached/values.yaml @@ -15,7 +15,15 @@ image: ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ ## # pullSecrets: - # - myRegistrKeySecretName + # - myRegistrKeySecretName + +## Pod Security Context +## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ +## +securityContext: + enabled: true + fsGroup: 1001 + runAsUser: 1001 ## Specify a imagePullPolicy ## ref: http://kubernetes.io/docs/user-guide/images/#pre-pulling-images