Skip to content
This repository has been archived by the owner on Apr 25, 2024. It is now read-only.

Commit

Permalink
Merge pull request #76 from FabianKramm/refactor
Browse files Browse the repository at this point in the history
fix: account quota error with pvcs
  • Loading branch information
FabianKramm authored Jul 10, 2020
2 parents f6fb39f + 0b45cd5 commit 07ada32
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions kube/pkg/quota/v1/evaluator/core/persistent_volume_claims.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,9 @@ import (
"k8s.io/apimachinery/pkg/runtime"
"k8s.io/apimachinery/pkg/runtime/schema"
"k8s.io/apiserver/pkg/admission"
utilfeature "k8s.io/apiserver/pkg/util/feature"
"k8s.io/component-base/featuregate"
)


// owner: @gnufied
// beta: v1.11
// Ability to Expand persistent volumes
Expand Down Expand Up @@ -94,7 +92,7 @@ func (p *pvcEvaluator) Handles(a admission.Attributes) bool {
if op == admission.Create {
return true
}
if op == admission.Update && utilfeature.DefaultFeatureGate.Enabled(ExpandPersistentVolumes) {
if op == admission.Update {
return true
}
return false
Expand Down Expand Up @@ -203,4 +201,4 @@ func toExternalPersistentVolumeClaimOrError(obj runtime.Object) (*corev1.Persist
return nil, fmt.Errorf("expect *api.PersistentVolumeClaim or *v1.PersistentVolumeClaim, got %v", t)
}
return pvc, nil
}
}

0 comments on commit 07ada32

Please sign in to comment.