mirror of
https://github.com/bitnami/charts.git
synced 2026-02-28 15:37:42 +08:00
[bitnami/apisix] Skip check-no-capabilities test when securityContext disabled (#18469)
Signed-off-by: Miguel Ruiz <miruiz@vmware.com>
This commit is contained in:
@@ -94,6 +94,7 @@ command:
|
||||
# or the one randomly defined by openshift (larger values). Otherwise, the chart is still using the default value.
|
||||
exec: if [ $(id -u) -lt {{ $uid }} ] || [ $(id -G | awk '{print $2}') -lt {{ $gid }} ]; then exit 1; fi
|
||||
exit-status: 0
|
||||
{{- if .Vars.dataPlane.containerSecurityContext.enabled }}
|
||||
check-no-capabilities:
|
||||
exec: cat /proc/1/status
|
||||
exit-status: 0
|
||||
@@ -103,6 +104,7 @@ command:
|
||||
- "CapEff: 0000000000000000"
|
||||
- "CapBnd: 0000000000000000"
|
||||
- "CapAmb: 0000000000000000"
|
||||
{{- end }}
|
||||
{{ if .Vars.dataPlane.serviceAccount.automountServiceAccountToken }}
|
||||
check-sa:
|
||||
exec: cat /var/run/secrets/kubernetes.io/serviceaccount/token | cut -d '.' -f 2 | xargs -I '{}' echo '{}====' | fold -w 4 | sed '$ d' | tr -d '\n' | base64 -d
|
||||
|
||||
Reference in New Issue
Block a user