Run pod in a privileged securityContext.

This is necessary in order to access devices from the pod.
The target is to be able to run resize2fs on a pod itself.
This commit is contained in:
Oleksii Kliukin
2017-05-12 11:41:29 +02:00
committed by Murat Kabilov
parent 701fa729de
commit 19dfa0c2b0
+4 -1
View File
@@ -105,7 +105,7 @@ bootstrap:
- hostssl all all all md5`, pgVersion, c.OpConfig.PamRoleName, c.OpConfig.PamRoleName),
},
}
privilegedMode := bool(true)
container := v1.Container{
Name: c.Metadata.Name,
Image: c.OpConfig.DockerImage,
@@ -134,6 +134,9 @@ bootstrap:
},
},
Env: envVars,
SecurityContext: &v1.SecurityContext{
Privileged: &privilegedMode,
},
}
terminateGracePeriodSeconds := int64(30)