mirror of
https://github.com/FairwindsOps/polaris.git
synced 2026-05-21 08:33:55 +00:00
fix comments
This commit is contained in:
@@ -13,7 +13,7 @@ import (
|
||||
"sigs.k8s.io/controller-runtime/pkg/webhook/admission/types"
|
||||
)
|
||||
|
||||
// Validator validates Pods
|
||||
// Validator validates k8s resources.
|
||||
type Validator struct {
|
||||
client client.Client
|
||||
decoder types.Decoder
|
||||
@@ -38,7 +38,7 @@ func (v *Validator) InjectDecoder(d types.Decoder) error {
|
||||
|
||||
var _ admission.Handler = &Validator{}
|
||||
|
||||
// Handle for DeployValidator admits a deploy if validation passes.
|
||||
// Handle for Validator to run validation checks.
|
||||
func (v *Validator) Handle(ctx context.Context, req types.Request) types.Response {
|
||||
deploy := appsv1.Deployment{}
|
||||
err := v.decoder.Decode(req, &deploy)
|
||||
|
||||
Reference in New Issue
Block a user