psp.yaml 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. {{- /*
  2. Copyright VMware, Inc.
  3. SPDX-License-Identifier: APACHE-2.0
  4. */}}
  5. {{- if and (include "common.capabilities.psp.supported" .) .Values.psp.create }}
  6. apiVersion: policy/v1beta1
  7. kind: PodSecurityPolicy
  8. metadata:
  9. name: {{ include "common.names.fullname" . }}
  10. namespace: {{ .Release.Namespace | quote }}
  11. labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }}
  12. {{- if .Values.commonAnnotations }}
  13. annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }}
  14. {{- end }}
  15. spec:
  16. privileged: false
  17. volumes:
  18. - 'configMap'
  19. - 'secret'
  20. - 'persistentVolumeClaim'
  21. - 'emptyDir'
  22. - 'projected'
  23. hostNetwork: false
  24. hostIPC: false
  25. hostPID: false
  26. runAsUser:
  27. rule: 'RunAsAny'
  28. seLinux:
  29. rule: 'RunAsAny'
  30. supplementalGroups:
  31. rule: 'MustRunAs'
  32. ranges:
  33. - min: 1
  34. max: 65535
  35. fsGroup:
  36. rule: 'MustRunAs'
  37. ranges:
  38. - min: 1
  39. max: 65535
  40. readOnlyRootFilesystem: false
  41. {{- end }}