security: drop all capabilities to the container
adding drop `ALL` capabilities in rook operator container as this is not required and will remove warning in ocp cluster. Signed-off-by: subhamkrai <srai@redhat.com>
This commit is contained in:
1 parent
a2e3d30526
commit
48f84b37e8
5 files changed
+18
-2
No files matched your search
@@ -567,8 +567,7 @@ spec:
|
||||
runAsUser: 2016
|
||||
runAsGroup: 2016
|
||||
capabilities:
|
||||
drop:
|
||||
- ALL
|
||||
drop: ["ALL"]
|
||||
volumeMounts:
|
||||
- mountPath: /var/lib/rook
|
||||
name: rook-config
|
||||
|
||||
@@ -91,6 +91,8 @@ spec:
|
||||
runAsNonRoot: true
|
||||
runAsUser: 2016
|
||||
runAsGroup: 2016
|
||||
capabilities:
|
||||
drop: ["ALL"]
|
||||
env:
|
||||
- name: ROOK_CEPH_USERNAME
|
||||
valueFrom:
|
||||
|
||||
@@ -33,6 +33,8 @@ spec:
|
||||
# created by privileged CSI driver container.
|
||||
securityContext:
|
||||
privileged: true
|
||||
capabilities:
|
||||
drop: ["ALL"]
|
||||
image: {{ .RegistrarImage }}
|
||||
imagePullPolicy: {{ .ImagePullPolicy }}
|
||||
args:
|
||||
@@ -54,6 +56,7 @@ spec:
|
||||
privileged: true
|
||||
capabilities:
|
||||
add: ["SYS_ADMIN"]
|
||||
drop: ["ALL"]
|
||||
allowPrivilegeEscalation: true
|
||||
image: {{ .CSIPluginImage }}
|
||||
args:
|
||||
@@ -123,6 +126,8 @@ spec:
|
||||
- name: liveness-prometheus
|
||||
securityContext:
|
||||
privileged: true
|
||||
capabilities:
|
||||
drop: ["ALL"]
|
||||
image: {{ .CSIPluginImage }}
|
||||
args:
|
||||
- "--type=liveness"
|
||||
|
||||
@@ -31,6 +31,8 @@ spec:
|
||||
# non-privileged sidecar containers cannot access unix domain socket
|
||||
# created by privileged CSI driver container.
|
||||
securityContext:
|
||||
capabilities:
|
||||
drop: ["ALL"]
|
||||
privileged: true
|
||||
image: {{ .RegistrarImage }}
|
||||
imagePullPolicy: {{ .ImagePullPolicy }}
|
||||
@@ -54,6 +56,7 @@ spec:
|
||||
capabilities:
|
||||
add:
|
||||
- SYS_ADMIN
|
||||
drop: ["ALL"]
|
||||
privileged: true
|
||||
args:
|
||||
- "--nodeid=$(NODE_ID)"
|
||||
|
||||
@@ -38,6 +38,8 @@ spec:
|
||||
# created by privileged CSI driver container.
|
||||
securityContext:
|
||||
privileged: true
|
||||
capabilities:
|
||||
drop: ["ALL"]
|
||||
image: {{ .RegistrarImage }}
|
||||
imagePullPolicy: {{ .ImagePullPolicy }}
|
||||
args:
|
||||
@@ -59,6 +61,7 @@ spec:
|
||||
privileged: true
|
||||
capabilities:
|
||||
add: ["SYS_ADMIN"]
|
||||
drop: ["ALL"]
|
||||
allowPrivilegeEscalation: true
|
||||
image: {{ .CSIPluginImage }}
|
||||
args :
|
||||
@@ -148,6 +151,8 @@ spec:
|
||||
- name: csi-addons
|
||||
securityContext:
|
||||
privileged: true
|
||||
capabilities:
|
||||
drop: ["ALL"]
|
||||
image: {{ .CSIAddonsImage }}
|
||||
args :
|
||||
- "--node-id=$(NODE_ID)"
|
||||
@@ -188,6 +193,8 @@ spec:
|
||||
- name: liveness-prometheus
|
||||
securityContext:
|
||||
privileged: true
|
||||
capabilities:
|
||||
drop: ["ALL"]
|
||||
image: {{ .CSIPluginImage }}
|
||||
args:
|
||||
- "--type=liveness"
|
||||
|
||||
Reference in new issue
Block a user