@@ -127,14 +127,12 @@ func (s *csiNodeSyncer) ensureContainersSpec() []corev1.Container {
127
127
})
128
128
129
129
nodePlugin .SecurityContext = & corev1.SecurityContext {
130
- RunAsNonRoot : util .False (),
131
- Privileged : util .True (),
132
- AllowPrivilegeEscalation : util .True (),
133
- RunAsUser : func (uid int64 ) * int64 { return & uid }(0 ),
130
+ RunAsNonRoot : util .False (),
131
+ Privileged : util .True (),
132
+ RunAsUser : func (uid int64 ) * int64 { return & uid }(0 ),
134
133
}
135
134
fillSecurityContextCapabilities (
136
135
nodePlugin .SecurityContext ,
137
- "SYS_ADMIN" ,
138
136
)
139
137
140
138
// node driver registrar sidecar
@@ -162,7 +160,10 @@ func (s *csiNodeSyncer) ensureContainersSpec() []corev1.Container {
162
160
healthPortArg ,
163
161
},
164
162
)
165
- livenessProbe .SecurityContext = & corev1.SecurityContext {AllowPrivilegeEscalation : util .False ()}
163
+ livenessProbe .SecurityContext = & corev1.SecurityContext {RunAsNonRoot : util .False (),
164
+ RunAsUser : func (uid int64 ) * int64 { return & uid }(0 ),
165
+ Privileged : util .False (),
166
+ }
166
167
fillSecurityContextCapabilities (livenessProbe .SecurityContext )
167
168
livenessProbe .ImagePullPolicy = s .getCSINodeDriverRegistrarPullPolicy ()
168
169
livenessProbe .Resources = getSidecarResourceRequests (s .driver , constants .LivenessProbe )
0 commit comments