Created
January 14, 2025 05:32
-
-
Save ihcsim/96d42c4a5bcae8330e5a7aefc1736e63 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
func (v *validator) Validate(ctx context.Context, matchedResource schema.GroupVersionResource, versionedAttr *admission.VersionedAttributes, versionedParams runtime.Object, namespace *corev1.Namespace, runtimeCELCostBudget int64, authz authorizer.Authorizer) ValidateResult { | |
// ... | |
evalResults, remainingBudget, err := v.validationFilter.ForInput(ctx, versionedAttr, admissionRequest, optionalVars, ns, runtimeCELCostBudget) | |
if err != nil { | |
return ValidateResult{ | |
Decisions: []PolicyDecision{ | |
{ | |
Action: policyDecisionActionForError(f), | |
Evaluation: EvalError, | |
Message: err.Error(), | |
}, | |
}, | |
} | |
} | |
// ... | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment