mirror of
https://github.com/k3s-io/kubernetes.git
synced 2026-01-05 23:47:50 +00:00
Drop RuntimeClass from PSP when feature is disabled
This commit is contained in:
@@ -38,6 +38,10 @@ func DropDisabledFields(pspSpec, oldPSPSpec *policy.PodSecurityPolicySpec) {
|
||||
if !utilfeature.DefaultFeatureGate.Enabled(features.CSIInlineVolume) {
|
||||
pspSpec.AllowedCSIDrivers = nil
|
||||
}
|
||||
if !utilfeature.DefaultFeatureGate.Enabled(features.RuntimeClass) &&
|
||||
(oldPSPSpec == nil || oldPSPSpec.RuntimeClass == nil) {
|
||||
pspSpec.RuntimeClass = nil
|
||||
}
|
||||
}
|
||||
|
||||
func allowedProcMountTypesInUse(oldPSPSpec *policy.PodSecurityPolicySpec) bool {
|
||||
|
||||
Reference in New Issue
Block a user