mirror of
https://github.com/bitnami/charts.git
synced 2026-03-05 06:47:25 +08:00
[bitnami/mongodb-sharded] feat: ✨ 🔒 Add automatic adaptation for Openshift restricted-v2 SCC (#24125)
Signed-off-by: Javier Salmeron Garcia <jsalmeron@vmware.com>
This commit is contained in:
committed by
GitHub
parent
5c72ce68ae
commit
a745214b88
@@ -1,6 +1,6 @@
|
||||
dependencies:
|
||||
- name: common
|
||||
repository: oci://registry-1.docker.io/bitnamicharts
|
||||
version: 2.16.1
|
||||
digest: sha256:f808a6fdc9c374d158ad7ff2f2c53a6c409e41da778d768b232dd20f86ef8b47
|
||||
generated: "2024-02-21T14:57:16.335067122Z"
|
||||
version: 2.18.0
|
||||
digest: sha256:f489ae7394a4eceb24fb702901483c67a5b4fff605f19d5e2545e3a6778e1280
|
||||
generated: "2024-03-05T14:57:12.782866744+01:00"
|
||||
|
||||
@@ -35,4 +35,4 @@ maintainers:
|
||||
name: mongodb-sharded
|
||||
sources:
|
||||
- https://github.com/bitnami/charts/tree/main/bitnami/mongodb-sharded
|
||||
version: 7.8.1
|
||||
version: 7.9.0
|
||||
|
||||
@@ -61,11 +61,12 @@ The command removes all the Kubernetes components associated with the chart and
|
||||
|
||||
### Global parameters
|
||||
|
||||
| Name | Description | Value |
|
||||
| ------------------------- | ----------------------------------------------- | ----- |
|
||||
| `global.imageRegistry` | Global Docker image registry | `""` |
|
||||
| `global.imagePullSecrets` | Global Docker registry secret names as an array | `[]` |
|
||||
| `global.storageClass` | Global storage class for dynamic provisioning | `""` |
|
||||
| Name | Description | Value |
|
||||
| ----------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------- |
|
||||
| `global.imageRegistry` | Global Docker image registry | `""` |
|
||||
| `global.imagePullSecrets` | Global Docker registry secret names as an array | `[]` |
|
||||
| `global.storageClass` | Global storage class for dynamic provisioning | `""` |
|
||||
| `global.compatibility.openshift.adaptSecurityContext` | Adapt the securityContext sections of the deployment to make them compatible with Openshift restricted-v2 SCC: remove runAsUser, runAsGroup and fsGroup and let the platform use their allowed default IDs. Possible values: auto (apply if the detected running cluster is Openshift), force (perform the adaptation always), disabled (do not perform adaptation) | `disabled` |
|
||||
|
||||
### Common parameters
|
||||
|
||||
|
||||
@@ -67,7 +67,7 @@ spec:
|
||||
topologySpreadConstraints: {{- include "common.tplvalues.render" (dict "value" .Values.configsvr.topologySpreadConstraints "context" $) | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- if .Values.configsvr.podSecurityContext.enabled }}
|
||||
securityContext: {{- omit .Values.configsvr.podSecurityContext "enabled" | toYaml | nindent 8 }}
|
||||
securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.configsvr.podSecurityContext "context" $) | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- if .Values.configsvr.terminationGracePeriodSeconds }}
|
||||
terminationGracePeriodSeconds: {{ .Values.configsvr.terminationGracePeriodSeconds }}
|
||||
@@ -114,7 +114,7 @@ spec:
|
||||
image: {{ include "mongodb-sharded.image" . }}
|
||||
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||
{{- if .Values.configsvr.containerSecurityContext.enabled }}
|
||||
securityContext: {{- omit .Values.configsvr.containerSecurityContext "enabled" | toYaml | nindent 12 }}
|
||||
securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.configsvr.containerSecurityContext "context" $) | nindent 12 }}
|
||||
{{- end }}
|
||||
ports:
|
||||
- containerPort: {{ .Values.common.containerPorts.mongodb }}
|
||||
@@ -306,7 +306,7 @@ spec:
|
||||
image: {{ include "mongodb-sharded.metrics.image" . }}
|
||||
imagePullPolicy: {{ .Values.metrics.image.pullPolicy | quote }}
|
||||
{{- if .Values.metrics.containerSecurityContext.enabled }}
|
||||
securityContext: {{- omit .Values.metrics.containerSecurityContext "enabled" | toYaml | nindent 12 }}
|
||||
securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.metrics.containerSecurityContext "context" $) | nindent 12 }}
|
||||
{{- end }}
|
||||
env:
|
||||
{{- if .Values.auth.enabled }}
|
||||
|
||||
@@ -71,7 +71,7 @@ spec:
|
||||
topologySpreadConstraints: {{- include "common.tplvalues.render" (dict "value" .Values.mongos.topologySpreadConstraints "context" $) | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- if .Values.mongos.podSecurityContext.enabled }}
|
||||
securityContext: {{- omit .Values.mongos.podSecurityContext "enabled" | toYaml | nindent 8 }}
|
||||
securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.mongos.podSecurityContext "context" $) | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- if .Values.mongos.terminationGracePeriodSeconds }}
|
||||
terminationGracePeriodSeconds: {{ .Values.mongos.terminationGracePeriodSeconds }}
|
||||
@@ -91,7 +91,7 @@ spec:
|
||||
image: {{ include "mongodb-sharded.image" . }}
|
||||
imagePullPolicy: {{ .Values.image.pullPolicy | quote }}
|
||||
{{- if .Values.mongos.containerSecurityContext.enabled }}
|
||||
securityContext: {{- omit .Values.mongos.containerSecurityContext "enabled" | toYaml | nindent 12 }}
|
||||
securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.mongos.containerSecurityContext "context" $) | nindent 12 }}
|
||||
{{- end }}
|
||||
env:
|
||||
- name: MONGODB_ENABLE_NUMACTL
|
||||
@@ -269,7 +269,7 @@ spec:
|
||||
image: {{ include "mongodb-sharded.metrics.image" . }}
|
||||
imagePullPolicy: {{ .Values.metrics.image.pullPolicy | quote }}
|
||||
{{- if .Values.metrics.containerSecurityContext.enabled }}
|
||||
securityContext: {{- omit .Values.metrics.containerSecurityContext "enabled" | toYaml | nindent 12 }}
|
||||
securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.metrics.containerSecurityContext "context" $) | nindent 12 }}
|
||||
{{- end }}
|
||||
env:
|
||||
{{- if $.Values.auth.enabled }}
|
||||
|
||||
@@ -70,7 +70,7 @@ spec:
|
||||
topologySpreadConstraints: {{- include "common.tplvalues.render" (dict "value" $.Values.shardsvr.arbiter.topologySpreadConstraints "context" $) | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- if $.Values.shardsvr.arbiter.podSecurityContext.enabled }}
|
||||
securityContext: {{- omit $.Values.shardsvr.arbiter.podSecurityContext "enabled" | toYaml | nindent 8 }}
|
||||
securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" $.Values.shardsvr.arbiter.podSecurityContext "context" $) | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- if $.Values.shardsvr.arbiter.terminationGracePeriodSeconds }}
|
||||
terminationGracePeriodSeconds: {{ $.Values.shardsvr.arbiter.terminationGracePeriodSeconds }}
|
||||
@@ -90,7 +90,7 @@ spec:
|
||||
image: {{ include "mongodb-sharded.image" $ }}
|
||||
imagePullPolicy: {{ $.Values.image.pullPolicy }}
|
||||
{{- if $.Values.shardsvr.arbiter.containerSecurityContext.enabled }}
|
||||
securityContext: {{- omit $.Values.shardsvr.arbiter.containerSecurityContext "enabled" | toYaml | nindent 12 }}
|
||||
securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" $.Values.shardsvr.arbiter.containerSecurityContext "context" $) | nindent 12 }}
|
||||
{{- end }}
|
||||
ports:
|
||||
- containerPort: {{ $.Values.common.containerPorts.mongodb }}
|
||||
@@ -272,7 +272,7 @@ spec:
|
||||
image: {{ include "mongodb-sharded.metrics.image" $ }}
|
||||
imagePullPolicy: {{ $.Values.metrics.image.pullPolicy | quote }}
|
||||
{{- if $.Values.metrics.containerSecurityContext.enabled }}
|
||||
securityContext: {{- omit $.Values.metrics.containerSecurityContext "enabled" | toYaml | nindent 12 }}
|
||||
securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" $.Values.metrics.containerSecurityContext "context" $) | nindent 12 }}
|
||||
{{- end }}
|
||||
env:
|
||||
{{- if $.Values.auth.enabled }}
|
||||
|
||||
@@ -70,7 +70,7 @@ spec:
|
||||
topologySpreadConstraints: {{- include "common.tplvalues.render" (dict "value" $.Values.shardsvr.dataNode.topologySpreadConstraints "context" $) | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- if $.Values.shardsvr.dataNode.podSecurityContext.enabled }}
|
||||
securityContext: {{- omit $.Values.shardsvr.dataNode.podSecurityContext "enabled" | toYaml | nindent 8 }}
|
||||
securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" $.Values.shardsvr.dataNode.podSecurityContext "context" $) | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- if $.Values.shardsvr.dataNode.terminationGracePeriodSeconds }}
|
||||
terminationGracePeriodSeconds: {{ $.Values.shardsvr.dataNode.terminationGracePeriodSeconds }}
|
||||
@@ -117,7 +117,7 @@ spec:
|
||||
image: {{ include "mongodb-sharded.image" $ }}
|
||||
imagePullPolicy: {{ $.Values.image.pullPolicy }}
|
||||
{{- if $.Values.shardsvr.dataNode.containerSecurityContext.enabled }}
|
||||
securityContext: {{- omit $.Values.shardsvr.dataNode.containerSecurityContext "enabled" | toYaml | nindent 12 }}
|
||||
securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" $.Values.shardsvr.dataNode.containerSecurityContext "context" $) | nindent 12 }}
|
||||
{{- end }}
|
||||
ports:
|
||||
- containerPort: {{ $.Values.common.containerPorts.mongodb }}
|
||||
@@ -313,7 +313,7 @@ spec:
|
||||
image: {{ include "mongodb-sharded.metrics.image" $ }}
|
||||
imagePullPolicy: {{ $.Values.metrics.image.pullPolicy | quote }}
|
||||
{{- if $.Values.metrics.containerSecurityContext.enabled }}
|
||||
securityContext: {{- omit $.Values.metrics.containerSecurityContext "enabled" | toYaml | nindent 12 }}
|
||||
securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" $.Values.metrics.containerSecurityContext "context" $) | nindent 12 }}
|
||||
{{- end }}
|
||||
env:
|
||||
{{- if $.Values.auth.enabled }}
|
||||
|
||||
@@ -19,6 +19,15 @@ global:
|
||||
##
|
||||
imagePullSecrets: []
|
||||
storageClass: ""
|
||||
## Compatibility adaptations for Kubernetes platforms
|
||||
##
|
||||
compatibility:
|
||||
## Compatibility adaptations for Openshift
|
||||
##
|
||||
openshift:
|
||||
## @param global.compatibility.openshift.adaptSecurityContext Adapt the securityContext sections of the deployment to make them compatible with Openshift restricted-v2 SCC: remove runAsUser, runAsGroup and fsGroup and let the platform use their allowed default IDs. Possible values: auto (apply if the detected running cluster is Openshift), force (perform the adaptation always), disabled (do not perform adaptation)
|
||||
##
|
||||
adaptSecurityContext: disabled
|
||||
## @section Common parameters
|
||||
##
|
||||
|
||||
|
||||
Reference in New Issue
Block a user