Is there a way to default a security group context for all persistent volume claims that get created in a project

10/3/2019

I've got an Openshift project dedicated for an application. All the persistent volume claims (pvc's) in my project bind to an NFS Persistent Volume (PV).

For the my pvc's to work properly I need to define a security context in my yaml files...

securityContext:
  supplementalGroups:
  - 5555

The problem is I'm using an operator to create my pvc's and they don't have support for specifying a securtyContext.

Is there a way i can tell Openshift to default a security context as above for all the pvc's that get created in my project?

That would solve my issue.

thanks

-- Richie
kubernetes
openshift

0 Answers