Rename FG to `ValidatingAdmissionPolicy`
Kubernetes-commit: 29737124860b1414affa07ed6db30fccdbae3b55
This commit is contained in:
parent
55bc692e10
commit
47687312f4
|
@ -109,7 +109,7 @@ func (c *celAdmissionPlugin) SetDrainedNotification(stopCh <-chan struct{}) {
|
|||
}
|
||||
|
||||
func (c *celAdmissionPlugin) InspectFeatureGates(featureGates featuregate.FeatureGate) {
|
||||
if featureGates.Enabled(features.CELValidatingAdmission) {
|
||||
if featureGates.Enabled(features.ValidatingAdmissionPolicy) {
|
||||
c.enabled = true
|
||||
}
|
||||
c.inspectedFeatureGates = true
|
||||
|
|
|
@ -249,13 +249,13 @@ func setupTestCommon(t *testing.T, compiler ValidatorCompiler, shouldStartInform
|
|||
fakeInformerFactory := informers.NewSharedInformerFactory(fakeClient, time.Second)
|
||||
featureGate := featuregate.NewFeatureGate()
|
||||
err := featureGate.Add(map[featuregate.Feature]featuregate.FeatureSpec{
|
||||
features.CELValidatingAdmission: {
|
||||
features.ValidatingAdmissionPolicy: {
|
||||
Default: true, PreRelease: featuregate.Alpha}})
|
||||
if err != nil {
|
||||
// FIXME: handle error.
|
||||
panic("Unexpected error")
|
||||
}
|
||||
err = featureGate.SetFromMap(map[string]bool{string(features.CELValidatingAdmission): true})
|
||||
err = featureGate.SetFromMap(map[string]bool{string(features.ValidatingAdmissionPolicy): true})
|
||||
if err != nil {
|
||||
// FIXME: handle error.
|
||||
panic("Unexpected error.")
|
||||
|
|
|
@ -93,7 +93,7 @@ const (
|
|||
// alpha: v1.26
|
||||
//
|
||||
// Enables expression validation in Admission Control
|
||||
CELValidatingAdmission featuregate.Feature = "CELValidatingAdmission"
|
||||
ValidatingAdmissionPolicy featuregate.Feature = "ValidatingAdmissionPolicy"
|
||||
|
||||
// owner: @cici37
|
||||
// kep: https://kep.k8s.io/2876
|
||||
|
@ -222,7 +222,7 @@ var defaultKubernetesFeatureGates = map[featuregate.Feature]featuregate.FeatureS
|
|||
|
||||
AdvancedAuditing: {Default: true, PreRelease: featuregate.GA},
|
||||
|
||||
CELValidatingAdmission: {Default: false, PreRelease: featuregate.Alpha},
|
||||
ValidatingAdmissionPolicy: {Default: false, PreRelease: featuregate.Alpha},
|
||||
|
||||
CustomResourceValidationExpressions: {Default: true, PreRelease: featuregate.Beta},
|
||||
|
||||
|
|
Loading…
Reference in New Issue