postgres-operator icon indicating copy to clipboard operation
postgres-operator copied to clipboard

Custom Security Context in postgresql

Open olivejing opened this issue 2 years ago • 8 comments

  • **Which image of the operator are you using? postgres-operator:v1.9.0
  • **Where do you run it - cloud or metal? Kubernetes and OpenShift
  • Type of issue? feature request

Hi, i checked postgres operator configuration and postgresql manifest, there is no parameter to custom SecurityContext. Parameter additional_pod_capabilities only supports adding capabilities in container level SecurityContex. Actually, i want to custom pod level and container lever SecurityContext, example:

pod level SecurityContext:

        securityContext:
          fsGroup: 7777
          runAsNonRoot: true
          runAsUser: 7777

container level SecurityContext:

          securityContext:
            allowPrivilegeEscalation: false
            capabilities:
              drop:
              - ALL
            privileged: false
            readOnlyRootFilesystem: true
            seccompProfile:
              type: RuntimeDefault

olivejing avatar Feb 16 '23 02:02 olivejing