- Sort Score
- Result 10 results
- Languages All
Results 1 - 4 of 4 for GetValidationOptionsFromPodSpecAndMeta (0.62 sec)
-
pkg/api/testing/backward_compatibility_test.go
}] } } `, absentKeys: []string{ "spec.hostPID", }, }, } validator := func(obj runtime.Object) field.ErrorList { opts := podutil.GetValidationOptionsFromPodSpecAndMeta(&(obj.(*api.Pod).Spec), nil, &(obj.(*api.Pod).ObjectMeta), nil) return validation.ValidatePodSpec(&(obj.(*api.Pod).Spec), &(obj.(*api.Pod).ObjectMeta), field.NewPath("spec"), opts) }
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Mon Mar 01 18:45:58 UTC 2021 - 3.5K bytes - Viewed (0) -
pkg/registry/core/pod/strategy.go
} // Validate validates a new pod. func (podStrategy) Validate(ctx context.Context, obj runtime.Object) field.ErrorList { pod := obj.(*api.Pod) opts := podutil.GetValidationOptionsFromPodSpecAndMeta(&pod.Spec, nil, &pod.ObjectMeta, nil) opts.ResourceIsPod = true return corevalidation.ValidatePodCreate(pod, opts) } // WarningsOnCreate returns warnings for the creation of the given object.
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Thu Mar 07 17:51:48 UTC 2024 - 29.8K bytes - Viewed (0) -
pkg/api/pod/util.go
if len(errs) != 0 { return true } } } } return false } // GetValidationOptionsFromPodSpecAndMeta returns validation options based on pod specs and metadata func GetValidationOptionsFromPodSpecAndMeta(podSpec, oldPodSpec *api.PodSpec, podMeta, oldPodMeta *metav1.ObjectMeta) apivalidation.PodValidationOptions { // default pod validation options based on feature gate
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed May 29 22:40:29 UTC 2024 - 41.3K bytes - Viewed (0) -
pkg/api/pod/util_test.go
featuregatetesting.SetFeatureGateDuringTest(t, utilfeature.DefaultFeatureGate, features.PodDeletionCost, tc.featureEnabled) // The new pod doesn't impact the outcome. gotOptions := GetValidationOptionsFromPodSpecAndMeta(nil, nil, nil, tc.oldPodMeta) if tc.wantAllowInvalidPodDeletionCost != gotOptions.AllowInvalidPodDeletionCost {
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed May 29 22:40:29 UTC 2024 - 108.8K bytes - Viewed (0)