From 4066caff6ccc8bbfec84f8ddd634aef052e50efe Mon Sep 17 00:00:00 2001 From: Sivanantham <90966311+sivanantha321@users.noreply.github.com> Date: Sat, 28 Jun 2025 21:15:33 +0530 Subject: [PATCH 1/9] refactor: Enhance HTTPRoute readiness checks (#4543) Signed-off-by: Sivanantham Chinnaiyan Signed-off-by: Dan Sun Co-authored-by: Dan Sun --- .golangci.yml | 2 + cmd/manager/main.go | 4 +- .../v1alpha1/llm_inference_service_types.go | 8 +- .../v1beta1/inferenceservice/controller.go | 12 +- .../rawkube_controller_test.go | 1688 +++++++++-------- .../ingress/httproute_reconciler.go | 391 ++-- .../ingress/httproute_reconciler_test.go | 1542 +++++++++++---- pkg/testing/envtest_setup.go | 4 +- 8 files changed, 2205 insertions(+), 1446 deletions(-) diff --git a/.golangci.yml b/.golangci.yml index 6de546cefb4..0abd3965863 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -216,3 +216,5 @@ linters-settings: alias: "ctrl" - pkg: "sigs.k8s.io/controller-runtime/runtime" alias: "runtime" + - pkg: "sigs.k8s.io/gateway-api/apis/v1" + alias: "gwapiv1" diff --git a/cmd/manager/main.go b/cmd/manager/main.go index ac88d8016d8..0175b3b2a7b 100644 --- a/cmd/manager/main.go +++ b/cmd/manager/main.go @@ -40,7 +40,7 @@ import ( metricsserver "sigs.k8s.io/controller-runtime/pkg/metrics/server" "sigs.k8s.io/controller-runtime/pkg/webhook" "sigs.k8s.io/controller-runtime/pkg/webhook/admission" - gatewayapiv1 "sigs.k8s.io/gateway-api/apis/v1" + gwapiv1 "sigs.k8s.io/gateway-api/apis/v1" "github.com/kserve/kserve/pkg/apis/serving/v1alpha1" "github.com/kserve/kserve/pkg/apis/serving/v1beta1" @@ -229,7 +229,7 @@ func main() { } setupLog.Info("Setting up gateway api scheme") - if err := gatewayapiv1.Install(mgr.GetScheme()); err != nil { + if err := gwapiv1.Install(mgr.GetScheme()); err != nil { setupLog.Error(err, "unable to add Gateway APIs to scheme") os.Exit(1) } diff --git a/pkg/apis/serving/v1alpha1/llm_inference_service_types.go b/pkg/apis/serving/v1alpha1/llm_inference_service_types.go index fc126ab8fde..c9fb37f50f6 100644 --- a/pkg/apis/serving/v1alpha1/llm_inference_service_types.go +++ b/pkg/apis/serving/v1alpha1/llm_inference_service_types.go @@ -22,7 +22,7 @@ import ( "knative.dev/pkg/apis" duckv1 "knative.dev/pkg/apis/duck/v1" igwapi "sigs.k8s.io/gateway-api-inference-extension/api/v1alpha2" - gatewayapi "sigs.k8s.io/gateway-api/apis/v1" + gwapiv1 "sigs.k8s.io/gateway-api/apis/v1" ) // LLMInferenceService is the Schema for the llminferenceservices API, representing a single LLM deployment. @@ -189,7 +189,7 @@ type HTTPRouteSpec struct { // Spec allows for providing a custom specification for an HTTPRoute. // If provided, the controller will create and manage an HTTPRoute with this specification. // +optional - Spec *gatewayapi.HTTPRouteSpec `json:"spec,omitempty"` + Spec *gwapiv1.HTTPRouteSpec `json:"spec,omitempty"` } // GatewaySpec defines the configuration for a Gateway API Gateway. @@ -272,9 +272,9 @@ type LLMStorageSpec struct { // might be inferred or is not strictly required by this controller. type UntypedObjectReference struct { // Name of the referenced object. - Name gatewayapi.ObjectName `json:"name,omitempty"` + Name gwapiv1.ObjectName `json:"name,omitempty"` // Namespace of the referenced object. - Namespace gatewayapi.Namespace `json:"namespace,omitempty"` + Namespace gwapiv1.Namespace `json:"namespace,omitempty"` } // LLMInferenceServiceStatus defines the observed state of LLMInferenceService. diff --git a/pkg/controller/v1beta1/inferenceservice/controller.go b/pkg/controller/v1beta1/inferenceservice/controller.go index 822e05c9c98..ffb836ae5b3 100644 --- a/pkg/controller/v1beta1/inferenceservice/controller.go +++ b/pkg/controller/v1beta1/inferenceservice/controller.go @@ -48,7 +48,7 @@ import ( "sigs.k8s.io/controller-runtime/pkg/handler" "sigs.k8s.io/controller-runtime/pkg/predicate" "sigs.k8s.io/controller-runtime/pkg/reconcile" - gatewayapiv1 "sigs.k8s.io/gateway-api/apis/v1" + gwapiv1 "sigs.k8s.io/gateway-api/apis/v1" "sigs.k8s.io/yaml" "github.com/kserve/kserve/pkg/apis/serving/v1alpha1" @@ -313,8 +313,10 @@ func (r *InferenceServiceReconciler) Reconcile(ctx context.Context, req ctrl.Req if ingressConfig.EnableGatewayAPI { reconciler := ingress.NewRawHTTPRouteReconciler(r.Client, r.Scheme, ingressConfig, isvcConfig) - if err := reconciler.Reconcile(ctx, isvc); err != nil { - return reconcile.Result{}, errors.Wrapf(err, "fails to reconcile ingress") + if result, err := reconciler.Reconcile(ctx, isvc); err != nil { + return result, errors.Wrapf(err, "fails to reconcile ingress") + } else if result.Requeue || result.RequeueAfter > 0 { + return result, nil } } else { reconciler, err := ingress.NewRawIngressReconciler(r.Client, r.Scheme, ingressConfig, isvcConfig) @@ -579,13 +581,13 @@ func (r *InferenceServiceReconciler) SetupWithManager(mgr ctrl.Manager, deployCo } if ingressConfig.EnableGatewayAPI { - gatewayapiFound, err := utils.IsCrdAvailable(r.ClientConfig, gatewayapiv1.GroupVersion.String(), constants.HTTPRouteKind) + gatewayapiFound, err := utils.IsCrdAvailable(r.ClientConfig, gwapiv1.GroupVersion.String(), constants.HTTPRouteKind) if err != nil { return err } if gatewayapiFound { - ctrlBuilder = ctrlBuilder.Owns(&gatewayapiv1.HTTPRoute{}) + ctrlBuilder = ctrlBuilder.Owns(&gwapiv1.HTTPRoute{}) } else { r.Log.Info("The InferenceService controller won't watch gateway.networking.k8s.io/v1/HTTPRoute resources because the CRD is not available.") panic("Gateway API CRD not available") diff --git a/pkg/controller/v1beta1/inferenceservice/rawkube_controller_test.go b/pkg/controller/v1beta1/inferenceservice/rawkube_controller_test.go index d3ea4b67516..45fccbcce98 100644 --- a/pkg/controller/v1beta1/inferenceservice/rawkube_controller_test.go +++ b/pkg/controller/v1beta1/inferenceservice/rawkube_controller_test.go @@ -44,7 +44,7 @@ import ( duckv1 "knative.dev/pkg/apis/duck/v1" "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/controller-runtime/pkg/reconcile" - gatewayapiv1 "sigs.k8s.io/gateway-api/apis/v1" + gwapiv1 "sigs.k8s.io/gateway-api/apis/v1" "github.com/kserve/kserve/pkg/apis/serving/v1alpha1" "github.com/kserve/kserve/pkg/apis/serving/v1beta1" @@ -358,7 +358,7 @@ var _ = Describe("v1beta1 inference service controller", func() { Expect(k8sClient.Status().Update(context.TODO(), updatedDeployment)).NotTo(HaveOccurred()) // check http route - actualTopLevelHttpRoute := &gatewayapiv1.HTTPRoute{} + actualTopLevelHttpRoute := &gwapiv1.HTTPRoute{} Eventually(func() error { return k8sClient.Get(context.TODO(), types.NamespacedName{ Name: serviceKey.Name, @@ -366,24 +366,24 @@ var _ = Describe("v1beta1 inference service controller", func() { }, actualTopLevelHttpRoute) }, timeout).Should(Succeed()) topLevelHost := fmt.Sprintf("%s-%s.%s", serviceKey.Name, serviceKey.Namespace, "example.com") - expectedTopLevelHttpRoute := gatewayapiv1.HTTPRoute{ - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{gatewayapiv1.Hostname(topLevelHost), gatewayapiv1.Hostname(fmt.Sprintf("%s-%s.additional.example.com", serviceKey.Name, serviceKey.Namespace))}, - Rules: []gatewayapiv1.HTTPRouteRule{ + expectedTopLevelHttpRoute := gwapiv1.HTTPRoute{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{gwapiv1.Hostname(topLevelHost), gwapiv1.Hostname(fmt.Sprintf("%s-%s.additional.example.com", serviceKey.Name, serviceKey.Namespace))}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(constants.FallbackPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -396,32 +396,32 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(predictorServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(predictorServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("30s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("30s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, }, }, @@ -429,7 +429,7 @@ var _ = Describe("v1beta1 inference service controller", func() { } Expect(actualTopLevelHttpRoute.Spec).To(BeComparableTo(expectedTopLevelHttpRoute.Spec)) - actualPredictorHttpRoute := &gatewayapiv1.HTTPRoute{} + actualPredictorHttpRoute := &gwapiv1.HTTPRoute{} Eventually(func() error { return k8sClient.Get(context.TODO(), types.NamespacedName{ Name: predictorServiceKey.Name, @@ -437,24 +437,24 @@ var _ = Describe("v1beta1 inference service controller", func() { }, actualPredictorHttpRoute) }, timeout).Should(Succeed()) predictorHost := fmt.Sprintf("%s-%s.%s", predictorServiceKey.Name, serviceKey.Namespace, "example.com") - expectedPredictorHttpRoute := gatewayapiv1.HTTPRoute{ - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{gatewayapiv1.Hostname(predictorHost)}, - Rules: []gatewayapiv1.HTTPRouteRule{ + expectedPredictorHttpRoute := gwapiv1.HTTPRoute{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{gwapiv1.Hostname(predictorHost)}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(constants.FallbackPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -467,32 +467,32 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(predictorServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(predictorServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("30s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("30s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, }, }, @@ -501,20 +501,20 @@ var _ = Describe("v1beta1 inference service controller", func() { Expect(actualPredictorHttpRoute.Spec).To(BeComparableTo(expectedPredictorHttpRoute.Spec)) // Mark the Ingress as accepted to make isvc ready - httpRouteStatus := gatewayapiv1.HTTPRouteStatus{ - RouteStatus: gatewayapiv1.RouteStatus{ - Parents: []gatewayapiv1.RouteParentStatus{ + httpRouteStatus := gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ { - ParentRef: gatewayapiv1.ParentReference{ - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + ParentRef: gwapiv1.ParentReference{ + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, ControllerName: "istio.io/gateway-controller", Conditions: []metav1.Condition{ { - Type: string(gatewayapiv1.ListenerConditionAccepted), + Type: string(gwapiv1.ListenerConditionAccepted), Status: metav1.ConditionTrue, Reason: "Accepted", Message: "Route was valid", @@ -913,7 +913,7 @@ var _ = Describe("v1beta1 inference service controller", func() { Expect(actualService.Spec).To(BeComparableTo(expectedService.Spec)) // check http route - actualToplevelHttpRoute := &gatewayapiv1.HTTPRoute{} + actualToplevelHttpRoute := &gwapiv1.HTTPRoute{} Eventually(func() error { return k8sClient.Get(context.TODO(), types.NamespacedName{ Name: serviceKey.Name, @@ -922,24 +922,24 @@ var _ = Describe("v1beta1 inference service controller", func() { }, timeout). Should(Succeed()) topLevelHost := fmt.Sprintf("%s-%s.%s", serviceKey.Name, serviceKey.Namespace, "example.com") - expectedToplevelHttpRoute := gatewayapiv1.HTTPRoute{ - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{gatewayapiv1.Hostname(topLevelHost), gatewayapiv1.Hostname(fmt.Sprintf("%s-%s.additional.example.com", serviceKey.Name, serviceKey.Namespace))}, - Rules: []gatewayapiv1.HTTPRouteRule{ + expectedToplevelHttpRoute := gwapiv1.HTTPRoute{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{gwapiv1.Hostname(topLevelHost), gwapiv1.Hostname(fmt.Sprintf("%s-%s.additional.example.com", serviceKey.Name, serviceKey.Namespace))}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(constants.FallbackPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -952,32 +952,32 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(predictorServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(predictorServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("60s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("60s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, }, }, @@ -985,7 +985,7 @@ var _ = Describe("v1beta1 inference service controller", func() { } Expect(actualToplevelHttpRoute.Spec).To(BeComparableTo(expectedToplevelHttpRoute.Spec)) - actualPredictorHttpRoute := &gatewayapiv1.HTTPRoute{} + actualPredictorHttpRoute := &gwapiv1.HTTPRoute{} Eventually(func() error { return k8sClient.Get(context.TODO(), types.NamespacedName{ Name: predictorServiceKey.Name, @@ -994,24 +994,24 @@ var _ = Describe("v1beta1 inference service controller", func() { }, timeout). Should(Succeed()) predictorHost := fmt.Sprintf("%s-%s.%s", predictorServiceKey.Name, serviceKey.Namespace, "example.com") - expectedPredictorHttpRoute := gatewayapiv1.HTTPRoute{ - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{gatewayapiv1.Hostname(predictorHost)}, - Rules: []gatewayapiv1.HTTPRouteRule{ + expectedPredictorHttpRoute := gwapiv1.HTTPRoute{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{gwapiv1.Hostname(predictorHost)}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(constants.FallbackPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -1024,32 +1024,32 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(predictorServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(predictorServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("60s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("60s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, }, }, @@ -1058,20 +1058,20 @@ var _ = Describe("v1beta1 inference service controller", func() { Expect(actualPredictorHttpRoute.Spec).To(BeComparableTo(expectedPredictorHttpRoute.Spec)) // Mark the Ingress as accepted to make isvc ready - httpRouteStatus := gatewayapiv1.HTTPRouteStatus{ - RouteStatus: gatewayapiv1.RouteStatus{ - Parents: []gatewayapiv1.RouteParentStatus{ + httpRouteStatus := gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ { - ParentRef: gatewayapiv1.ParentReference{ - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + ParentRef: gwapiv1.ParentReference{ + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, ControllerName: "istio.io/gateway-controller", Conditions: []metav1.Condition{ { - Type: string(gatewayapiv1.ListenerConditionAccepted), + Type: string(gwapiv1.ListenerConditionAccepted), Status: metav1.ConditionTrue, Reason: "Accepted", Message: "Route was valid", @@ -1466,7 +1466,7 @@ var _ = Describe("v1beta1 inference service controller", func() { Expect(k8sClient.Status().Update(context.TODO(), updatedDeployment)).NotTo(HaveOccurred()) // check http Route - actualToplevelHttpRoute := &gatewayapiv1.HTTPRoute{} + actualToplevelHttpRoute := &gwapiv1.HTTPRoute{} Eventually(func() error { return k8sClient.Get(context.TODO(), types.NamespacedName{ Name: serviceKey.Name, @@ -1475,24 +1475,24 @@ var _ = Describe("v1beta1 inference service controller", func() { }, timeout). Should(Succeed()) topLevelHost := fmt.Sprintf("%s-%s.%s", serviceKey.Name, serviceKey.Namespace, "example.com") - expectedToplevelHttpRoute := gatewayapiv1.HTTPRoute{ - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{gatewayapiv1.Hostname(topLevelHost), gatewayapiv1.Hostname(fmt.Sprintf("%s-%s.additional.example.com", serviceKey.Name, serviceKey.Namespace))}, - Rules: []gatewayapiv1.HTTPRouteRule{ + expectedToplevelHttpRoute := gwapiv1.HTTPRoute{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{gwapiv1.Hostname(topLevelHost), gwapiv1.Hostname(fmt.Sprintf("%s-%s.additional.example.com", serviceKey.Name, serviceKey.Namespace))}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(constants.FallbackPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -1505,32 +1505,32 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(predictorServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(predictorServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("60s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("60s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, }, }, @@ -1538,7 +1538,7 @@ var _ = Describe("v1beta1 inference service controller", func() { } Expect(actualToplevelHttpRoute.Spec).To(BeComparableTo(expectedToplevelHttpRoute.Spec)) - actualPredictorHttpRoute := &gatewayapiv1.HTTPRoute{} + actualPredictorHttpRoute := &gwapiv1.HTTPRoute{} Eventually(func() error { return k8sClient.Get(context.TODO(), types.NamespacedName{ Name: predictorServiceKey.Name, @@ -1547,24 +1547,24 @@ var _ = Describe("v1beta1 inference service controller", func() { }, timeout). Should(Succeed()) predictorHost := fmt.Sprintf("%s-%s.%s", predictorServiceKey.Name, serviceKey.Namespace, "example.com") - expectedPredictorHttpRoute := gatewayapiv1.HTTPRoute{ - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{gatewayapiv1.Hostname(predictorHost)}, - Rules: []gatewayapiv1.HTTPRouteRule{ + expectedPredictorHttpRoute := gwapiv1.HTTPRoute{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{gwapiv1.Hostname(predictorHost)}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(constants.FallbackPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -1577,32 +1577,32 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(predictorServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(predictorServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("60s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("60s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, }, }, @@ -1611,20 +1611,20 @@ var _ = Describe("v1beta1 inference service controller", func() { Expect(actualPredictorHttpRoute.Spec).To(BeComparableTo(expectedPredictorHttpRoute.Spec)) // Mark the Ingress as accepted to make isvc ready - httpRouteStatus := gatewayapiv1.HTTPRouteStatus{ - RouteStatus: gatewayapiv1.RouteStatus{ - Parents: []gatewayapiv1.RouteParentStatus{ + httpRouteStatus := gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ { - ParentRef: gatewayapiv1.ParentReference{ - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + ParentRef: gwapiv1.ParentReference{ + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, ControllerName: "istio.io/gateway-controller", Conditions: []metav1.Condition{ { - Type: string(gatewayapiv1.ListenerConditionAccepted), + Type: string(gwapiv1.ListenerConditionAccepted), Status: metav1.ConditionTrue, Reason: "Accepted", Message: "Route was valid", @@ -2073,26 +2073,26 @@ var _ = Describe("v1beta1 inference service controller", func() { // Waits for the http route to be ready // Note: top level route uses serviceKey, predictor route uses predictorKey expectHttpRouteToBeReady := func(ctx context.Context, objKey types.NamespacedName) { - actualHttpRoute := &gatewayapiv1.HTTPRoute{} + actualHttpRoute := &gwapiv1.HTTPRoute{} Eventually(func() error { return k8sClient.Get(ctx, objKey, actualHttpRoute) }, timeout).Should(Succeed()) // Mark the route as accepted to make isvc ready - httpRouteStatus := gatewayapiv1.HTTPRouteStatus{ - RouteStatus: gatewayapiv1.RouteStatus{ - Parents: []gatewayapiv1.RouteParentStatus{ + httpRouteStatus := gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ { - ParentRef: gatewayapiv1.ParentReference{ - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + ParentRef: gwapiv1.ParentReference{ + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, ControllerName: "istio.io/gateway-controller", Conditions: []metav1.Condition{ { - Type: string(gatewayapiv1.ListenerConditionAccepted), + Type: string(gwapiv1.ListenerConditionAccepted), Status: metav1.ConditionTrue, Reason: "Accepted", Message: "Route was valid", @@ -2409,13 +2409,29 @@ var _ = Describe("v1beta1 inference service controller", func() { // check that the http routes were not created // top level http route - expectResourceDoesNotExist(context.Background(), &gatewayapiv1.HTTPRoute{}, serviceKey) + expectResourceDoesNotExist(context.Background(), &gwapiv1.HTTPRoute{}, serviceKey) // predictor http route - expectResourceDoesNotExist(context.Background(), &gatewayapiv1.HTTPRoute{}, predictorKey) + expectResourceDoesNotExist(context.Background(), &gwapiv1.HTTPRoute{}, predictorKey) // check that the HPA was not created expectResourceDoesNotExist(ctx, &autoscalingv2.HorizontalPodAutoscaler{}, predictorKey) + // check that the HPA was not created + existingHPA := &autoscalingv2.HorizontalPodAutoscaler{} + Consistently(func() bool { + err := k8sClient.Get(ctx, predictorKey, existingHPA) + return apierr.IsNotFound(err) + }, time.Second*10).Should(BeTrue(), "The HPA should not be created") + + actualPredictorHttpRoute := &gwapiv1.HTTPRoute{} + Consistently(func() bool { + err := k8sClient.Get(context.Background(), types.NamespacedName{ + Name: predictorKey.Name, + Namespace: serviceKey.Namespace, + }, actualPredictorHttpRoute) + return apierr.IsNotFound(err) + }, time.Second*10).Should(BeTrue(), "The predictor http route should not be created") + // Check that the ISVC was updated expectIsvcToExist(ctx, serviceKey) @@ -2581,9 +2597,9 @@ var _ = Describe("v1beta1 inference service controller", func() { // check that the http routes were deleted // top level http route - expectResourceToBeDeleted(context.Background(), &gatewayapiv1.HTTPRoute{}, serviceKey) + expectResourceToBeDeleted(context.Background(), &gwapiv1.HTTPRoute{}, serviceKey) // predictor http route - expectResourceToBeDeleted(context.Background(), &gatewayapiv1.HTTPRoute{}, predictorKey) + expectResourceToBeDeleted(context.Background(), &gwapiv1.HTTPRoute{}, predictorKey) // check that the HPA was deleted expectResourceToBeDeleted(ctx, &autoscalingv2.HorizontalPodAutoscaler{}, predictorKey) @@ -2753,9 +2769,9 @@ var _ = Describe("v1beta1 inference service controller", func() { // check that the http routes were not created // top level http route - expectResourceDoesNotExist(context.Background(), &gatewayapiv1.HTTPRoute{}, serviceKey) + expectResourceDoesNotExist(context.Background(), &gwapiv1.HTTPRoute{}, serviceKey) // predictor http route - expectResourceDoesNotExist(context.Background(), &gatewayapiv1.HTTPRoute{}, predictorKey) + expectResourceDoesNotExist(context.Background(), &gwapiv1.HTTPRoute{}, predictorKey) // check that the predictor HPA was not created expectResourceDoesNotExist(ctx, &autoscalingv2.HorizontalPodAutoscaler{}, predictorKey) @@ -3106,11 +3122,11 @@ var _ = Describe("v1beta1 inference service controller", func() { // check that the http routes were not created // top level http route - expectResourceDoesNotExist(context.Background(), &gatewayapiv1.HTTPRoute{}, serviceKey) + expectResourceDoesNotExist(context.Background(), &gwapiv1.HTTPRoute{}, serviceKey) // predictor http route - expectResourceDoesNotExist(context.Background(), &gatewayapiv1.HTTPRoute{}, predictorKey) + expectResourceDoesNotExist(context.Background(), &gwapiv1.HTTPRoute{}, predictorKey) // transformer http route - expectResourceDoesNotExist(context.Background(), &gatewayapiv1.HTTPRoute{}, transformerKey) + expectResourceDoesNotExist(context.Background(), &gwapiv1.HTTPRoute{}, transformerKey) // check that the predictor HPA was not created expectResourceDoesNotExist(ctx, &autoscalingv2.HorizontalPodAutoscaler{}, predictorKey) @@ -3212,11 +3228,11 @@ var _ = Describe("v1beta1 inference service controller", func() { // check that the http routes were deleted // top level http route - expectResourceToBeDeleted(context.Background(), &gatewayapiv1.HTTPRoute{}, serviceKey) + expectResourceToBeDeleted(context.Background(), &gwapiv1.HTTPRoute{}, serviceKey) // predictor http route - expectResourceToBeDeleted(context.Background(), &gatewayapiv1.HTTPRoute{}, predictorKey) + expectResourceToBeDeleted(context.Background(), &gwapiv1.HTTPRoute{}, predictorKey) // transformer http route - expectResourceToBeDeleted(context.Background(), &gatewayapiv1.HTTPRoute{}, transformerKey) + expectResourceToBeDeleted(context.Background(), &gwapiv1.HTTPRoute{}, transformerKey) // check that the predictor HPA was deleted expectResourceToBeDeleted(ctx, &autoscalingv2.HorizontalPodAutoscaler{}, predictorKey) @@ -3280,11 +3296,11 @@ var _ = Describe("v1beta1 inference service controller", func() { // check that the http routes were not created // top level http route - expectResourceDoesNotExist(context.Background(), &gatewayapiv1.HTTPRoute{}, serviceKey) + expectResourceDoesNotExist(context.Background(), &gwapiv1.HTTPRoute{}, serviceKey) // predictor http route - expectResourceDoesNotExist(context.Background(), &gatewayapiv1.HTTPRoute{}, predictorKey) + expectResourceDoesNotExist(context.Background(), &gwapiv1.HTTPRoute{}, predictorKey) // transformer http route - expectResourceDoesNotExist(context.Background(), &gatewayapiv1.HTTPRoute{}, transformerKey) + expectResourceDoesNotExist(context.Background(), &gwapiv1.HTTPRoute{}, transformerKey) // check that the predictor HPA was not created expectResourceDoesNotExist(ctx, &autoscalingv2.HorizontalPodAutoscaler{}, predictorKey) @@ -3530,11 +3546,11 @@ var _ = Describe("v1beta1 inference service controller", func() { // check that the http routes were not created // top level http route - expectResourceDoesNotExist(context.Background(), &gatewayapiv1.HTTPRoute{}, serviceKey) + expectResourceDoesNotExist(context.Background(), &gwapiv1.HTTPRoute{}, serviceKey) // predictor http route - expectResourceDoesNotExist(context.Background(), &gatewayapiv1.HTTPRoute{}, predictorKey) + expectResourceDoesNotExist(context.Background(), &gwapiv1.HTTPRoute{}, predictorKey) // explainer http route - expectResourceDoesNotExist(context.Background(), &gatewayapiv1.HTTPRoute{}, explainerKey) + expectResourceDoesNotExist(context.Background(), &gwapiv1.HTTPRoute{}, explainerKey) // check that the predictor HPA was not created expectResourceDoesNotExist(ctx, &autoscalingv2.HorizontalPodAutoscaler{}, predictorKey) @@ -3636,11 +3652,11 @@ var _ = Describe("v1beta1 inference service controller", func() { // check that the http routes were deleted // top level http route - expectResourceToBeDeleted(context.Background(), &gatewayapiv1.HTTPRoute{}, serviceKey) + expectResourceToBeDeleted(context.Background(), &gwapiv1.HTTPRoute{}, serviceKey) // predictor http route - expectResourceToBeDeleted(context.Background(), &gatewayapiv1.HTTPRoute{}, predictorKey) + expectResourceToBeDeleted(context.Background(), &gwapiv1.HTTPRoute{}, predictorKey) // explainer http route - expectResourceToBeDeleted(context.Background(), &gatewayapiv1.HTTPRoute{}, explainerKey) + expectResourceToBeDeleted(context.Background(), &gwapiv1.HTTPRoute{}, explainerKey) // check that the predictor HPA was deleted expectResourceToBeDeleted(ctx, &autoscalingv2.HorizontalPodAutoscaler{}, predictorKey) @@ -3704,11 +3720,11 @@ var _ = Describe("v1beta1 inference service controller", func() { // check that the http routes were not created // top level http route - expectResourceDoesNotExist(context.Background(), &gatewayapiv1.HTTPRoute{}, serviceKey) + expectResourceDoesNotExist(context.Background(), &gwapiv1.HTTPRoute{}, serviceKey) // predictor http route - expectResourceDoesNotExist(context.Background(), &gatewayapiv1.HTTPRoute{}, predictorKey) + expectResourceDoesNotExist(context.Background(), &gwapiv1.HTTPRoute{}, predictorKey) // explainer http route - expectResourceDoesNotExist(context.Background(), &gatewayapiv1.HTTPRoute{}, explainerKey) + expectResourceDoesNotExist(context.Background(), &gwapiv1.HTTPRoute{}, explainerKey) // check that the predictor HPA was not created expectResourceDoesNotExist(ctx, &autoscalingv2.HorizontalPodAutoscaler{}, predictorKey) @@ -4745,7 +4761,7 @@ var _ = Describe("v1beta1 inference service controller", func() { Expect(k8sClient.Status().Update(context.TODO(), updatedDeployment)).NotTo(HaveOccurred()) // check ingress not created - actualToplevelHttpRoute := &gatewayapiv1.HTTPRoute{} + actualToplevelHttpRoute := &gwapiv1.HTTPRoute{} Consistently(func() error { return k8sClient.Get(context.TODO(), types.NamespacedName{ Name: serviceKey.Name, @@ -4753,7 +4769,7 @@ var _ = Describe("v1beta1 inference service controller", func() { }, actualToplevelHttpRoute) }, timeout). Should(Not(Succeed())) - actualPredictorHttpRoute := &gatewayapiv1.HTTPRoute{} + actualPredictorHttpRoute := &gwapiv1.HTTPRoute{} Consistently(func() error { return k8sClient.Get(context.TODO(), types.NamespacedName{ Name: predictorServiceKey.Name, @@ -5164,7 +5180,7 @@ var _ = Describe("v1beta1 inference service controller", func() { Expect(k8sClient.Status().Update(context.TODO(), updatedDeployment)).NotTo(HaveOccurred()) // check http route - actualToplevelHttpRoute := &gatewayapiv1.HTTPRoute{} + actualToplevelHttpRoute := &gwapiv1.HTTPRoute{} Eventually(func() error { return k8sClient.Get(context.TODO(), types.NamespacedName{ Name: serviceKey.Name, @@ -5173,24 +5189,24 @@ var _ = Describe("v1beta1 inference service controller", func() { }, timeout). Should(Succeed()) topLevelHost := fmt.Sprintf("%s.%s.%s", serviceKey.Name, serviceKey.Namespace, "example.com") - expectedToplevelHttpRoute := gatewayapiv1.HTTPRoute{ - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{gatewayapiv1.Hostname(topLevelHost), gatewayapiv1.Hostname(fmt.Sprintf("%s.%s.additional.example.com", serviceKey.Name, serviceKey.Namespace))}, - Rules: []gatewayapiv1.HTTPRouteRule{ + expectedToplevelHttpRoute := gwapiv1.HTTPRoute{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{gwapiv1.Hostname(topLevelHost), gwapiv1.Hostname(fmt.Sprintf("%s.%s.additional.example.com", serviceKey.Name, serviceKey.Namespace))}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(constants.FallbackPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -5203,32 +5219,32 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(predictorServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(predictorServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("60s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("60s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, }, }, @@ -5236,7 +5252,7 @@ var _ = Describe("v1beta1 inference service controller", func() { } Expect(actualToplevelHttpRoute.Spec).To(BeComparableTo(expectedToplevelHttpRoute.Spec)) - actualPredictorHttpRoute := &gatewayapiv1.HTTPRoute{} + actualPredictorHttpRoute := &gwapiv1.HTTPRoute{} Eventually(func() error { return k8sClient.Get(context.TODO(), types.NamespacedName{ Name: predictorServiceKey.Name, @@ -5245,24 +5261,24 @@ var _ = Describe("v1beta1 inference service controller", func() { }, timeout). Should(Succeed()) predictorHost := fmt.Sprintf("%s.%s.%s", predictorServiceKey.Name, serviceKey.Namespace, "example.com") - expectedPredictorHttpRoute := gatewayapiv1.HTTPRoute{ - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{gatewayapiv1.Hostname(predictorHost)}, - Rules: []gatewayapiv1.HTTPRouteRule{ + expectedPredictorHttpRoute := gwapiv1.HTTPRoute{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{gwapiv1.Hostname(predictorHost)}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(constants.FallbackPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -5275,32 +5291,32 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(predictorServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(predictorServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("60s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("60s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, }, }, @@ -5309,20 +5325,20 @@ var _ = Describe("v1beta1 inference service controller", func() { Expect(actualPredictorHttpRoute.Spec).To(BeComparableTo(expectedPredictorHttpRoute.Spec)) // Mark the Ingress as accepted to make isvc ready - httpRouteStatus := gatewayapiv1.HTTPRouteStatus{ - RouteStatus: gatewayapiv1.RouteStatus{ - Parents: []gatewayapiv1.RouteParentStatus{ + httpRouteStatus := gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ { - ParentRef: gatewayapiv1.ParentReference{ - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + ParentRef: gwapiv1.ParentReference{ + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, ControllerName: "istio.io/gateway-controller", Conditions: []metav1.Condition{ { - Type: string(gatewayapiv1.ListenerConditionAccepted), + Type: string(gwapiv1.ListenerConditionAccepted), Status: metav1.ConditionTrue, Reason: "Accepted", Message: "Route was valid", @@ -5920,7 +5936,7 @@ var _ = Describe("v1beta1 inference service controller", func() { Expect(k8sClient.Status().Update(context.TODO(), updatedTransformerDeployment)).NotTo(HaveOccurred()) // check http route - actualToplevelHttpRoute := &gatewayapiv1.HTTPRoute{} + actualToplevelHttpRoute := &gwapiv1.HTTPRoute{} Eventually(func() error { return k8sClient.Get(context.TODO(), types.NamespacedName{ Name: serviceKey.Name, @@ -5929,24 +5945,24 @@ var _ = Describe("v1beta1 inference service controller", func() { }, timeout). Should(Succeed()) topLevelHost := fmt.Sprintf("%s-%s.%s", serviceKey.Name, serviceKey.Namespace, "example.com") - expectedToplevelHttpRoute := gatewayapiv1.HTTPRoute{ - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{gatewayapiv1.Hostname(topLevelHost), gatewayapiv1.Hostname(fmt.Sprintf("%s-%s.additional.example.com", serviceKey.Name, serviceKey.Namespace))}, - Rules: []gatewayapiv1.HTTPRouteRule{ + expectedToplevelHttpRoute := gwapiv1.HTTPRoute{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{gwapiv1.Hostname(topLevelHost), gwapiv1.Hostname(fmt.Sprintf("%s-%s.additional.example.com", serviceKey.Name, serviceKey.Namespace))}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(constants.FallbackPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -5959,32 +5975,32 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(transformerServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(transformerServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("30s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("30s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, }, }, @@ -5992,7 +6008,7 @@ var _ = Describe("v1beta1 inference service controller", func() { } Expect(actualToplevelHttpRoute.Spec).To(BeComparableTo(expectedToplevelHttpRoute.Spec)) - actualPredictorHttpRoute := &gatewayapiv1.HTTPRoute{} + actualPredictorHttpRoute := &gwapiv1.HTTPRoute{} Eventually(func() error { return k8sClient.Get(context.TODO(), types.NamespacedName{ Name: predictorServiceKey.Name, @@ -6001,24 +6017,24 @@ var _ = Describe("v1beta1 inference service controller", func() { }, timeout). Should(Succeed()) predictorHost := fmt.Sprintf("%s-%s.%s", predictorServiceKey.Name, serviceKey.Namespace, "example.com") - expectedPredictorHttpRoute := gatewayapiv1.HTTPRoute{ - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{gatewayapiv1.Hostname(predictorHost)}, - Rules: []gatewayapiv1.HTTPRouteRule{ + expectedPredictorHttpRoute := gwapiv1.HTTPRoute{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{gwapiv1.Hostname(predictorHost)}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(constants.FallbackPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -6031,32 +6047,32 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(predictorServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(predictorServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("60s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("60s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, }, }, @@ -6064,7 +6080,7 @@ var _ = Describe("v1beta1 inference service controller", func() { } Expect(actualPredictorHttpRoute.Spec).To(BeComparableTo(expectedPredictorHttpRoute.Spec)) - actualTransformerHttpRoute := &gatewayapiv1.HTTPRoute{} + actualTransformerHttpRoute := &gwapiv1.HTTPRoute{} Eventually(func() error { return k8sClient.Get(context.TODO(), types.NamespacedName{ Name: transformerServiceKey.Name, @@ -6073,24 +6089,24 @@ var _ = Describe("v1beta1 inference service controller", func() { }, timeout). Should(Succeed()) transformerHost := fmt.Sprintf("%s-%s.%s", transformerServiceKey.Name, serviceKey.Namespace, "example.com") - expectedTransformerHttpRoute := gatewayapiv1.HTTPRoute{ - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{gatewayapiv1.Hostname(transformerHost)}, - Rules: []gatewayapiv1.HTTPRouteRule{ + expectedTransformerHttpRoute := gwapiv1.HTTPRoute{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{gwapiv1.Hostname(transformerHost)}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(constants.FallbackPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -6103,32 +6119,32 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(transformerServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(transformerServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("30s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("30s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, }, }, @@ -6137,20 +6153,20 @@ var _ = Describe("v1beta1 inference service controller", func() { Expect(actualTransformerHttpRoute.Spec).To(BeComparableTo(expectedTransformerHttpRoute.Spec)) // Mark the Ingress as accepted to make isvc ready - httpRouteStatus := gatewayapiv1.HTTPRouteStatus{ - RouteStatus: gatewayapiv1.RouteStatus{ - Parents: []gatewayapiv1.RouteParentStatus{ + httpRouteStatus := gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ { - ParentRef: gatewayapiv1.ParentReference{ - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + ParentRef: gwapiv1.ParentReference{ + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, ControllerName: "istio.io/gateway-controller", Conditions: []metav1.Condition{ { - Type: string(gatewayapiv1.ListenerConditionAccepted), + Type: string(gwapiv1.ListenerConditionAccepted), Status: metav1.ConditionTrue, Reason: "Accepted", Message: "Route was valid", @@ -6828,7 +6844,7 @@ var _ = Describe("v1beta1 inference service controller", func() { Expect(k8sClient.Status().Update(context.TODO(), updatedExplainerDeployment)).NotTo(HaveOccurred()) // check http route - actualToplevelHttpRoute := &gatewayapiv1.HTTPRoute{} + actualToplevelHttpRoute := &gwapiv1.HTTPRoute{} Eventually(func() error { return k8sClient.Get(context.TODO(), types.NamespacedName{ Name: serviceKey.Name, @@ -6836,24 +6852,24 @@ var _ = Describe("v1beta1 inference service controller", func() { }, actualToplevelHttpRoute) }, timeout).Should(Succeed()) topLevelHost := fmt.Sprintf("%s-%s.%s", serviceKey.Name, serviceKey.Namespace, "example.com") - expectedToplevelHttpRoute := gatewayapiv1.HTTPRoute{ - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{gatewayapiv1.Hostname(topLevelHost), gatewayapiv1.Hostname(fmt.Sprintf("%s-%s.additional.example.com", serviceKey.Name, serviceKey.Namespace))}, - Rules: []gatewayapiv1.HTTPRouteRule{ + expectedToplevelHttpRoute := gwapiv1.HTTPRoute{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{gwapiv1.Hostname(topLevelHost), gwapiv1.Hostname(fmt.Sprintf("%s-%s.additional.example.com", serviceKey.Name, serviceKey.Namespace))}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(constants.ExplainPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -6866,38 +6882,38 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(explainerServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(explainerServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("30s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("30s")), }, }, { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(constants.FallbackPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -6910,32 +6926,32 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(predictorServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(predictorServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("60s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("60s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, }, }, @@ -6943,7 +6959,7 @@ var _ = Describe("v1beta1 inference service controller", func() { } Expect(actualToplevelHttpRoute.Spec).To(BeComparableTo(expectedToplevelHttpRoute.Spec)) - actualPredictorHttpRoute := &gatewayapiv1.HTTPRoute{} + actualPredictorHttpRoute := &gwapiv1.HTTPRoute{} Eventually(func() error { return k8sClient.Get(context.TODO(), types.NamespacedName{ Name: predictorServiceKey.Name, @@ -6952,24 +6968,24 @@ var _ = Describe("v1beta1 inference service controller", func() { }, timeout). Should(Succeed()) predictorHost := fmt.Sprintf("%s-%s.%s", predictorServiceKey.Name, serviceKey.Namespace, "example.com") - expectedPredictorHttpRoute := gatewayapiv1.HTTPRoute{ - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{gatewayapiv1.Hostname(predictorHost)}, - Rules: []gatewayapiv1.HTTPRouteRule{ + expectedPredictorHttpRoute := gwapiv1.HTTPRoute{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{gwapiv1.Hostname(predictorHost)}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(constants.FallbackPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -6982,32 +6998,32 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(predictorServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(predictorServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("60s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("60s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, }, }, @@ -7015,7 +7031,7 @@ var _ = Describe("v1beta1 inference service controller", func() { } Expect(actualPredictorHttpRoute.Spec).To(BeComparableTo(expectedPredictorHttpRoute.Spec)) - actualExplainerHttpRoute := &gatewayapiv1.HTTPRoute{} + actualExplainerHttpRoute := &gwapiv1.HTTPRoute{} Eventually(func() error { return k8sClient.Get(context.TODO(), types.NamespacedName{ Name: explainerServiceKey.Name, @@ -7024,24 +7040,24 @@ var _ = Describe("v1beta1 inference service controller", func() { }, timeout). Should(Succeed()) explainerHost := fmt.Sprintf("%s-%s.%s", explainerServiceKey.Name, serviceKey.Namespace, "example.com") - expectedExplainerHttpRoute := gatewayapiv1.HTTPRoute{ - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{gatewayapiv1.Hostname(explainerHost)}, - Rules: []gatewayapiv1.HTTPRouteRule{ + expectedExplainerHttpRoute := gwapiv1.HTTPRoute{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{gwapiv1.Hostname(explainerHost)}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(constants.FallbackPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -7054,32 +7070,32 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(explainerServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(explainerServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("30s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("30s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, }, }, @@ -7088,20 +7104,20 @@ var _ = Describe("v1beta1 inference service controller", func() { Expect(actualExplainerHttpRoute.Spec).To(BeComparableTo(expectedExplainerHttpRoute.Spec)) // Mark the Ingress as accepted to make isvc ready - httpRouteStatus := gatewayapiv1.HTTPRouteStatus{ - RouteStatus: gatewayapiv1.RouteStatus{ - Parents: []gatewayapiv1.RouteParentStatus{ + httpRouteStatus := gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ { - ParentRef: gatewayapiv1.ParentReference{ - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + ParentRef: gwapiv1.ParentReference{ + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, ControllerName: "istio.io/gateway-controller", Conditions: []metav1.Condition{ { - Type: string(gatewayapiv1.ListenerConditionAccepted), + Type: string(gwapiv1.ListenerConditionAccepted), Status: metav1.ConditionTrue, Reason: "Accepted", Message: "Route was valid", @@ -7603,7 +7619,7 @@ var _ = Describe("v1beta1 inference service controller", func() { Expect(k8sClient.Status().Update(context.TODO(), updatedDeployment)).NotTo(HaveOccurred()) // check http route - actualToplevelHttpRoute := &gatewayapiv1.HTTPRoute{} + actualToplevelHttpRoute := &gwapiv1.HTTPRoute{} Eventually(func() error { return k8sClient.Get(context.TODO(), types.NamespacedName{ Name: serviceKey.Name, @@ -7613,24 +7629,24 @@ var _ = Describe("v1beta1 inference service controller", func() { Should(Succeed()) topLevelHost := fmt.Sprintf("%s-%s.%s", serviceKey.Name, serviceKey.Namespace, "example.com") prefixUrlPath := fmt.Sprintf("/serving/%s/%s", serviceKey.Namespace, serviceKey.Name) - expectedToplevelHttpRoute := gatewayapiv1.HTTPRoute{ - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{gatewayapiv1.Hostname(topLevelHost), gatewayapiv1.Hostname(fmt.Sprintf("%s-%s.additional.example.com", serviceKey.Name, serviceKey.Namespace)), "example.com"}, - Rules: []gatewayapiv1.HTTPRouteRule{ + expectedToplevelHttpRoute := gwapiv1.HTTPRoute{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{gwapiv1.Hostname(topLevelHost), gwapiv1.Hostname(fmt.Sprintf("%s-%s.additional.example.com", serviceKey.Name, serviceKey.Namespace)), "example.com"}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(constants.FallbackPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -7643,38 +7659,38 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(predictorServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(predictorServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("30s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("30s")), }, }, { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(prefixUrlPath + "/"), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -7687,32 +7703,32 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(predictorServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(predictorServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("30s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("30s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, }, }, @@ -7720,7 +7736,7 @@ var _ = Describe("v1beta1 inference service controller", func() { } Expect(actualToplevelHttpRoute.Spec).To(BeComparableTo(expectedToplevelHttpRoute.Spec)) - actualPredictorHttpRoute := &gatewayapiv1.HTTPRoute{} + actualPredictorHttpRoute := &gwapiv1.HTTPRoute{} Eventually(func() error { return k8sClient.Get(context.TODO(), types.NamespacedName{ Name: predictorServiceKey.Name, @@ -7729,24 +7745,24 @@ var _ = Describe("v1beta1 inference service controller", func() { }, timeout). Should(Succeed()) predictorHost := fmt.Sprintf("%s-%s.%s", predictorServiceKey.Name, serviceKey.Namespace, "example.com") - expectedPredictorHttpRoute := gatewayapiv1.HTTPRoute{ - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{gatewayapiv1.Hostname(predictorHost)}, - Rules: []gatewayapiv1.HTTPRouteRule{ + expectedPredictorHttpRoute := gwapiv1.HTTPRoute{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{gwapiv1.Hostname(predictorHost)}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(constants.FallbackPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -7759,32 +7775,32 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(predictorServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(predictorServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("30s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("30s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, }, }, @@ -7793,20 +7809,20 @@ var _ = Describe("v1beta1 inference service controller", func() { Expect(actualPredictorHttpRoute.Spec).To(BeComparableTo(expectedPredictorHttpRoute.Spec)) // Mark the Ingress as accepted to make isvc ready - httpRouteStatus := gatewayapiv1.HTTPRouteStatus{ - RouteStatus: gatewayapiv1.RouteStatus{ - Parents: []gatewayapiv1.RouteParentStatus{ + httpRouteStatus := gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ { - ParentRef: gatewayapiv1.ParentReference{ - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + ParentRef: gwapiv1.ParentReference{ + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, ControllerName: "istio.io/gateway-controller", Conditions: []metav1.Condition{ { - Type: string(gatewayapiv1.ListenerConditionAccepted), + Type: string(gwapiv1.ListenerConditionAccepted), Status: metav1.ConditionTrue, Reason: "Accepted", Message: "Route was valid", @@ -8409,7 +8425,7 @@ var _ = Describe("v1beta1 inference service controller", func() { Expect(k8sClient.Status().Update(context.TODO(), updatedTransformerDeployment)).NotTo(HaveOccurred()) // check http route - actualToplevelHttpRoute := &gatewayapiv1.HTTPRoute{} + actualToplevelHttpRoute := &gwapiv1.HTTPRoute{} Eventually(func() error { return k8sClient.Get(context.TODO(), types.NamespacedName{ Name: serviceKey.Name, @@ -8419,24 +8435,24 @@ var _ = Describe("v1beta1 inference service controller", func() { Should(Succeed()) topLevelHost := fmt.Sprintf("%s-%s.%s", serviceKey.Name, serviceKey.Namespace, "example.com") prefixUrlPath := fmt.Sprintf("/serving/%s/%s", serviceKey.Namespace, serviceKey.Name) - expectedToplevelHttpRoute := gatewayapiv1.HTTPRoute{ - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{gatewayapiv1.Hostname(topLevelHost), gatewayapiv1.Hostname(fmt.Sprintf("%s-%s.additional.example.com", serviceKey.Name, serviceKey.Namespace)), "example.com"}, - Rules: []gatewayapiv1.HTTPRouteRule{ + expectedToplevelHttpRoute := gwapiv1.HTTPRoute{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{gwapiv1.Hostname(topLevelHost), gwapiv1.Hostname(fmt.Sprintf("%s-%s.additional.example.com", serviceKey.Name, serviceKey.Namespace)), "example.com"}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(constants.FallbackPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -8449,38 +8465,38 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(transformerServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(transformerServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("30s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("30s")), }, }, { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(prefixUrlPath + "/"), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -8493,32 +8509,32 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(transformerServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(transformerServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("30s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("30s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, }, }, @@ -8526,7 +8542,7 @@ var _ = Describe("v1beta1 inference service controller", func() { } Expect(actualToplevelHttpRoute.Spec).To(BeComparableTo(expectedToplevelHttpRoute.Spec)) - actualPredictorHttpRoute := &gatewayapiv1.HTTPRoute{} + actualPredictorHttpRoute := &gwapiv1.HTTPRoute{} Eventually(func() error { return k8sClient.Get(context.TODO(), types.NamespacedName{ Name: predictorServiceKey.Name, @@ -8535,24 +8551,24 @@ var _ = Describe("v1beta1 inference service controller", func() { }, timeout). Should(Succeed()) predictorHost := fmt.Sprintf("%s-%s.%s", predictorServiceKey.Name, serviceKey.Namespace, "example.com") - expectedPredictorHttpRoute := gatewayapiv1.HTTPRoute{ - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{gatewayapiv1.Hostname(predictorHost)}, - Rules: []gatewayapiv1.HTTPRouteRule{ + expectedPredictorHttpRoute := gwapiv1.HTTPRoute{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{gwapiv1.Hostname(predictorHost)}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(constants.FallbackPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -8565,32 +8581,32 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(predictorServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(predictorServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("60s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("60s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, }, }, @@ -8598,7 +8614,7 @@ var _ = Describe("v1beta1 inference service controller", func() { } Expect(actualPredictorHttpRoute.Spec).To(BeComparableTo(expectedPredictorHttpRoute.Spec)) - actualTransformerHttpRoute := &gatewayapiv1.HTTPRoute{} + actualTransformerHttpRoute := &gwapiv1.HTTPRoute{} Eventually(func() error { return k8sClient.Get(context.TODO(), types.NamespacedName{ Name: transformerServiceKey.Name, @@ -8607,24 +8623,24 @@ var _ = Describe("v1beta1 inference service controller", func() { }, timeout). Should(Succeed()) transformerHost := fmt.Sprintf("%s-%s.%s", transformerServiceKey.Name, serviceKey.Namespace, "example.com") - expectedTransformerHttpRoute := gatewayapiv1.HTTPRoute{ - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{gatewayapiv1.Hostname(transformerHost)}, - Rules: []gatewayapiv1.HTTPRouteRule{ + expectedTransformerHttpRoute := gwapiv1.HTTPRoute{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{gwapiv1.Hostname(transformerHost)}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(constants.FallbackPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -8637,32 +8653,32 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(transformerServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(transformerServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("30s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("30s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, }, }, @@ -8671,20 +8687,20 @@ var _ = Describe("v1beta1 inference service controller", func() { Expect(actualTransformerHttpRoute.Spec).To(BeComparableTo(expectedTransformerHttpRoute.Spec)) // Mark the Ingress as accepted to make isvc ready - httpRouteStatus := gatewayapiv1.HTTPRouteStatus{ - RouteStatus: gatewayapiv1.RouteStatus{ - Parents: []gatewayapiv1.RouteParentStatus{ + httpRouteStatus := gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ { - ParentRef: gatewayapiv1.ParentReference{ - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + ParentRef: gwapiv1.ParentReference{ + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, ControllerName: "istio.io/gateway-controller", Conditions: []metav1.Condition{ { - Type: string(gatewayapiv1.ListenerConditionAccepted), + Type: string(gwapiv1.ListenerConditionAccepted), Status: metav1.ConditionTrue, Reason: "Accepted", Message: "Route was valid", @@ -9364,7 +9380,7 @@ var _ = Describe("v1beta1 inference service controller", func() { Expect(k8sClient.Status().Update(context.TODO(), updatedExplainerDeployment)).NotTo(HaveOccurred()) // check http route - actualToplevelHttpRoute := &gatewayapiv1.HTTPRoute{} + actualToplevelHttpRoute := &gwapiv1.HTTPRoute{} Eventually(func() error { return k8sClient.Get(context.TODO(), types.NamespacedName{ Name: serviceKey.Name, @@ -9374,24 +9390,24 @@ var _ = Describe("v1beta1 inference service controller", func() { Should(Succeed()) topLevelHost := fmt.Sprintf("%s-%s.%s", serviceKey.Name, serviceKey.Namespace, "example.com") prefixUrlPath := fmt.Sprintf("/serving/%s/%s", serviceKey.Namespace, serviceKey.Name) - expectedToplevelHttpRoute := gatewayapiv1.HTTPRoute{ - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{gatewayapiv1.Hostname(topLevelHost), gatewayapiv1.Hostname(fmt.Sprintf("%s-%s.additional.example.com", serviceKey.Name, serviceKey.Namespace)), "example.com"}, - Rules: []gatewayapiv1.HTTPRouteRule{ + expectedToplevelHttpRoute := gwapiv1.HTTPRoute{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{gwapiv1.Hostname(topLevelHost), gwapiv1.Hostname(fmt.Sprintf("%s-%s.additional.example.com", serviceKey.Name, serviceKey.Namespace)), "example.com"}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(constants.ExplainPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -9404,38 +9420,38 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(explainerServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(explainerServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("30s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("30s")), }, }, { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(constants.FallbackPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -9448,38 +9464,38 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(predictorServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(predictorServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("60s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("60s")), }, }, { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(prefixUrlPath + constants.PathBasedExplainPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -9492,38 +9508,38 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(explainerServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(explainerServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("30s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("30s")), }, }, { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(prefixUrlPath + "/"), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -9536,32 +9552,32 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(predictorServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(predictorServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("60s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("60s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, }, }, @@ -9569,7 +9585,7 @@ var _ = Describe("v1beta1 inference service controller", func() { } Expect(actualToplevelHttpRoute.Spec).To(BeComparableTo(expectedToplevelHttpRoute.Spec)) - actualPredictorHttpRoute := &gatewayapiv1.HTTPRoute{} + actualPredictorHttpRoute := &gwapiv1.HTTPRoute{} Eventually(func() error { return k8sClient.Get(context.TODO(), types.NamespacedName{ Name: predictorServiceKey.Name, @@ -9578,24 +9594,24 @@ var _ = Describe("v1beta1 inference service controller", func() { }, timeout). Should(Succeed()) predictorHost := fmt.Sprintf("%s-%s.%s", predictorServiceKey.Name, serviceKey.Namespace, "example.com") - expectedPredictorHttpRoute := gatewayapiv1.HTTPRoute{ - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{gatewayapiv1.Hostname(predictorHost)}, - Rules: []gatewayapiv1.HTTPRouteRule{ + expectedPredictorHttpRoute := gwapiv1.HTTPRoute{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{gwapiv1.Hostname(predictorHost)}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(constants.FallbackPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -9608,32 +9624,32 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(predictorServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(predictorServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("60s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("60s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, }, }, @@ -9641,7 +9657,7 @@ var _ = Describe("v1beta1 inference service controller", func() { } Expect(actualPredictorHttpRoute.Spec).To(BeComparableTo(expectedPredictorHttpRoute.Spec)) - actualExplainerHttpRoute := &gatewayapiv1.HTTPRoute{} + actualExplainerHttpRoute := &gwapiv1.HTTPRoute{} Eventually(func() error { return k8sClient.Get(context.TODO(), types.NamespacedName{ Name: explainerServiceKey.Name, @@ -9650,24 +9666,24 @@ var _ = Describe("v1beta1 inference service controller", func() { }, timeout). Should(Succeed()) explainerHost := fmt.Sprintf("%s-%s.%s", explainerServiceKey.Name, serviceKey.Namespace, "example.com") - expectedExplainerHttpRoute := gatewayapiv1.HTTPRoute{ - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{gatewayapiv1.Hostname(explainerHost)}, - Rules: []gatewayapiv1.HTTPRouteRule{ + expectedExplainerHttpRoute := gwapiv1.HTTPRoute{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{gwapiv1.Hostname(explainerHost)}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(constants.FallbackPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: serviceKey.Name, @@ -9680,32 +9696,32 @@ var _ = Describe("v1beta1 inference service controller", func() { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Group: (*gatewayapiv1.Group)(ptr.To("")), - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(explainerServiceKey.Name), - Namespace: (*gatewayapiv1.Namespace)(ptr.To(serviceKey.Namespace)), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Group: (*gwapiv1.Group)(ptr.To("")), + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(explainerServiceKey.Name), + Namespace: (*gwapiv1.Namespace)(ptr.To(serviceKey.Namespace)), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, Weight: ptr.To(int32(1)), }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("30s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("30s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, }, }, @@ -9714,20 +9730,20 @@ var _ = Describe("v1beta1 inference service controller", func() { Expect(actualExplainerHttpRoute.Spec).To(BeComparableTo(expectedExplainerHttpRoute.Spec)) // Mark the Ingress as accepted to make isvc ready - httpRouteStatus := gatewayapiv1.HTTPRouteStatus{ - RouteStatus: gatewayapiv1.RouteStatus{ - Parents: []gatewayapiv1.RouteParentStatus{ + httpRouteStatus := gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ { - ParentRef: gatewayapiv1.ParentReference{ - Name: gatewayapiv1.ObjectName(kserveGateway.Name), - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace(kserveGateway.Namespace)), + ParentRef: gwapiv1.ParentReference{ + Name: gwapiv1.ObjectName(kserveGateway.Name), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace(kserveGateway.Namespace)), }, ControllerName: "istio.io/gateway-controller", Conditions: []metav1.Condition{ { - Type: string(gatewayapiv1.ListenerConditionAccepted), + Type: string(gwapiv1.ListenerConditionAccepted), Status: metav1.ConditionTrue, Reason: "Accepted", Message: "Route was valid", diff --git a/pkg/controller/v1beta1/inferenceservice/reconcilers/ingress/httproute_reconciler.go b/pkg/controller/v1beta1/inferenceservice/reconcilers/ingress/httproute_reconciler.go index 7832600a213..b0678e2e450 100644 --- a/pkg/controller/v1beta1/inferenceservice/reconcilers/ingress/httproute_reconciler.go +++ b/pkg/controller/v1beta1/inferenceservice/reconcilers/ingress/httproute_reconciler.go @@ -28,13 +28,13 @@ import ( "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/types" "k8s.io/utils/ptr" - "knative.dev/pkg/apis" knapis "knative.dev/pkg/apis" duckv1 "knative.dev/pkg/apis/duck/v1" "knative.dev/pkg/network" + ctrl "sigs.k8s.io/controller-runtime" "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/controller-runtime/pkg/controller/controllerutil" - gatewayapiv1 "sigs.k8s.io/gateway-api/apis/v1" + gwapiv1 "sigs.k8s.io/gateway-api/apis/v1" "github.com/kserve/kserve/pkg/apis/serving/v1beta1" "github.com/kserve/kserve/pkg/constants" @@ -67,8 +67,8 @@ func NewRawHTTPRouteReconciler(client client.Client, scheme *runtime.Scheme, ing } // toGatewayAPIDuration converts seconds to gatewayapiv1.Duration -func toGatewayAPIDuration(seconds int64) *gatewayapiv1.Duration { - duration := gatewayapiv1.Duration(fmt.Sprintf("%ds", seconds)) +func toGatewayAPIDuration(seconds int64) *gwapiv1.Duration { + duration := gwapiv1.Duration(fmt.Sprintf("%ds", seconds)) return &duration } @@ -95,20 +95,20 @@ func getRawServiceHost(isvc *v1beta1.InferenceService) string { return network.GetServiceHostname(predictorName, isvc.Namespace) } -func createHTTPRouteMatch(prefix string) gatewayapiv1.HTTPRouteMatch { - return gatewayapiv1.HTTPRouteMatch{ - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), +func createHTTPRouteMatch(prefix string) gwapiv1.HTTPRouteMatch { + return gwapiv1.HTTPRouteMatch{ + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(prefix), }, } } -func addIsvcHeaders(name string, namespace string) gatewayapiv1.HTTPRouteFilter { - return gatewayapiv1.HTTPRouteFilter{ - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ +func addIsvcHeaders(name string, namespace string) gwapiv1.HTTPRouteFilter { + return gwapiv1.HTTPRouteFilter{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: name, @@ -122,29 +122,29 @@ func addIsvcHeaders(name string, namespace string) gatewayapiv1.HTTPRouteFilter } } -func createHTTPRouteRule(routeMatches []gatewayapiv1.HTTPRouteMatch, filters []gatewayapiv1.HTTPRouteFilter, - serviceName, namespace string, port int32, timeout *gatewayapiv1.Duration, -) gatewayapiv1.HTTPRouteRule { - var backendRefs []gatewayapiv1.HTTPBackendRef +func createHTTPRouteRule(routeMatches []gwapiv1.HTTPRouteMatch, filters []gwapiv1.HTTPRouteFilter, + serviceName, namespace string, port int32, timeout *gwapiv1.Duration, +) gwapiv1.HTTPRouteRule { + var backendRefs []gwapiv1.HTTPBackendRef if serviceName != "" { - backendRefs = []gatewayapiv1.HTTPBackendRef{ + backendRefs = []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), - Name: gatewayapiv1.ObjectName(serviceName), - Namespace: (*gatewayapiv1.Namespace)(&namespace), - Port: (*gatewayapiv1.PortNumber)(&port), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), + Name: gwapiv1.ObjectName(serviceName), + Namespace: (*gwapiv1.Namespace)(&namespace), + Port: (*gwapiv1.PortNumber)(&port), }, }, }, } } - return gatewayapiv1.HTTPRouteRule{ + return gwapiv1.HTTPRouteRule{ Matches: routeMatches, Filters: filters, BackendRefs: backendRefs, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ + Timeouts: &gwapiv1.HTTPRouteTimeouts{ Request: timeout, }, } @@ -152,12 +152,12 @@ func createHTTPRouteRule(routeMatches []gatewayapiv1.HTTPRouteMatch, filters []g func createRawPredictorHTTPRoute(isvc *v1beta1.InferenceService, ingressConfig *v1beta1.IngressConfig, isvcConfig *v1beta1.InferenceServicesConfig, -) (*gatewayapiv1.HTTPRoute, error) { - var httpRouteRules []gatewayapiv1.HTTPRouteRule - var allowedHosts []gatewayapiv1.Hostname +) (*gwapiv1.HTTPRoute, error) { + var httpRouteRules []gwapiv1.HTTPRouteRule + var allowedHosts []gwapiv1.Hostname if !isvc.Status.IsConditionReady(v1beta1.PredictorReady) { - isvc.Status.SetCondition(v1beta1.IngressReady, &apis.Condition{ + isvc.Status.SetCondition(v1beta1.IngressReady, &knapis.Condition{ Type: v1beta1.IngressReady, Status: corev1.ConditionFalse, Reason: "Predictor ingress not created", @@ -167,15 +167,15 @@ func createRawPredictorHTTPRoute(isvc *v1beta1.InferenceService, ingressConfig * predictorName := constants.PredictorServiceName(isvc.Name) // Add isvc name and namespace headers - filters := []gatewayapiv1.HTTPRouteFilter{addIsvcHeaders(isvc.Name, isvc.Namespace)} + filters := []gwapiv1.HTTPRouteFilter{addIsvcHeaders(isvc.Name, isvc.Namespace)} // Add predictor host rules predictorHost, err := GenerateDomainName(predictorName, isvc.ObjectMeta, ingressConfig) if err != nil { return nil, fmt.Errorf("failed to generate predictor ingress host: %w", err) } - allowedHosts = append(allowedHosts, gatewayapiv1.Hostname(predictorHost)) - routeMatch := []gatewayapiv1.HTTPRouteMatch{createHTTPRouteMatch(constants.FallbackPrefix())} + allowedHosts = append(allowedHosts, gwapiv1.Hostname(predictorHost)) + routeMatch := []gwapiv1.HTTPRouteMatch{createHTTPRouteMatch(constants.FallbackPrefix())} timeout := DefaultTimeout if isvc.Spec.Predictor.TimeoutSeconds != nil { timeout = toGatewayAPIDuration(*isvc.Spec.Predictor.TimeoutSeconds) @@ -189,23 +189,23 @@ func createRawPredictorHTTPRoute(isvc *v1beta1.InferenceService, ingressConfig * return !utils.Includes(isvcConfig.ServiceLabelDisallowedList, key) }) gatewaySlice := strings.Split(ingressConfig.KserveIngressGateway, "/") - httpRoute := gatewayapiv1.HTTPRoute{ + httpRoute := gwapiv1.HTTPRoute{ ObjectMeta: metav1.ObjectMeta{ Name: constants.PredictorServiceName(isvc.Name), Namespace: isvc.Namespace, Annotations: annotations, Labels: labels, }, - Spec: gatewayapiv1.HTTPRouteSpec{ + Spec: gwapiv1.HTTPRouteSpec{ Hostnames: allowedHosts, Rules: httpRouteRules, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Kind: (*gatewayapiv1.Kind)(ptr.To(constants.GatewayKind)), - Namespace: (*gatewayapiv1.Namespace)(&gatewaySlice[0]), - Name: gatewayapiv1.ObjectName(gatewaySlice[1]), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Kind: (*gwapiv1.Kind)(ptr.To(constants.GatewayKind)), + Namespace: (*gwapiv1.Namespace)(&gatewaySlice[0]), + Name: gwapiv1.ObjectName(gatewaySlice[1]), }, }, }, @@ -216,12 +216,12 @@ func createRawPredictorHTTPRoute(isvc *v1beta1.InferenceService, ingressConfig * func createRawTransformerHTTPRoute(isvc *v1beta1.InferenceService, ingressConfig *v1beta1.IngressConfig, isvcConfig *v1beta1.InferenceServicesConfig, -) (*gatewayapiv1.HTTPRoute, error) { - var httpRouteRules []gatewayapiv1.HTTPRouteRule - var allowedHosts []gatewayapiv1.Hostname +) (*gwapiv1.HTTPRoute, error) { + var httpRouteRules []gwapiv1.HTTPRouteRule + var allowedHosts []gwapiv1.Hostname if !isvc.Status.IsConditionReady(v1beta1.TransformerReady) { - isvc.Status.SetCondition(v1beta1.IngressReady, &apis.Condition{ + isvc.Status.SetCondition(v1beta1.IngressReady, &knapis.Condition{ Type: v1beta1.IngressReady, Status: corev1.ConditionFalse, Reason: "Transformer ingress not created", @@ -231,14 +231,14 @@ func createRawTransformerHTTPRoute(isvc *v1beta1.InferenceService, ingressConfig transformerName := constants.TransformerServiceName(isvc.Name) // Add isvc name and namespace headers - filters := []gatewayapiv1.HTTPRouteFilter{addIsvcHeaders(isvc.Name, isvc.Namespace)} + filters := []gwapiv1.HTTPRouteFilter{addIsvcHeaders(isvc.Name, isvc.Namespace)} transformerHost, err := GenerateDomainName(transformerName, isvc.ObjectMeta, ingressConfig) if err != nil { return nil, fmt.Errorf("failed to generate transformer ingress host: %w", err) } - allowedHosts = append(allowedHosts, gatewayapiv1.Hostname(transformerHost)) - routeMatch := []gatewayapiv1.HTTPRouteMatch{createHTTPRouteMatch(constants.FallbackPrefix())} + allowedHosts = append(allowedHosts, gwapiv1.Hostname(transformerHost)) + routeMatch := []gwapiv1.HTTPRouteMatch{createHTTPRouteMatch(constants.FallbackPrefix())} timeout := DefaultTimeout if isvc.Spec.Transformer.TimeoutSeconds != nil { timeout = toGatewayAPIDuration(*isvc.Spec.Transformer.TimeoutSeconds) @@ -253,23 +253,23 @@ func createRawTransformerHTTPRoute(isvc *v1beta1.InferenceService, ingressConfig return !utils.Includes(isvcConfig.ServiceLabelDisallowedList, key) }) gatewaySlice := strings.Split(ingressConfig.KserveIngressGateway, "/") - httpRoute := gatewayapiv1.HTTPRoute{ + httpRoute := gwapiv1.HTTPRoute{ ObjectMeta: metav1.ObjectMeta{ Name: constants.TransformerServiceName(isvc.Name), Namespace: isvc.Namespace, Annotations: annotations, Labels: labels, }, - Spec: gatewayapiv1.HTTPRouteSpec{ + Spec: gwapiv1.HTTPRouteSpec{ Hostnames: allowedHosts, Rules: httpRouteRules, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Kind: (*gatewayapiv1.Kind)(ptr.To(constants.GatewayKind)), - Namespace: (*gatewayapiv1.Namespace)(&gatewaySlice[0]), - Name: gatewayapiv1.ObjectName(gatewaySlice[1]), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Kind: (*gwapiv1.Kind)(ptr.To(constants.GatewayKind)), + Namespace: (*gwapiv1.Namespace)(&gatewaySlice[0]), + Name: gwapiv1.ObjectName(gatewaySlice[1]), }, }, }, @@ -280,12 +280,12 @@ func createRawTransformerHTTPRoute(isvc *v1beta1.InferenceService, ingressConfig func createRawExplainerHTTPRoute(isvc *v1beta1.InferenceService, ingressConfig *v1beta1.IngressConfig, isvcConfig *v1beta1.InferenceServicesConfig, -) (*gatewayapiv1.HTTPRoute, error) { - var httpRouteRules []gatewayapiv1.HTTPRouteRule - var allowedHosts []gatewayapiv1.Hostname +) (*gwapiv1.HTTPRoute, error) { + var httpRouteRules []gwapiv1.HTTPRouteRule + var allowedHosts []gwapiv1.Hostname if !isvc.Status.IsConditionReady(v1beta1.ExplainerReady) { - isvc.Status.SetCondition(v1beta1.IngressReady, &apis.Condition{ + isvc.Status.SetCondition(v1beta1.IngressReady, &knapis.Condition{ Type: v1beta1.IngressReady, Status: corev1.ConditionFalse, Reason: "Explainer ingress not created", @@ -295,16 +295,16 @@ func createRawExplainerHTTPRoute(isvc *v1beta1.InferenceService, ingressConfig * explainerName := constants.ExplainerServiceName(isvc.Name) // Add isvc name and namespace headers - filters := []gatewayapiv1.HTTPRouteFilter{addIsvcHeaders(isvc.Name, isvc.Namespace)} + filters := []gwapiv1.HTTPRouteFilter{addIsvcHeaders(isvc.Name, isvc.Namespace)} explainerHost, err := GenerateDomainName(explainerName, isvc.ObjectMeta, ingressConfig) if err != nil { return nil, fmt.Errorf("failed to generate explainer ingress host: %w", err) } - allowedHosts = append(allowedHosts, gatewayapiv1.Hostname(explainerHost)) + allowedHosts = append(allowedHosts, gwapiv1.Hostname(explainerHost)) // Add explainer host rules - routeMatch := []gatewayapiv1.HTTPRouteMatch{createHTTPRouteMatch(constants.FallbackPrefix())} + routeMatch := []gwapiv1.HTTPRouteMatch{createHTTPRouteMatch(constants.FallbackPrefix())} timeout := DefaultTimeout if isvc.Spec.Explainer.TimeoutSeconds != nil { timeout = toGatewayAPIDuration(*isvc.Spec.Explainer.TimeoutSeconds) @@ -319,23 +319,23 @@ func createRawExplainerHTTPRoute(isvc *v1beta1.InferenceService, ingressConfig * return !utils.Includes(isvcConfig.ServiceLabelDisallowedList, key) }) gatewaySlice := strings.Split(ingressConfig.KserveIngressGateway, "/") - httpRoute := gatewayapiv1.HTTPRoute{ + httpRoute := gwapiv1.HTTPRoute{ ObjectMeta: metav1.ObjectMeta{ Name: constants.ExplainerServiceName(isvc.Name), Namespace: isvc.Namespace, Annotations: annotations, Labels: labels, }, - Spec: gatewayapiv1.HTTPRouteSpec{ + Spec: gwapiv1.HTTPRouteSpec{ Hostnames: allowedHosts, Rules: httpRouteRules, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Kind: (*gatewayapiv1.Kind)(ptr.To(constants.GatewayKind)), - Namespace: (*gatewayapiv1.Namespace)(&gatewaySlice[0]), - Name: gatewayapiv1.ObjectName(gatewaySlice[1]), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Kind: (*gwapiv1.Kind)(ptr.To(constants.GatewayKind)), + Namespace: (*gwapiv1.Namespace)(&gatewaySlice[0]), + Name: gwapiv1.ObjectName(gatewaySlice[1]), }, }, }, @@ -346,12 +346,12 @@ func createRawExplainerHTTPRoute(isvc *v1beta1.InferenceService, ingressConfig * func createRawTopLevelHTTPRoute(isvc *v1beta1.InferenceService, ingressConfig *v1beta1.IngressConfig, isvcConfig *v1beta1.InferenceServicesConfig, -) (*gatewayapiv1.HTTPRoute, error) { - var httpRouteRules []gatewayapiv1.HTTPRouteRule - var allowedHosts []gatewayapiv1.Hostname +) (*gwapiv1.HTTPRoute, error) { + var httpRouteRules []gwapiv1.HTTPRouteRule + var allowedHosts []gwapiv1.Hostname if !isvc.Status.IsConditionReady(v1beta1.PredictorReady) { - isvc.Status.SetCondition(v1beta1.IngressReady, &apis.Condition{ + isvc.Status.SetCondition(v1beta1.IngressReady, &knapis.Condition{ Type: v1beta1.IngressReady, Status: corev1.ConditionFalse, Reason: "Predictor ingress not created", @@ -366,29 +366,29 @@ func createRawTopLevelHTTPRoute(isvc *v1beta1.InferenceService, ingressConfig *v if err != nil { return nil, fmt.Errorf("failed to generate top level ingress host: %w", err) } - allowedHosts = append(allowedHosts, gatewayapiv1.Hostname(topLevelHost)) + allowedHosts = append(allowedHosts, gwapiv1.Hostname(topLevelHost)) domainList := []string{ingressConfig.IngressDomain} additionalHosts := GetAdditionalHosts(&domainList, topLevelHost, ingressConfig) // Add additional hosts to allowed hosts if additionalHosts != nil { - hostMap := make(map[gatewayapiv1.Hostname]bool, len(allowedHosts)) + hostMap := make(map[gwapiv1.Hostname]bool, len(allowedHosts)) for _, host := range allowedHosts { hostMap[host] = true } for _, additionalHost := range *additionalHosts { - gwHost := gatewayapiv1.Hostname(additionalHost) + gwHost := gwapiv1.Hostname(additionalHost) if _, found := hostMap[gwHost]; !found { allowedHosts = append(allowedHosts, gwHost) } } } // Add isvc name and namespace headers - filters := []gatewayapiv1.HTTPRouteFilter{addIsvcHeaders(isvc.Name, isvc.Namespace)} + filters := []gwapiv1.HTTPRouteFilter{addIsvcHeaders(isvc.Name, isvc.Namespace)} if isvc.Spec.Explainer != nil { // Scenario: When explainer present if !isvc.Status.IsConditionReady(v1beta1.ExplainerReady) { - isvc.Status.SetCondition(v1beta1.IngressReady, &apis.Condition{ + isvc.Status.SetCondition(v1beta1.IngressReady, &knapis.Condition{ Type: v1beta1.IngressReady, Status: corev1.ConditionFalse, Reason: "Explainer ingress not created", @@ -401,14 +401,14 @@ func createRawTopLevelHTTPRoute(isvc *v1beta1.InferenceService, ingressConfig *v } // Add toplevel host :explain route // :explain routes to the explainer when there is only explainer - explainRouteMatch := []gatewayapiv1.HTTPRouteMatch{createHTTPRouteMatch(constants.ExplainPrefix())} + explainRouteMatch := []gwapiv1.HTTPRouteMatch{createHTTPRouteMatch(constants.ExplainPrefix())} httpRouteRules = append(httpRouteRules, createHTTPRouteRule(explainRouteMatch, filters, explainerName, isvc.Namespace, constants.CommonDefaultHttpPort, timeout)) } if isvc.Spec.Transformer != nil { // Scenario: When predictor with transformer and with/without explainer present if !isvc.Status.IsConditionReady(v1beta1.TransformerReady) { - isvc.Status.SetCondition(v1beta1.IngressReady, &apis.Condition{ + isvc.Status.SetCondition(v1beta1.IngressReady, &knapis.Condition{ Type: v1beta1.IngressReady, Status: corev1.ConditionFalse, Reason: "Transformer ingress not created", @@ -420,7 +420,7 @@ func createRawTopLevelHTTPRoute(isvc *v1beta1.InferenceService, ingressConfig *v timeout = toGatewayAPIDuration(*isvc.Spec.Transformer.TimeoutSeconds) } // :predict routes to the transformer when there are both predictor and transformer - routeMatch := []gatewayapiv1.HTTPRouteMatch{createHTTPRouteMatch(constants.FallbackPrefix())} + routeMatch := []gwapiv1.HTTPRouteMatch{createHTTPRouteMatch(constants.FallbackPrefix())} httpRouteRules = append(httpRouteRules, createHTTPRouteRule(routeMatch, filters, transformerName, isvc.Namespace, constants.CommonDefaultHttpPort, timeout)) } else { // Scenario: When predictor without transformer and with/without explainer present @@ -429,7 +429,7 @@ func createRawTopLevelHTTPRoute(isvc *v1beta1.InferenceService, ingressConfig *v timeout = toGatewayAPIDuration(*isvc.Spec.Predictor.TimeoutSeconds) } // Add toplevel host rules for predictor which routes all traffic to predictor - routeMatch := []gatewayapiv1.HTTPRouteMatch{createHTTPRouteMatch(constants.FallbackPrefix())} + routeMatch := []gwapiv1.HTTPRouteMatch{createHTTPRouteMatch(constants.FallbackPrefix())} httpRouteRules = append(httpRouteRules, createHTTPRouteRule(routeMatch, filters, predictorName, isvc.Namespace, constants.CommonDefaultHttpPort, timeout)) } @@ -442,7 +442,7 @@ func createRawTopLevelHTTPRoute(isvc *v1beta1.InferenceService, ingressConfig *v } path = strings.TrimSuffix(path, "/") // remove trailing "/" if present // Include ingressDomain to the allowed hosts - allowedHosts = append(allowedHosts, gatewayapiv1.Hostname(ingressConfig.IngressDomain)) + allowedHosts = append(allowedHosts, gwapiv1.Hostname(ingressConfig.IngressDomain)) if isvc.Spec.Explainer != nil { timeout := DefaultTimeout @@ -450,7 +450,7 @@ func createRawTopLevelHTTPRoute(isvc *v1beta1.InferenceService, ingressConfig *v timeout = toGatewayAPIDuration(*isvc.Spec.Explainer.TimeoutSeconds) } // Add path based routing rule for :explain endpoint - explainerPathRouteMatch := []gatewayapiv1.HTTPRouteMatch{createHTTPRouteMatch(path + constants.PathBasedExplainPrefix())} + explainerPathRouteMatch := []gwapiv1.HTTPRouteMatch{createHTTPRouteMatch(path + constants.PathBasedExplainPrefix())} httpRouteRules = append(httpRouteRules, createHTTPRouteRule(explainerPathRouteMatch, filters, explainerName, isvc.Namespace, constants.CommonDefaultHttpPort, timeout)) } @@ -461,7 +461,7 @@ func createRawTopLevelHTTPRoute(isvc *v1beta1.InferenceService, ingressConfig *v timeout = toGatewayAPIDuration(*isvc.Spec.Transformer.TimeoutSeconds) } // :predict routes to the transformer when there are both predictor and transformer - pathRouteMatch := []gatewayapiv1.HTTPRouteMatch{createHTTPRouteMatch(path + "/")} + pathRouteMatch := []gwapiv1.HTTPRouteMatch{createHTTPRouteMatch(path + "/")} httpRouteRules = append(httpRouteRules, createHTTPRouteRule(pathRouteMatch, filters, transformerName, isvc.Namespace, constants.CommonDefaultHttpPort, timeout)) } else { @@ -470,7 +470,7 @@ func createRawTopLevelHTTPRoute(isvc *v1beta1.InferenceService, ingressConfig *v timeout = toGatewayAPIDuration(*isvc.Spec.Predictor.TimeoutSeconds) } // :predict routes to the predictor when there is only predictor - pathRouteMatch := []gatewayapiv1.HTTPRouteMatch{createHTTPRouteMatch(path + "/")} + pathRouteMatch := []gwapiv1.HTTPRouteMatch{createHTTPRouteMatch(path + "/")} httpRouteRules = append(httpRouteRules, createHTTPRouteRule(pathRouteMatch, filters, predictorName, isvc.Namespace, constants.CommonDefaultHttpPort, timeout)) } @@ -483,23 +483,23 @@ func createRawTopLevelHTTPRoute(isvc *v1beta1.InferenceService, ingressConfig *v return !utils.Includes(isvcConfig.ServiceLabelDisallowedList, key) }) gatewaySlice := strings.Split(ingressConfig.KserveIngressGateway, "/") - httpRoute := gatewayapiv1.HTTPRoute{ + httpRoute := gwapiv1.HTTPRoute{ ObjectMeta: metav1.ObjectMeta{ Name: isvc.Name, Namespace: isvc.Namespace, Annotations: annotations, Labels: labels, }, - Spec: gatewayapiv1.HTTPRouteSpec{ + Spec: gwapiv1.HTTPRouteSpec{ Hostnames: allowedHosts, Rules: httpRouteRules, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Kind: (*gatewayapiv1.Kind)(ptr.To(constants.GatewayKind)), - Namespace: (*gatewayapiv1.Namespace)(&gatewaySlice[0]), - Name: gatewayapiv1.ObjectName(gatewaySlice[1]), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Kind: (*gwapiv1.Kind)(ptr.To(constants.GatewayKind)), + Namespace: (*gwapiv1.Namespace)(&gatewaySlice[0]), + Name: gwapiv1.ObjectName(gatewaySlice[1]), }, }, }, @@ -508,14 +508,14 @@ func createRawTopLevelHTTPRoute(isvc *v1beta1.InferenceService, ingressConfig *v return &httpRoute, nil } -func semanticHttpRouteEquals(desired, existing *gatewayapiv1.HTTPRoute) bool { +func semanticHttpRouteEquals(desired, existing *gwapiv1.HTTPRoute) bool { return equality.Semantic.DeepDerivative(desired.Spec, existing.Spec) && equality.Semantic.DeepDerivative(desired.Labels, existing.Labels) && equality.Semantic.DeepDerivative(desired.Annotations, existing.Annotations) } // isHTTPRouteReady checks if the HTTPRoute is ready. If not, returns the reason and message. -func isHTTPRouteReady(httpRouteStatus gatewayapiv1.HTTPRouteStatus) (bool, *string, *string) { +func isHTTPRouteReady(httpRouteStatus gwapiv1.HTTPRouteStatus) (bool, *string, *string) { if len(httpRouteStatus.Parents) == 0 { return false, ptr.To(HTTPRouteParentStatusNotAvailable), ptr.To(HTTPRouteNotReady) } @@ -537,7 +537,7 @@ func (r *RawHTTPRouteReconciler) reconcilePredictorHTTPRoute(ctx context.Context // reconcile httpRoute httpRouteName := constants.PredictorServiceName(isvc.Name) - existingHttpRoute := &gatewayapiv1.HTTPRoute{} + existingHttpRoute := &gwapiv1.HTTPRoute{} getExistingErr := r.client.Get(ctx, types.NamespacedName{ Namespace: isvc.Namespace, Name: httpRouteName, @@ -600,7 +600,7 @@ func (r *RawHTTPRouteReconciler) reconcileTransformerHTTPRoute(ctx context.Conte // reconcile httpRoute httpRouteName := constants.TransformerServiceName(isvc.Name) - existingHttpRoute := &gatewayapiv1.HTTPRoute{} + existingHttpRoute := &gwapiv1.HTTPRoute{} getExistingErr := r.client.Get(ctx, types.NamespacedName{ Name: httpRouteName, Namespace: isvc.Namespace, }, existingHttpRoute) @@ -660,7 +660,7 @@ func (r *RawHTTPRouteReconciler) reconcileExplainerHTTPRoute(ctx context.Context // reconcile httproute httpRouteName := constants.ExplainerServiceName(isvc.Name) - existingHttpRoute := &gatewayapiv1.HTTPRoute{} + existingHttpRoute := &gwapiv1.HTTPRoute{} getExistingErr := r.client.Get(ctx, types.NamespacedName{ Name: httpRouteName, Namespace: isvc.Namespace, }, existingHttpRoute) @@ -719,7 +719,7 @@ func (r *RawHTTPRouteReconciler) reconcileTopLevelHTTPRoute(ctx context.Context, } // reconcile httpRoute - existingHttpRoute := &gatewayapiv1.HTTPRoute{} + existingHttpRoute := &gwapiv1.HTTPRoute{} getExistingErr := r.client.Get(ctx, types.NamespacedName{ Namespace: isvc.Namespace, Name: isvc.Name, @@ -774,8 +774,89 @@ func (r *RawHTTPRouteReconciler) reconcileTopLevelHTTPRoute(ctx context.Context, return nil } +// reconcileHTTPRouteStatus checks the readiness status of HTTPRoutes associated with all components +// of an InferenceService. It iterates through Predictor, Transformer (if defined), Explainer (if defined), +// and the top level httproute. +// +// For each component, it retrieves the corresponding HTTPRoute and checks if it's ready. +// If any HTTPRoute is missing or not ready, it updates the InferenceService status with a +// condition indicating why ingress is not ready and requeues the request. +// If all HTTPRoutes are ready, it marks the InferenceService's IngressReady condition as true. +func (r *RawHTTPRouteReconciler) reconcileHTTPRouteStatus(ctx context.Context, isvc *v1beta1.InferenceService) (ctrl.Result, error) { + // Check HTTPRoute statuses for all components + type httpRouteCheck struct { + name string + component string + } + + checks := []httpRouteCheck{ + { + name: constants.PredictorServiceName(isvc.Name), + component: "Predictor", + }, + } + + if isvc.Spec.Transformer != nil { + checks = append(checks, httpRouteCheck{ + name: constants.TransformerServiceName(isvc.Name), + component: "Transformer", + }) + } + if isvc.Spec.Explainer != nil { + checks = append(checks, httpRouteCheck{ + name: constants.ExplainerServiceName(isvc.Name), + component: "Explainer", + }) + } + checks = append(checks, httpRouteCheck{ + name: isvc.Name, + component: "InferenceService", + }) + + for _, check := range checks { + httpRoute := &gwapiv1.HTTPRoute{} + if err := r.client.Get(ctx, types.NamespacedName{ + Name: check.name, + Namespace: isvc.Namespace, + }, httpRoute); err != nil { + if apierr.IsNotFound(err) { + // HTTPRoute not found means the component deployment is not ready yet, so we set the IngressReady condition to False + // and requeue the request with backoff period. + isvc.Status.SetCondition(v1beta1.IngressReady, &knapis.Condition{ + Type: v1beta1.IngressReady, + Status: corev1.ConditionFalse, + Reason: check.component + " Deployment NotReady", + Message: check.component + " HTTPRoute not created", + }) + return ctrl.Result{Requeue: true}, nil + } + // Return any other errors + return ctrl.Result{}, err + } + // Check if the HTTPRoute is ready + // If not, set the IngressReady condition to False and requeue the request with backoff period. + if ready, reason, message := isHTTPRouteReady(httpRoute.Status); !ready { + log.Info(check.component+" HTTPRoute not ready", "reason", *reason, "message", *message) + isvc.Status.SetCondition(v1beta1.IngressReady, &knapis.Condition{ + Type: v1beta1.IngressReady, + Status: corev1.ConditionFalse, + Reason: *reason, + Message: fmt.Sprintf("%s %s", check.component, *message), + }) + return ctrl.Result{Requeue: true}, nil + } + } + + // If we are here, then all the HTTPRoutes are ready, Mark ingress as ready + isvc.Status.SetCondition(v1beta1.IngressReady, &knapis.Condition{ + Type: v1beta1.IngressReady, + Status: corev1.ConditionTrue, + }) + return ctrl.Result{}, nil +} + // ReconcileHTTPRoute reconciles the HTTPRoute resource -func (r *RawHTTPRouteReconciler) Reconcile(ctx context.Context, isvc *v1beta1.InferenceService) error { +func (r *RawHTTPRouteReconciler) Reconcile(ctx context.Context, isvc *v1beta1.InferenceService) (ctrl.Result, error) { var err error isInternal := false // disable ingress creation if service is labelled with cluster local or kserve domain is cluster local @@ -787,128 +868,52 @@ func (r *RawHTTPRouteReconciler) Reconcile(ctx context.Context, isvc *v1beta1.In } if !isInternal && !r.ingressConfig.DisableIngressCreation { if err := r.reconcilePredictorHTTPRoute(ctx, isvc); err != nil { - return err + return ctrl.Result{}, err } if isvc.Spec.Transformer != nil { if err := r.reconcileTransformerHTTPRoute(ctx, isvc); err != nil { - return err + return ctrl.Result{}, err } } if isvc.Spec.Explainer != nil { if err := r.reconcileExplainerHTTPRoute(ctx, isvc); err != nil { - return err + return ctrl.Result{}, err } } if err := r.reconcileTopLevelHTTPRoute(ctx, isvc); err != nil { - return err + return ctrl.Result{}, err } if utils.GetForceStopRuntime(isvc) { - isvc.Status.SetCondition(v1beta1.IngressReady, &apis.Condition{ + isvc.Status.SetCondition(v1beta1.IngressReady, &knapis.Condition{ Type: v1beta1.IngressReady, Status: corev1.ConditionFalse, Reason: v1beta1.StoppedISVCReason, }) - return nil + return ctrl.Result{}, nil } - // Check Predictor HTTPRoute status - httpRoute := &gatewayapiv1.HTTPRoute{} - if err := r.client.Get(ctx, types.NamespacedName{ - Name: constants.PredictorServiceName(isvc.Name), - Namespace: isvc.Namespace, - }, httpRoute); err != nil { - return err + // Check HTTPRoute statuses for all components + if result, err := r.reconcileHTTPRouteStatus(ctx, isvc); err != nil || result.Requeue { + return result, err } - if ready, reason, message := isHTTPRouteReady(httpRoute.Status); !ready { - log.Info("Predictor HTTPRoute not ready", "reason", *reason, "message", *message) - isvc.Status.SetCondition(v1beta1.IngressReady, &apis.Condition{ - Type: v1beta1.IngressReady, - Status: corev1.ConditionFalse, - Reason: *reason, - Message: fmt.Sprintf("%s %s", "Predictor", *message), - }) - return nil - } - // Check Transformer HTTPRoute status - if isvc.Spec.Transformer != nil { - httpRoute = &gatewayapiv1.HTTPRoute{} - if err := r.client.Get(ctx, types.NamespacedName{ - Name: constants.TransformerServiceName(isvc.Name), - Namespace: isvc.Namespace, - }, httpRoute); err != nil { - return err - } - if ready, reason, message := isHTTPRouteReady(httpRoute.Status); !ready { - isvc.Status.SetCondition(v1beta1.IngressReady, &apis.Condition{ - Type: v1beta1.IngressReady, - Status: corev1.ConditionFalse, - Reason: *reason, - Message: fmt.Sprintf("%s %s", "Transformer", *message), - }) - return nil - } - } - // Check Explainer HTTPRoute status - if isvc.Spec.Explainer != nil { - httpRoute = &gatewayapiv1.HTTPRoute{} - if err := r.client.Get(ctx, types.NamespacedName{ - Name: constants.ExplainerServiceName(isvc.Name), - Namespace: isvc.Namespace, - }, httpRoute); err != nil { - return err - } - if ready, reason, message := isHTTPRouteReady(httpRoute.Status); !ready { - isvc.Status.SetCondition(v1beta1.IngressReady, &apis.Condition{ - Type: v1beta1.IngressReady, - Status: corev1.ConditionFalse, - Reason: *reason, - Message: fmt.Sprintf("%s %s", "Explainer", *message), - }) - return nil - } - } - // Check Top level HTTPRoute status - httpRoute = &gatewayapiv1.HTTPRoute{} - if err := r.client.Get(ctx, types.NamespacedName{ - Name: isvc.Name, - Namespace: isvc.Namespace, - }, httpRoute); err != nil { - return err - } - if ready, reason, message := isHTTPRouteReady(httpRoute.Status); !ready { - log.Info("Top level HTTPRoute not ready", "reason", *reason, "message", *message) - isvc.Status.SetCondition(v1beta1.IngressReady, &apis.Condition{ - Type: v1beta1.IngressReady, - Status: corev1.ConditionFalse, - Reason: *reason, - Message: fmt.Sprintf("%s %s", "TopLevel", *message), - }) - return nil - } - // If we are here, then all the HTTPRoutes are ready, Mark ingress as ready - isvc.Status.SetCondition(v1beta1.IngressReady, &apis.Condition{ - Type: v1beta1.IngressReady, - Status: corev1.ConditionTrue, - }) } else { // Ingress creation is disabled. We set it to true as the isvc condition depends on it. - isvc.Status.SetCondition(v1beta1.IngressReady, &apis.Condition{ + isvc.Status.SetCondition(v1beta1.IngressReady, &knapis.Condition{ Type: v1beta1.IngressReady, Status: corev1.ConditionTrue, }) } - isvc.Status.URL, err = createRawURL(isvc, r.ingressConfig) - if err != nil { - return err + if isvc.Status.URL, err = createRawURL(isvc, r.ingressConfig); err != nil { + return ctrl.Result{}, err } isvc.Status.Address = &duckv1.Addressable{ - URL: &apis.URL{ + URL: &knapis.URL{ Host: getRawServiceHost(isvc), Scheme: r.ingressConfig.UrlScheme, Path: "", }, } - return nil + return ctrl.Result{}, nil } diff --git a/pkg/controller/v1beta1/inferenceservice/reconcilers/ingress/httproute_reconciler_test.go b/pkg/controller/v1beta1/inferenceservice/reconcilers/ingress/httproute_reconciler_test.go index 766e13d812d..7e9d6a7f58f 100644 --- a/pkg/controller/v1beta1/inferenceservice/reconcilers/ingress/httproute_reconciler_test.go +++ b/pkg/controller/v1beta1/inferenceservice/reconcilers/ingress/httproute_reconciler_test.go @@ -17,6 +17,7 @@ limitations under the License. package ingress import ( + "context" "testing" "github.com/google/go-cmp/cmp/cmpopts" @@ -31,13 +32,42 @@ import ( "k8s.io/utils/ptr" "knative.dev/pkg/apis" duckv1 "knative.dev/pkg/apis/duck/v1" + ctrl "sigs.k8s.io/controller-runtime" + "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/controller-runtime/pkg/client/fake" - gatewayapiv1 "sigs.k8s.io/gateway-api/apis/v1" + "sigs.k8s.io/controller-runtime/pkg/controller/controllerutil" + gwapiv1 "sigs.k8s.io/gateway-api/apis/v1" "github.com/kserve/kserve/pkg/apis/serving/v1beta1" "github.com/kserve/kserve/pkg/constants" ) +// httpRouteClientInterceptor wraps a client.Client to simulate errors for testing +type httpRouteClientInterceptor struct { + client.Client + blockHTTPRouteCreation bool +} + +func (c *httpRouteClientInterceptor) Create(ctx context.Context, obj client.Object, opts ...client.CreateOption) error { + // Allow HTTPRoute creation to proceed normally + return c.Client.Create(ctx, obj, opts...) +} + +// Get intercepts Get calls to return NotFound for HTTPRoutes when blocked +func (c *httpRouteClientInterceptor) Get(ctx context.Context, key client.ObjectKey, obj client.Object, opts ...client.GetOption) error { + // Return NotFound for HTTPRoute Get calls when blocked + // This simulates the case where HTTPRoute was created but then deleted or not found during status checks + if c.blockHTTPRouteCreation { + if _, ok := obj.(*gwapiv1.HTTPRoute); ok { + return apierr.NewNotFound(schema.GroupResource{ + Group: gwapiv1.GroupVersion.Group, + Resource: "httproutes", + }, key.Name) + } + } + return c.Client.Get(ctx, key, obj, opts...) +} + func TestCreateRawURL(t *testing.T) { g := NewGomegaWithT(t) @@ -123,44 +153,8 @@ func TestGetRawServiceHost(t *testing.T) { }, expectedHost: "test-isvc-transformer.default.svc.cluster.local", }, - "predictor with default suffix": { - isvc: &v1beta1.InferenceService{ - ObjectMeta: metav1.ObjectMeta{ - Name: "test-isvc-pred-default", - Namespace: "default", - }, - Spec: v1beta1.InferenceServiceSpec{ - Predictor: v1beta1.PredictorSpec{}, - }, - }, - expectedHost: "test-isvc-pred-default-predictor.default.svc.cluster.local", - }, - "transformer with default suffix": { - isvc: &v1beta1.InferenceService{ - ObjectMeta: metav1.ObjectMeta{ - Name: "test-isvc-pred-default", - Namespace: "default", - }, - Spec: v1beta1.InferenceServiceSpec{ - Predictor: v1beta1.PredictorSpec{}, - Transformer: &v1beta1.TransformerSpec{}, - }, - }, - expectedHost: "test-isvc-pred-default-transformer.default.svc.cluster.local", - }, } - s := scheme.Scheme - s.AddKnownTypes(v1beta1.SchemeGroupVersion, &v1beta1.InferenceService{}) - client := fake.NewClientBuilder().WithScheme(s).Build() - // Create a dummy service to test default suffix cases - client.Create(t.Context(), &corev1.Service{ - ObjectMeta: metav1.ObjectMeta{ - Name: "test-isvc-pred-default", - Namespace: "default", - }, - Spec: corev1.ServiceSpec{}, - }) for name, tc := range testCases { t.Run(name, func(t *testing.T) { host := getRawServiceHost(tc.isvc) @@ -173,13 +167,13 @@ func TestCreateHTTPRouteMatch(t *testing.T) { g := NewGomegaWithT(t) testCases := map[string]struct { prefix string - expectedHTTPRoutes gatewayapiv1.HTTPRouteMatch + expectedHTTPRoutes gwapiv1.HTTPRouteMatch }{ "basic case": { prefix: "^.*$", - expectedHTTPRoutes: gatewayapiv1.HTTPRouteMatch{ - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + expectedHTTPRoutes: gwapiv1.HTTPRouteMatch{ + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To("^.*$"), }, }, @@ -209,7 +203,7 @@ func TestAddIsvcHeaders(t *testing.T) { for name, tc := range testCases { t.Run(name, func(t *testing.T) { headers := addIsvcHeaders(tc.isvcName, tc.isvcNamespace) - g.Expect(headers.Type).To(BeComparableTo(gatewayapiv1.HTTPRouteFilterRequestHeaderModifier)) + g.Expect(headers.Type).To(BeComparableTo(gwapiv1.HTTPRouteFilterRequestHeaderModifier)) g.Expect(headers.RequestHeaderModifier.Set).To(HaveLen(2)) g.Expect(string(headers.RequestHeaderModifier.Set[0].Name)).To(BeComparableTo(constants.IsvcNameHeader)) g.Expect(headers.RequestHeaderModifier.Set[0].Value).To(BeComparableTo(tc.isvcName)) @@ -222,22 +216,22 @@ func TestAddIsvcHeaders(t *testing.T) { func TestCreateHTTPRouteRule(t *testing.T) { g := NewGomegaWithT(t) testCases := map[string]struct { - matches []gatewayapiv1.HTTPRouteMatch - filters []gatewayapiv1.HTTPRouteFilter + matches []gwapiv1.HTTPRouteMatch + filters []gwapiv1.HTTPRouteFilter serviceName string servicePort int32 expectedRules int }{ "basic case": { - matches: []gatewayapiv1.HTTPRouteMatch{ + matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To("/predict"), }, }, }, - filters: []gatewayapiv1.HTTPRouteFilter{ + filters: []gwapiv1.HTTPRouteFilter{ addIsvcHeaders("test-isvc", "default"), }, serviceName: "test-service", @@ -260,32 +254,32 @@ func TestCreateHTTPRouteRule(t *testing.T) { func TestSemanticHttpRouteEquals(t *testing.T) { g := NewGomegaWithT(t) testCases := map[string]struct { - desired *gatewayapiv1.HTTPRoute - existing *gatewayapiv1.HTTPRoute + desired *gwapiv1.HTTPRoute + existing *gwapiv1.HTTPRoute expectedEqual bool }{ "equal routes": { - desired: &gatewayapiv1.HTTPRoute{ - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{"example.com"}, + desired: &gwapiv1.HTTPRoute{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{"example.com"}, }, }, - existing: &gatewayapiv1.HTTPRoute{ - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{"example.com"}, + existing: &gwapiv1.HTTPRoute{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{"example.com"}, }, }, expectedEqual: true, }, "different routes": { - desired: &gatewayapiv1.HTTPRoute{ - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{"example.com"}, + desired: &gwapiv1.HTTPRoute{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{"example.com"}, }, }, - existing: &gatewayapiv1.HTTPRoute{ - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{"different.com"}, + existing: &gwapiv1.HTTPRoute{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{"different.com"}, }, }, expectedEqual: false, @@ -302,23 +296,23 @@ func TestSemanticHttpRouteEquals(t *testing.T) { func TestIsHTTPRouteReady(t *testing.T) { g := NewGomegaWithT(t) testCases := map[string]struct { - httpRouteStatus gatewayapiv1.HTTPRouteStatus + httpRouteStatus gwapiv1.HTTPRouteStatus expectedReady bool expectedReason *string expectedMessage *string }{ "route accepted": { - httpRouteStatus: gatewayapiv1.HTTPRouteStatus{ - RouteStatus: gatewayapiv1.RouteStatus{ - Parents: []gatewayapiv1.RouteParentStatus{ + httpRouteStatus: gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ { Conditions: []metav1.Condition{ { - Type: string(gatewayapiv1.RouteConditionAccepted), + Type: string(gwapiv1.RouteConditionAccepted), Status: metav1.ConditionTrue, }, { - Type: string(gatewayapiv1.RouteConditionResolvedRefs), + Type: string(gwapiv1.RouteConditionResolvedRefs), Status: metav1.ConditionTrue, }, }, @@ -331,19 +325,19 @@ func TestIsHTTPRouteReady(t *testing.T) { expectedMessage: nil, }, "route not accepted": { - httpRouteStatus: gatewayapiv1.HTTPRouteStatus{ - RouteStatus: gatewayapiv1.RouteStatus{ - Parents: []gatewayapiv1.RouteParentStatus{ + httpRouteStatus: gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ { Conditions: []metav1.Condition{ { - Type: string(gatewayapiv1.RouteConditionAccepted), + Type: string(gwapiv1.RouteConditionAccepted), Status: metav1.ConditionFalse, Reason: "Route not accepted", Message: "Route not accepted", }, { - Type: string(gatewayapiv1.RouteConditionResolvedRefs), + Type: string(gwapiv1.RouteConditionResolvedRefs), Status: metav1.ConditionTrue, }, }, @@ -356,15 +350,100 @@ func TestIsHTTPRouteReady(t *testing.T) { expectedMessage: ptr.To("Route not accepted"), }, "no parent status": { - httpRouteStatus: gatewayapiv1.HTTPRouteStatus{ - RouteStatus: gatewayapiv1.RouteStatus{ - Parents: []gatewayapiv1.RouteParentStatus{}, + httpRouteStatus: gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{}, }, }, expectedReady: false, expectedReason: ptr.To(HTTPRouteParentStatusNotAvailable), expectedMessage: ptr.To(HTTPRouteNotReady), }, + "resolved refs not ready": { + httpRouteStatus: gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ + { + Conditions: []metav1.Condition{ + { + Type: string(gwapiv1.RouteConditionAccepted), + Status: metav1.ConditionTrue, + }, + { + Type: string(gwapiv1.RouteConditionResolvedRefs), + Status: metav1.ConditionFalse, + Reason: "BackendNotFound", + Message: "Backend service not found", + }, + }, + }, + }, + }, + }, + expectedReady: false, + expectedReason: ptr.To("BackendNotFound"), + expectedMessage: ptr.To("Backend service not found"), + }, + "multiple parents with one not ready": { + httpRouteStatus: gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ + { + Conditions: []metav1.Condition{ + { + Type: string(gwapiv1.RouteConditionAccepted), + Status: metav1.ConditionTrue, + }, + { + Type: string(gwapiv1.RouteConditionResolvedRefs), + Status: metav1.ConditionTrue, + }, + }, + }, + { + Conditions: []metav1.Condition{ + { + Type: string(gwapiv1.RouteConditionAccepted), + Status: metav1.ConditionFalse, + Reason: "GatewayNotFound", + Message: "Gateway not found", + }, + }, + }, + }, + }, + }, + expectedReady: false, + expectedReason: ptr.To("GatewayNotFound"), + expectedMessage: ptr.To("Gateway not found"), + }, + "both accepted and resolved refs false": { + httpRouteStatus: gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ + { + Conditions: []metav1.Condition{ + { + Type: string(gwapiv1.RouteConditionAccepted), + Status: metav1.ConditionFalse, + Reason: "NotAccepted", + Message: "Route not accepted", + }, + { + Type: string(gwapiv1.RouteConditionResolvedRefs), + Status: metav1.ConditionFalse, + Reason: "BackendNotFound", + Message: "Backend not found", + }, + }, + }, + }, + }, + }, + expectedReady: false, + expectedReason: ptr.To("NotAccepted"), + expectedMessage: ptr.To("Route not accepted"), + }, } for name, tc := range testCases { @@ -383,7 +462,7 @@ func TestCreateRawTopLevelHTTPRoute(t *testing.T) { testCases := map[string]struct { isvc *v1beta1.InferenceService ingressConfig *v1beta1.IngressConfig - expected *gatewayapiv1.HTTPRoute + expected *gwapiv1.HTTPRoute }{ "Predictor ready": { isvc: &v1beta1.InferenceService{ @@ -413,30 +492,30 @@ func TestCreateRawTopLevelHTTPRoute(t *testing.T) { AdditionalIngressDomains: &[]string{"additional.example.com"}, EnableGatewayAPI: true, }, - expected: &gatewayapiv1.HTTPRoute{ + expected: &gwapiv1.HTTPRoute{ ObjectMeta: metav1.ObjectMeta{ Name: "test-isvc", Namespace: "default", Annotations: map[string]string{}, Labels: map[string]string{}, }, - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{"test-isvc-default.example.com", "test-isvc-default.additional.example.com"}, - Rules: []gatewayapiv1.HTTPRouteRule{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{"test-isvc-default.example.com", "test-isvc-default.additional.example.com"}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To("^/.*$"), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: "test-isvc", @@ -449,30 +528,30 @@ func TestCreateRawTopLevelHTTPRoute(t *testing.T) { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), Name: "test-isvc-predictor", - Namespace: (*gatewayapiv1.Namespace)(ptr.To("default")), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + Namespace: (*gwapiv1.Namespace)(ptr.To("default")), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("60s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("60s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { Name: "kserve-gateway", - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace("kserve")), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace("kserve")), }, }, }, @@ -542,30 +621,30 @@ func TestCreateRawTopLevelHTTPRoute(t *testing.T) { AdditionalIngressDomains: &[]string{"additional.example.com"}, EnableGatewayAPI: true, }, - expected: &gatewayapiv1.HTTPRoute{ + expected: &gwapiv1.HTTPRoute{ ObjectMeta: metav1.ObjectMeta{ Name: "test-isvc", Namespace: "default", Annotations: map[string]string{}, Labels: map[string]string{}, }, - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{"test-isvc-default.example.com", "test-isvc-default.additional.example.com"}, - Rules: []gatewayapiv1.HTTPRouteRule{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{"test-isvc-default.example.com", "test-isvc-default.additional.example.com"}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To("^/.*$"), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: "test-isvc", @@ -578,30 +657,30 @@ func TestCreateRawTopLevelHTTPRoute(t *testing.T) { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), Name: "test-isvc-transformer", - Namespace: (*gatewayapiv1.Namespace)(ptr.To("default")), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + Namespace: (*gwapiv1.Namespace)(ptr.To("default")), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("60s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("60s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { Name: "kserve-gateway", - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace("kserve")), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace("kserve")), }, }, }, @@ -676,30 +755,30 @@ func TestCreateRawTopLevelHTTPRoute(t *testing.T) { AdditionalIngressDomains: &[]string{"additional.example.com"}, EnableGatewayAPI: true, }, - expected: &gatewayapiv1.HTTPRoute{ + expected: &gwapiv1.HTTPRoute{ ObjectMeta: metav1.ObjectMeta{ Name: "test-isvc", Namespace: "default", Annotations: map[string]string{}, Labels: map[string]string{}, }, - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{"test-isvc-default.example.com", "test-isvc-default.additional.example.com"}, - Rules: []gatewayapiv1.HTTPRouteRule{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{"test-isvc-default.example.com", "test-isvc-default.additional.example.com"}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(constants.ExplainPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: "test-isvc", @@ -712,36 +791,36 @@ func TestCreateRawTopLevelHTTPRoute(t *testing.T) { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), Name: "test-isvc-explainer", - Namespace: (*gatewayapiv1.Namespace)(ptr.To("default")), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + Namespace: (*gwapiv1.Namespace)(ptr.To("default")), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("60s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("60s")), }, }, { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To("^/.*$"), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: "test-isvc", @@ -754,30 +833,30 @@ func TestCreateRawTopLevelHTTPRoute(t *testing.T) { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), Name: "test-isvc-predictor", - Namespace: (*gatewayapiv1.Namespace)(ptr.To("default")), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + Namespace: (*gwapiv1.Namespace)(ptr.To("default")), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("60s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("60s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { Name: "kserve-gateway", - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace("kserve")), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace("kserve")), }, }, }, @@ -853,30 +932,30 @@ func TestCreateRawTopLevelHTTPRoute(t *testing.T) { PathTemplate: "/serving/{{ .Namespace }}/{{ .Name }}", EnableGatewayAPI: true, }, - expected: &gatewayapiv1.HTTPRoute{ + expected: &gwapiv1.HTTPRoute{ ObjectMeta: metav1.ObjectMeta{ Name: "test-isvc", Namespace: "default", Annotations: map[string]string{}, Labels: map[string]string{}, }, - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{"test-isvc-default.example.com", "test-isvc-default.additional.example.com", "example.com"}, - Rules: []gatewayapiv1.HTTPRouteRule{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{"test-isvc-default.example.com", "test-isvc-default.additional.example.com", "example.com"}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To(constants.ExplainPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: "test-isvc", @@ -889,36 +968,36 @@ func TestCreateRawTopLevelHTTPRoute(t *testing.T) { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), Name: "test-isvc-explainer", - Namespace: (*gatewayapiv1.Namespace)(ptr.To("default")), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + Namespace: (*gwapiv1.Namespace)(ptr.To("default")), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("60s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("60s")), }, }, { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To("^/.*$"), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: "test-isvc", @@ -931,36 +1010,36 @@ func TestCreateRawTopLevelHTTPRoute(t *testing.T) { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), Name: "test-isvc-predictor", - Namespace: (*gatewayapiv1.Namespace)(ptr.To("default")), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + Namespace: (*gwapiv1.Namespace)(ptr.To("default")), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("60s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("60s")), }, }, { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To("/serving/default/test-isvc" + constants.PathBasedExplainPrefix()), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: "test-isvc", @@ -973,36 +1052,36 @@ func TestCreateRawTopLevelHTTPRoute(t *testing.T) { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), Name: "test-isvc-explainer", - Namespace: (*gatewayapiv1.Namespace)(ptr.To("default")), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + Namespace: (*gwapiv1.Namespace)(ptr.To("default")), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("60s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("60s")), }, }, { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To("/serving/default/test-isvc/"), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: "test-isvc", @@ -1015,30 +1094,30 @@ func TestCreateRawTopLevelHTTPRoute(t *testing.T) { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), Name: "test-isvc-predictor", - Namespace: (*gatewayapiv1.Namespace)(ptr.To("default")), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + Namespace: (*gwapiv1.Namespace)(ptr.To("default")), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("60s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("60s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { Name: "kserve-gateway", - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace("kserve")), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace("kserve")), }, }, }, @@ -1079,30 +1158,30 @@ func TestCreateRawTopLevelHTTPRoute(t *testing.T) { PathTemplate: "/serving/{{ .Namespace }}/{{ .Name }}", EnableGatewayAPI: true, }, - expected: &gatewayapiv1.HTTPRoute{ + expected: &gwapiv1.HTTPRoute{ ObjectMeta: metav1.ObjectMeta{ Name: "test-isvc", Namespace: "default", Annotations: map[string]string{}, Labels: map[string]string{}, }, - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{"test-isvc-default.example.com", "test-isvc-default.additional.example.com", "example.com"}, - Rules: []gatewayapiv1.HTTPRouteRule{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{"test-isvc-default.example.com", "test-isvc-default.additional.example.com", "example.com"}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To("^/.*$"), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: "test-isvc", @@ -1115,36 +1194,36 @@ func TestCreateRawTopLevelHTTPRoute(t *testing.T) { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), Name: "test-isvc-transformer", - Namespace: (*gatewayapiv1.Namespace)(ptr.To("default")), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + Namespace: (*gwapiv1.Namespace)(ptr.To("default")), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("60s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("60s")), }, }, { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To("/serving/default/test-isvc/"), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: "test-isvc", @@ -1157,30 +1236,30 @@ func TestCreateRawTopLevelHTTPRoute(t *testing.T) { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), Name: "test-isvc-transformer", - Namespace: (*gatewayapiv1.Namespace)(ptr.To("default")), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + Namespace: (*gwapiv1.Namespace)(ptr.To("default")), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("60s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("60s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { Name: "kserve-gateway", - Kind: ptr.To(gatewayapiv1.Kind(constants.GatewayKind)), - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Namespace: ptr.To(gatewayapiv1.Namespace("kserve")), + Kind: ptr.To(gwapiv1.Kind(constants.GatewayKind)), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Namespace: ptr.To(gwapiv1.Namespace("kserve")), }, }, }, @@ -1193,8 +1272,8 @@ func TestCreateRawTopLevelHTTPRoute(t *testing.T) { t.Run(name, func(t *testing.T) { s := scheme.Scheme s.AddKnownTypes(v1beta1.SchemeGroupVersion, &v1beta1.InferenceService{}) - s.AddKnownTypes(schema.GroupVersion{Group: gatewayapiv1.GroupVersion.Group, Version: gatewayapiv1.GroupVersion.Version}, - &gatewayapiv1.HTTPRoute{}) + s.AddKnownTypes(schema.GroupVersion{Group: gwapiv1.GroupVersion.Group, Version: gwapiv1.GroupVersion.Version}, + &gwapiv1.HTTPRoute{}) client := fake.NewClientBuilder().WithScheme(s).Build() // Create a dummy service to test default suffix case client.Create(t.Context(), &corev1.Service{ @@ -1227,7 +1306,7 @@ func TestCreateRawPredictorHTTPRoute(t *testing.T) { testCases := map[string]struct { isvc *v1beta1.InferenceService ingressConfig *v1beta1.IngressConfig - expected *gatewayapiv1.HTTPRoute + expected *gwapiv1.HTTPRoute }{ "Predictor ready": { isvc: &v1beta1.InferenceService{ @@ -1256,30 +1335,30 @@ func TestCreateRawPredictorHTTPRoute(t *testing.T) { KserveIngressGateway: "kserve/kserve-gateway", EnableGatewayAPI: true, }, - expected: &gatewayapiv1.HTTPRoute{ + expected: &gwapiv1.HTTPRoute{ ObjectMeta: metav1.ObjectMeta{ Name: "test-isvc-predictor", Namespace: "default", Annotations: map[string]string{}, Labels: map[string]string{}, }, - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{"test-isvc-predictor-default.example.com"}, - Rules: []gatewayapiv1.HTTPRouteRule{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{"test-isvc-predictor-default.example.com"}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To("^/.*$"), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: "test-isvc", @@ -1292,30 +1371,30 @@ func TestCreateRawPredictorHTTPRoute(t *testing.T) { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), Name: "test-isvc-predictor", - Namespace: (*gatewayapiv1.Namespace)(ptr.To("default")), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + Namespace: (*gwapiv1.Namespace)(ptr.To("default")), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("60s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("60s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Kind: (*gatewayapiv1.Kind)(ptr.To(constants.GatewayKind)), - Namespace: (*gatewayapiv1.Namespace)(ptr.To("kserve")), - Name: gatewayapiv1.ObjectName("kserve-gateway"), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Kind: (*gwapiv1.Kind)(ptr.To(constants.GatewayKind)), + Namespace: (*gwapiv1.Namespace)(ptr.To("kserve")), + Name: gwapiv1.ObjectName("kserve-gateway"), }, }, }, @@ -1357,8 +1436,8 @@ func TestCreateRawPredictorHTTPRoute(t *testing.T) { t.Run(name, func(t *testing.T) { s := scheme.Scheme s.AddKnownTypes(v1beta1.SchemeGroupVersion, &v1beta1.InferenceService{}) - s.AddKnownTypes(schema.GroupVersion{Group: gatewayapiv1.GroupVersion.Group, Version: gatewayapiv1.GroupVersion.Version}, - &gatewayapiv1.HTTPRoute{}) + s.AddKnownTypes(schema.GroupVersion{Group: gwapiv1.GroupVersion.Group, Version: gwapiv1.GroupVersion.Version}, + &gwapiv1.HTTPRoute{}) client := fake.NewClientBuilder().WithScheme(s).Build() // Create a dummy service to test default suffix case client.Create(t.Context(), &corev1.Service{ @@ -1391,7 +1470,7 @@ func TestCreateRawTransformerHTTPRoute(t *testing.T) { testCases := map[string]struct { isvc *v1beta1.InferenceService ingressConfig *v1beta1.IngressConfig - expected *gatewayapiv1.HTTPRoute + expected *gwapiv1.HTTPRoute }{ "Transformer ready": { isvc: &v1beta1.InferenceService{ @@ -1421,30 +1500,30 @@ func TestCreateRawTransformerHTTPRoute(t *testing.T) { KserveIngressGateway: "kserve/kserve-gateway", EnableGatewayAPI: true, }, - expected: &gatewayapiv1.HTTPRoute{ + expected: &gwapiv1.HTTPRoute{ ObjectMeta: metav1.ObjectMeta{ Name: "test-isvc-transformer", Namespace: "default", Annotations: map[string]string{}, Labels: map[string]string{}, }, - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{"test-isvc-transformer-default.example.com"}, - Rules: []gatewayapiv1.HTTPRouteRule{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{"test-isvc-transformer-default.example.com"}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To("^/.*$"), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: "test-isvc", @@ -1457,30 +1536,30 @@ func TestCreateRawTransformerHTTPRoute(t *testing.T) { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), Name: "test-isvc-transformer", - Namespace: (*gatewayapiv1.Namespace)(ptr.To("default")), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + Namespace: (*gwapiv1.Namespace)(ptr.To("default")), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("60s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("60s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Kind: (*gatewayapiv1.Kind)(ptr.To(constants.GatewayKind)), - Namespace: (*gatewayapiv1.Namespace)(ptr.To("kserve")), - Name: gatewayapiv1.ObjectName("kserve-gateway"), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Kind: (*gwapiv1.Kind)(ptr.To(constants.GatewayKind)), + Namespace: (*gwapiv1.Namespace)(ptr.To("kserve")), + Name: gwapiv1.ObjectName("kserve-gateway"), }, }, }, @@ -1523,8 +1602,8 @@ func TestCreateRawTransformerHTTPRoute(t *testing.T) { t.Run(name, func(t *testing.T) { s := scheme.Scheme s.AddKnownTypes(v1beta1.SchemeGroupVersion, &v1beta1.InferenceService{}) - s.AddKnownTypes(schema.GroupVersion{Group: gatewayapiv1.GroupVersion.Group, Version: gatewayapiv1.GroupVersion.Version}, - &gatewayapiv1.HTTPRoute{}) + s.AddKnownTypes(schema.GroupVersion{Group: gwapiv1.GroupVersion.Group, Version: gwapiv1.GroupVersion.Version}, + &gwapiv1.HTTPRoute{}) client := fake.NewClientBuilder().WithScheme(s).Build() // Create a dummy service to test default suffix case client.Create(t.Context(), &corev1.Service{ @@ -1557,7 +1636,7 @@ func TestCreateRawExplainerHTTPRoute(t *testing.T) { testCases := map[string]struct { isvc *v1beta1.InferenceService ingressConfig *v1beta1.IngressConfig - expected *gatewayapiv1.HTTPRoute + expected *gwapiv1.HTTPRoute }{ "Explainer ready": { isvc: &v1beta1.InferenceService{ @@ -1587,30 +1666,30 @@ func TestCreateRawExplainerHTTPRoute(t *testing.T) { KserveIngressGateway: "kserve/kserve-gateway", EnableGatewayAPI: true, }, - expected: &gatewayapiv1.HTTPRoute{ + expected: &gwapiv1.HTTPRoute{ ObjectMeta: metav1.ObjectMeta{ Name: "test-isvc-explainer", Namespace: "default", Annotations: map[string]string{}, Labels: map[string]string{}, }, - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{"test-isvc-explainer-default.example.com"}, - Rules: []gatewayapiv1.HTTPRouteRule{ + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{"test-isvc-explainer-default.example.com"}, + Rules: []gwapiv1.HTTPRouteRule{ { - Matches: []gatewayapiv1.HTTPRouteMatch{ + Matches: []gwapiv1.HTTPRouteMatch{ { - Path: &gatewayapiv1.HTTPPathMatch{ - Type: ptr.To(gatewayapiv1.PathMatchRegularExpression), + Path: &gwapiv1.HTTPPathMatch{ + Type: ptr.To(gwapiv1.PathMatchRegularExpression), Value: ptr.To("^/.*$"), }, }, }, - Filters: []gatewayapiv1.HTTPRouteFilter{ + Filters: []gwapiv1.HTTPRouteFilter{ { - Type: gatewayapiv1.HTTPRouteFilterRequestHeaderModifier, - RequestHeaderModifier: &gatewayapiv1.HTTPHeaderFilter{ - Set: []gatewayapiv1.HTTPHeader{ + Type: gwapiv1.HTTPRouteFilterRequestHeaderModifier, + RequestHeaderModifier: &gwapiv1.HTTPHeaderFilter{ + Set: []gwapiv1.HTTPHeader{ { Name: constants.IsvcNameHeader, Value: "test-isvc", @@ -1623,30 +1702,30 @@ func TestCreateRawExplainerHTTPRoute(t *testing.T) { }, }, }, - BackendRefs: []gatewayapiv1.HTTPBackendRef{ + BackendRefs: []gwapiv1.HTTPBackendRef{ { - BackendRef: gatewayapiv1.BackendRef{ - BackendObjectReference: gatewayapiv1.BackendObjectReference{ - Kind: ptr.To(gatewayapiv1.Kind(constants.ServiceKind)), + BackendRef: gwapiv1.BackendRef{ + BackendObjectReference: gwapiv1.BackendObjectReference{ + Kind: ptr.To(gwapiv1.Kind(constants.ServiceKind)), Name: "test-isvc-explainer", - Namespace: (*gatewayapiv1.Namespace)(ptr.To("default")), - Port: (*gatewayapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), + Namespace: (*gwapiv1.Namespace)(ptr.To("default")), + Port: (*gwapiv1.PortNumber)(ptr.To(int32(constants.CommonDefaultHttpPort))), }, }, }, }, - Timeouts: &gatewayapiv1.HTTPRouteTimeouts{ - Request: ptr.To(gatewayapiv1.Duration("60s")), + Timeouts: &gwapiv1.HTTPRouteTimeouts{ + Request: ptr.To(gwapiv1.Duration("60s")), }, }, }, - CommonRouteSpec: gatewayapiv1.CommonRouteSpec{ - ParentRefs: []gatewayapiv1.ParentReference{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ { - Group: (*gatewayapiv1.Group)(&gatewayapiv1.GroupVersion.Group), - Kind: (*gatewayapiv1.Kind)(ptr.To(constants.GatewayKind)), - Namespace: (*gatewayapiv1.Namespace)(ptr.To("kserve")), - Name: gatewayapiv1.ObjectName("kserve-gateway"), + Group: (*gwapiv1.Group)(&gwapiv1.GroupVersion.Group), + Kind: (*gwapiv1.Kind)(ptr.To(constants.GatewayKind)), + Namespace: (*gwapiv1.Namespace)(ptr.To("kserve")), + Name: gwapiv1.ObjectName("kserve-gateway"), }, }, }, @@ -1689,8 +1768,8 @@ func TestCreateRawExplainerHTTPRoute(t *testing.T) { t.Run(name, func(t *testing.T) { s := scheme.Scheme s.AddKnownTypes(v1beta1.SchemeGroupVersion, &v1beta1.InferenceService{}) - s.AddKnownTypes(schema.GroupVersion{Group: gatewayapiv1.GroupVersion.Group, Version: gatewayapiv1.GroupVersion.Version}, - &gatewayapiv1.HTTPRoute{}) + s.AddKnownTypes(schema.GroupVersion{Group: gwapiv1.GroupVersion.Group, Version: gwapiv1.GroupVersion.Version}, + &gwapiv1.HTTPRoute{}) client := fake.NewClientBuilder().WithScheme(s).Build() // Create a dummy service to test default suffix case client.Create(t.Context(), &corev1.Service{ @@ -1721,7 +1800,7 @@ func TestRawHTTPRouteReconciler_reconcilePredictorHTTPRoute(t *testing.T) { g := NewGomegaWithT(t) s := scheme.Scheme _ = v1beta1.AddToScheme(s) - _ = gatewayapiv1.Install(s) + _ = gwapiv1.Install(s) _ = corev1.AddToScheme(s) ingressConfig := &v1beta1.IngressConfig{ @@ -1759,13 +1838,13 @@ func TestRawHTTPRouteReconciler_reconcilePredictorHTTPRoute(t *testing.T) { err := reconciler.reconcilePredictorHTTPRoute(t.Context(), isvc) g.Expect(err).ToNot(HaveOccurred()) - route := &gatewayapiv1.HTTPRoute{} + route := &gwapiv1.HTTPRoute{} err = client.Get(t.Context(), types.NamespacedName{ Name: "foo-predictor", Namespace: "default", }, route) g.Expect(err).ToNot(HaveOccurred()) - g.Expect(route.Spec.Hostnames).To(ContainElement(gatewayapiv1.Hostname("foo-predictor-default.example.com"))) + g.Expect(route.Spec.Hostnames).To(ContainElement(gwapiv1.Hostname("foo-predictor-default.example.com"))) }) t.Run("does nothing if desired is nil (PredictorReady false)", func(t *testing.T) { @@ -1792,7 +1871,7 @@ func TestRawHTTPRouteReconciler_reconcilePredictorHTTPRoute(t *testing.T) { err := reconciler.reconcilePredictorHTTPRoute(t.Context(), isvc) g.Expect(err).ToNot(HaveOccurred()) - route := &gatewayapiv1.HTTPRoute{} + route := &gwapiv1.HTTPRoute{} err = client.Get(t.Context(), types.NamespacedName{ Name: "foo-predictor", Namespace: "default", @@ -1818,13 +1897,13 @@ func TestRawHTTPRouteReconciler_reconcilePredictorHTTPRoute(t *testing.T) { }) // Create an existing HTTPRoute with a different hostname - existing := &gatewayapiv1.HTTPRoute{ + existing := &gwapiv1.HTTPRoute{ ObjectMeta: metav1.ObjectMeta{ Name: "foo-predictor", Namespace: "default", }, - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{"old-host.example.com"}, + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{"old-host.example.com"}, }, } _ = client.Create(t.Context(), existing) @@ -1839,13 +1918,13 @@ func TestRawHTTPRouteReconciler_reconcilePredictorHTTPRoute(t *testing.T) { err := reconciler.reconcilePredictorHTTPRoute(t.Context(), isvc) g.Expect(err).ToNot(HaveOccurred()) - route := &gatewayapiv1.HTTPRoute{} + route := &gwapiv1.HTTPRoute{} err = client.Get(t.Context(), types.NamespacedName{ Name: "foo-predictor", Namespace: "default", }, route) g.Expect(err).ToNot(HaveOccurred()) - g.Expect(route.Spec.Hostnames).To(ContainElement(gatewayapiv1.Hostname("foo-predictor-default.example.com"))) + g.Expect(route.Spec.Hostnames).To(ContainElement(gwapiv1.Hostname("foo-predictor-default.example.com"))) }) } @@ -1853,7 +1932,7 @@ func TestRawHTTPRouteReconciler_reconcileTransformerHTTPRoute(t *testing.T) { g := NewGomegaWithT(t) s := scheme.Scheme s.AddKnownTypes(v1beta1.SchemeGroupVersion, &v1beta1.InferenceService{}) - s.AddKnownTypes(schema.GroupVersion{Group: gatewayapiv1.GroupVersion.Group, Version: gatewayapiv1.GroupVersion.Version}, &gatewayapiv1.HTTPRoute{}) + s.AddKnownTypes(schema.GroupVersion{Group: gwapiv1.GroupVersion.Group, Version: gwapiv1.GroupVersion.Version}, &gwapiv1.HTTPRoute{}) s.AddKnownTypes(corev1.SchemeGroupVersion, &corev1.Service{}) ingressConfig := &v1beta1.IngressConfig{ @@ -1902,7 +1981,7 @@ func TestRawHTTPRouteReconciler_reconcileTransformerHTTPRoute(t *testing.T) { err := reconciler.reconcileTransformerHTTPRoute(t.Context(), isvc) g.Expect(err).ToNot(HaveOccurred()) - route := &gatewayapiv1.HTTPRoute{} + route := &gwapiv1.HTTPRoute{} err = client.Get(t.Context(), types.NamespacedName{ Name: "test-isvc-transformer", Namespace: "default", @@ -1940,13 +2019,13 @@ func TestRawHTTPRouteReconciler_reconcileTransformerHTTPRoute(t *testing.T) { }, }) // Create an existing HTTPRoute with different spec - existingRoute := &gatewayapiv1.HTTPRoute{ + existingRoute := &gwapiv1.HTTPRoute{ ObjectMeta: metav1.ObjectMeta{ Name: "test-isvc2-transformer", Namespace: "default", }, - Spec: gatewayapiv1.HTTPRouteSpec{ - Hostnames: []gatewayapiv1.Hostname{"oldhost.example.com"}, + Spec: gwapiv1.HTTPRouteSpec{ + Hostnames: []gwapiv1.Hostname{"oldhost.example.com"}, }, } client.Create(t.Context(), existingRoute) @@ -1960,13 +2039,13 @@ func TestRawHTTPRouteReconciler_reconcileTransformerHTTPRoute(t *testing.T) { err := reconciler.reconcileTransformerHTTPRoute(t.Context(), isvc) g.Expect(err).ToNot(HaveOccurred()) - route := &gatewayapiv1.HTTPRoute{} + route := &gwapiv1.HTTPRoute{} err = client.Get(t.Context(), types.NamespacedName{ Name: "test-isvc2-transformer", Namespace: "default", }, route) g.Expect(err).ToNot(HaveOccurred()) - g.Expect(route.Spec.Hostnames).To(ContainElement(gatewayapiv1.Hostname("test-isvc2-transformer-default.example.com"))) + g.Expect(route.Spec.Hostnames).To(ContainElement(gwapiv1.Hostname("test-isvc2-transformer-default.example.com"))) }) t.Run("does nothing if desired is nil", func(t *testing.T) { @@ -2006,7 +2085,7 @@ func TestRawHTTPRouteReconciler_reconcileExplainerHTTPRoute(t *testing.T) { g := NewGomegaWithT(t) s := scheme.Scheme s.AddKnownTypes(v1beta1.SchemeGroupVersion, &v1beta1.InferenceService{}) - s.AddKnownTypes(schema.GroupVersion{Group: gatewayapiv1.GroupVersion.Group, Version: gatewayapiv1.GroupVersion.Version}, &gatewayapiv1.HTTPRoute{}) + s.AddKnownTypes(schema.GroupVersion{Group: gwapiv1.GroupVersion.Group, Version: gwapiv1.GroupVersion.Version}, &gwapiv1.HTTPRoute{}) ctx := t.Context() ingressConfig := &v1beta1.IngressConfig{ @@ -2053,7 +2132,7 @@ func TestRawHTTPRouteReconciler_reconcileExplainerHTTPRoute(t *testing.T) { err := reconciler.reconcileExplainerHTTPRoute(ctx, isvc) g.Expect(err).ToNot(HaveOccurred()) - route := &gatewayapiv1.HTTPRoute{} + route := &gwapiv1.HTTPRoute{} err = client.Get(ctx, types.NamespacedName{Name: "foo-explainer", Namespace: "bar"}, route) g.Expect(err).ToNot(HaveOccurred()) g.Expect(route.Spec.Hostnames).ToNot(BeEmpty()) @@ -2084,7 +2163,7 @@ func TestRawHTTPRouteReconciler_reconcileExplainerHTTPRoute(t *testing.T) { err := reconciler.reconcileExplainerHTTPRoute(ctx, isvc) g.Expect(err).ToNot(HaveOccurred()) - route := &gatewayapiv1.HTTPRoute{} + route := &gwapiv1.HTTPRoute{} err = client.Get(ctx, types.NamespacedName{Name: "foo-explainer", Namespace: "bar"}, route) g.Expect(apierr.IsNotFound(err)).To(BeTrue()) }) @@ -2107,7 +2186,7 @@ func TestRawHTTPRouteReconciler_reconcileExplainerHTTPRoute(t *testing.T) { }) // Register HTTPRoute and corev1.Service types in the scheme for this test - s.AddKnownTypes(schema.GroupVersion{Group: gatewayapiv1.GroupVersion.Group, Version: gatewayapiv1.GroupVersion.Version}, &gatewayapiv1.HTTPRoute{}) + s.AddKnownTypes(schema.GroupVersion{Group: gwapiv1.GroupVersion.Group, Version: gwapiv1.GroupVersion.Version}, &gwapiv1.HTTPRoute{}) s.AddKnownTypes(corev1.SchemeGroupVersion, &corev1.Service{}) client := fake.NewClientBuilder().WithScheme(s). @@ -2128,7 +2207,7 @@ func TestRawHTTPRouteReconciler_reconcileExplainerHTTPRoute(t *testing.T) { err := reconciler.reconcileExplainerHTTPRoute(ctx, isvc) g.Expect(err).ToNot(HaveOccurred()) - route := &gatewayapiv1.HTTPRoute{} + route := &gwapiv1.HTTPRoute{} _ = client.Get(ctx, types.NamespacedName{Name: "foo-explainer-default", Namespace: "bar"}, route) }) } @@ -2136,7 +2215,7 @@ func TestRawHTTPRouteReconciler_reconcileExplainerHTTPRoute(t *testing.T) { func TestRawHTTPRouteReconciler_reconcileTopLevelHTTPRoute(t *testing.T) { g := NewGomegaWithT(t) s := scheme.Scheme - _ = gatewayapiv1.Install(s) + _ = gwapiv1.Install(s) _ = v1beta1.AddToScheme(s) ingressConfig := &v1beta1.IngressConfig{ @@ -2182,13 +2261,13 @@ func TestRawHTTPRouteReconciler_reconcileTopLevelHTTPRoute(t *testing.T) { err := reconciler.reconcileTopLevelHTTPRoute(t.Context(), isvc) g.Expect(err).ToNot(HaveOccurred()) - route := &gatewayapiv1.HTTPRoute{} + route := &gwapiv1.HTTPRoute{} err = client.Get(t.Context(), types.NamespacedName{ Name: "test-isvc", Namespace: "default", }, route) g.Expect(err).ToNot(HaveOccurred()) - g.Expect(route.Spec.Hostnames).To(ContainElement(gatewayapiv1.Hostname("test-isvc-default.example.com"))) + g.Expect(route.Spec.Hostnames).To(ContainElement(gwapiv1.Hostname("test-isvc-default.example.com"))) }) t.Run("creates top-level HTTPRoute for predictor+transformer+explainer", func(t *testing.T) { @@ -2248,13 +2327,13 @@ func TestRawHTTPRouteReconciler_reconcileTopLevelHTTPRoute(t *testing.T) { err := reconciler.reconcileTopLevelHTTPRoute(t.Context(), isvc) g.Expect(err).ToNot(HaveOccurred()) - route := &gatewayapiv1.HTTPRoute{} + route := &gwapiv1.HTTPRoute{} err = client.Get(t.Context(), types.NamespacedName{ Name: "test-isvc2", Namespace: "default", }, route) g.Expect(err).ToNot(HaveOccurred()) - g.Expect(route.Spec.Hostnames).To(ContainElement(gatewayapiv1.Hostname("test-isvc2-default.example.com"))) + g.Expect(route.Spec.Hostnames).To(ContainElement(gwapiv1.Hostname("test-isvc2-default.example.com"))) g.Expect(route.Spec.Rules).ToNot(BeEmpty()) }) @@ -2279,7 +2358,7 @@ func TestRawHTTPRouteReconciler_reconcileTopLevelHTTPRoute(t *testing.T) { err := reconciler.reconcileTopLevelHTTPRoute(t.Context(), isvc) g.Expect(err).ToNot(HaveOccurred()) - route := &gatewayapiv1.HTTPRoute{} + route := &gwapiv1.HTTPRoute{} err = client.Get(t.Context(), types.NamespacedName{ Name: "test-isvc3", Namespace: "default", @@ -2306,27 +2385,27 @@ func TestRawHTTPRouteReconciler_Reconcile(t *testing.T) { // Setup scheme and fake client s := scheme.Scheme s.AddKnownTypes(v1beta1.SchemeGroupVersion, &v1beta1.InferenceService{}) - s.AddKnownTypes(schema.GroupVersion{Group: gatewayapiv1.GroupVersion.Group, Version: gatewayapiv1.GroupVersion.Version}, &gatewayapiv1.HTTPRoute{}) + s.AddKnownTypes(schema.GroupVersion{Group: gwapiv1.GroupVersion.Group, Version: gwapiv1.GroupVersion.Version}, &gwapiv1.HTTPRoute{}) s.AddKnownTypes(corev1.SchemeGroupVersion, &corev1.Service{}) // Helper to create a ready HTTPRoute status - readyHTTPRoute := func(name, namespace string) *gatewayapiv1.HTTPRoute { - return &gatewayapiv1.HTTPRoute{ + readyHTTPRoute := func(name, namespace string) *gwapiv1.HTTPRoute { + return &gwapiv1.HTTPRoute{ ObjectMeta: metav1.ObjectMeta{ Name: name, Namespace: namespace, }, - Status: gatewayapiv1.HTTPRouteStatus{ - RouteStatus: gatewayapiv1.RouteStatus{ - Parents: []gatewayapiv1.RouteParentStatus{ + Status: gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ { Conditions: []metav1.Condition{ { - Type: string(gatewayapiv1.RouteConditionAccepted), + Type: string(gwapiv1.RouteConditionAccepted), Status: metav1.ConditionTrue, }, { - Type: string(gatewayapiv1.RouteConditionResolvedRefs), + Type: string(gwapiv1.RouteConditionResolvedRefs), Status: metav1.ConditionTrue, }, }, @@ -2353,8 +2432,9 @@ func TestRawHTTPRouteReconciler_Reconcile(t *testing.T) { } client := fake.NewClientBuilder().WithScheme(s).Build() reconciler := NewRawHTTPRouteReconciler(client, s, ingressConfig, isvcConfig) - err := reconciler.Reconcile(t.Context(), isvc) + result, err := reconciler.Reconcile(t.Context(), isvc) g.Expect(err).ToNot(HaveOccurred()) + g.Expect(result).To(Equal(ctrl.Result{})) cond := isvc.Status.GetCondition(v1beta1.IngressReady) g.Expect(cond).NotTo(BeNil()) g.Expect(cond.Status).To(Equal(corev1.ConditionTrue)) @@ -2375,14 +2455,15 @@ func TestRawHTTPRouteReconciler_Reconcile(t *testing.T) { clusterLocalConfig.IngressDomain = constants.ClusterLocalDomain client := fake.NewClientBuilder().WithScheme(s).Build() reconciler := NewRawHTTPRouteReconciler(client, s, &clusterLocalConfig, isvcConfig) - err := reconciler.Reconcile(t.Context(), isvc) + result, err := reconciler.Reconcile(t.Context(), isvc) g.Expect(err).ToNot(HaveOccurred()) + g.Expect(result).To(Equal(ctrl.Result{})) cond := isvc.Status.GetCondition(v1beta1.IngressReady) g.Expect(cond).NotTo(BeNil()) g.Expect(cond.Status).To(Equal(corev1.ConditionTrue)) }) - t.Run("Reconcile returns error if HTTPRoute not found", func(t *testing.T) { + t.Run("Reconcile returns requeue if HTTPRoute not found", func(t *testing.T) { isvc := &v1beta1.InferenceService{ ObjectMeta: metav1.ObjectMeta{ Name: "test-isvc", @@ -2399,8 +2480,15 @@ func TestRawHTTPRouteReconciler_Reconcile(t *testing.T) { }) client := fake.NewClientBuilder().WithScheme(s).Build() reconciler := NewRawHTTPRouteReconciler(client, s, ingressConfig, isvcConfig) - err := reconciler.Reconcile(t.Context(), isvc) + result, err := reconciler.Reconcile(t.Context(), isvc) g.Expect(err).ToNot(HaveOccurred()) + g.Expect(result.Requeue).To(BeTrue()) + cond := isvc.Status.GetCondition(v1beta1.IngressReady) + g.Expect(cond).NotTo(BeNil()) + g.Expect(cond.Status).To(Equal(corev1.ConditionFalse)) + // When HTTPRoutes are newly created, they have empty status which leads to ParentStatusNotAvailable + g.Expect(cond.Reason).To(Equal("ParentStatusNotAvailable")) + g.Expect(cond.Message).To(Equal("Predictor HttpRouteNotReady")) }) t.Run("Reconcile sets IngressReady to False if HTTPRoute not ready", func(t *testing.T) { @@ -2418,18 +2506,18 @@ func TestRawHTTPRouteReconciler_Reconcile(t *testing.T) { Type: v1beta1.PredictorReady, Status: corev1.ConditionTrue, }) - notReadyHTTPRoute := &gatewayapiv1.HTTPRoute{ + notReadyHTTPRoute := &gwapiv1.HTTPRoute{ ObjectMeta: metav1.ObjectMeta{ Name: constants.PredictorServiceName(isvc.Name), Namespace: isvc.Namespace, }, - Status: gatewayapiv1.HTTPRouteStatus{ - RouteStatus: gatewayapiv1.RouteStatus{ - Parents: []gatewayapiv1.RouteParentStatus{ + Status: gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ { Conditions: []metav1.Condition{ { - Type: string(gatewayapiv1.RouteConditionAccepted), + Type: string(gwapiv1.RouteConditionAccepted), Status: metav1.ConditionFalse, Reason: "NotAccepted", Message: "Route not accepted", @@ -2454,11 +2542,13 @@ func TestRawHTTPRouteReconciler_Reconcile(t *testing.T) { ). Build() reconciler := NewRawHTTPRouteReconciler(client, s, ingressConfig, isvcConfig) - err := reconciler.Reconcile(t.Context(), isvc) + result, err := reconciler.Reconcile(t.Context(), isvc) g.Expect(err).ToNot(HaveOccurred()) + g.Expect(result.Requeue).To(BeTrue()) cond := isvc.Status.GetCondition(v1beta1.IngressReady) g.Expect(cond).NotTo(BeNil()) g.Expect(cond.Status).To(Equal(corev1.ConditionFalse)) + g.Expect(cond.Reason).To(Equal("ParentStatusNotAvailable")) g.Expect(cond.Message).To(ContainSubstring("Predictor")) }) @@ -2517,9 +2607,653 @@ func TestRawHTTPRouteReconciler_Reconcile(t *testing.T) { Build() reconciler := NewRawHTTPRouteReconciler(client, s, ingressConfig, isvcConfig) - err := reconciler.Reconcile(t.Context(), isvc) + result, err := reconciler.Reconcile(t.Context(), isvc) g.Expect(err).ToNot(HaveOccurred()) + // HTTPRoutes get updated by reconciler which resets their status, causing requeue + g.Expect(result.Requeue).To(BeTrue()) cond := isvc.Status.GetCondition(v1beta1.IngressReady) g.Expect(cond).NotTo(BeNil()) + g.Expect(cond.Status).To(Equal(corev1.ConditionFalse)) + }) + + t.Run("Reconcile requeues when HTTPRoute not found", func(t *testing.T) { + isvc := &v1beta1.InferenceService{ + ObjectMeta: metav1.ObjectMeta{ + Name: "test-isvc-requeue", + Namespace: "default", + }, + Spec: v1beta1.InferenceServiceSpec{ + Predictor: v1beta1.PredictorSpec{}, + }, + Status: v1beta1.InferenceServiceStatus{}, + } + isvc.Status.SetCondition(v1beta1.PredictorReady, &apis.Condition{ + Type: v1beta1.PredictorReady, + Status: corev1.ConditionTrue, + }) + + // Create client without HTTPRoute objects - HTTPRoutes get created during reconciliation but have empty status + client := fake.NewClientBuilder().WithScheme(s).Build() + reconciler := NewRawHTTPRouteReconciler(client, s, ingressConfig, isvcConfig) + result, err := reconciler.Reconcile(t.Context(), isvc) + g.Expect(err).ToNot(HaveOccurred()) + g.Expect(result.Requeue).To(BeTrue()) + cond := isvc.Status.GetCondition(v1beta1.IngressReady) + g.Expect(cond).NotTo(BeNil()) + g.Expect(cond.Status).To(Equal(corev1.ConditionFalse)) + // HTTPRoutes are created during reconciliation but have empty status, leading to ParentStatusNotAvailable + g.Expect(cond.Reason).To(Equal("ParentStatusNotAvailable")) + g.Expect(cond.Message).To(ContainSubstring("HttpRouteNotReady")) + }) + + t.Run("Reconcile requeues when HTTPRoute not ready", func(t *testing.T) { + isvc := &v1beta1.InferenceService{ + ObjectMeta: metav1.ObjectMeta{ + Name: "test-isvc-not-ready", + Namespace: "default", + }, + Spec: v1beta1.InferenceServiceSpec{ + Predictor: v1beta1.PredictorSpec{}, + }, + Status: v1beta1.InferenceServiceStatus{}, + } + isvc.Status.SetCondition(v1beta1.PredictorReady, &apis.Condition{ + Type: v1beta1.PredictorReady, + Status: corev1.ConditionTrue, + }) + + // Create HTTPRoute with not ready status - needs to have the correct spec to avoid being updated + desiredPredictorRoute, err := createRawPredictorHTTPRoute(isvc, ingressConfig, isvcConfig) + g.Expect(err).ToNot(HaveOccurred()) + g.Expect(desiredPredictorRoute).NotTo(BeNil()) + + notReadyHTTPRoute := desiredPredictorRoute.DeepCopy() + // Set controller reference to match what the reconciler will set + err = controllerutil.SetControllerReference(isvc, notReadyHTTPRoute, s) + g.Expect(err).ToNot(HaveOccurred()) + notReadyHTTPRoute.Status = gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ + { + Conditions: []metav1.Condition{ + { + Type: string(gwapiv1.RouteConditionAccepted), + Status: metav1.ConditionFalse, + Reason: "NotAccepted", + Message: "Route not accepted by gateway", + }, + }, + }, + }, + }, + } + + client := fake.NewClientBuilder(). + WithScheme(s). + WithObjects( + notReadyHTTPRoute, + readyHTTPRoute(isvc.Name, isvc.Namespace), // Top-level route is ready + ). + Build() + + reconciler := NewRawHTTPRouteReconciler(client, s, ingressConfig, isvcConfig) + result, err := reconciler.Reconcile(t.Context(), isvc) + g.Expect(err).ToNot(HaveOccurred()) + g.Expect(result.Requeue).To(BeTrue()) + cond := isvc.Status.GetCondition(v1beta1.IngressReady) + g.Expect(cond).NotTo(BeNil()) + g.Expect(cond.Status).To(Equal(corev1.ConditionFalse)) + g.Expect(cond.Reason).To(Equal("NotAccepted")) + g.Expect(cond.Message).To(ContainSubstring("Predictor")) + }) + + t.Run("Reconcile requeues when transformer HTTPRoute not ready", func(t *testing.T) { + isvc := &v1beta1.InferenceService{ + ObjectMeta: metav1.ObjectMeta{ + Name: "test-isvc-transformer", + Namespace: "default", + }, + Spec: v1beta1.InferenceServiceSpec{ + Predictor: v1beta1.PredictorSpec{}, + Transformer: &v1beta1.TransformerSpec{}, + }, + Status: v1beta1.InferenceServiceStatus{}, + } + isvc.Status.SetCondition(v1beta1.PredictorReady, &apis.Condition{ + Type: v1beta1.PredictorReady, + Status: corev1.ConditionTrue, + }) + isvc.Status.SetCondition(v1beta1.TransformerReady, &apis.Condition{ + Type: v1beta1.TransformerReady, + Status: corev1.ConditionTrue, + }) + + // Create ready predictor HTTPRoute but not ready transformer HTTPRoute + desiredPredictorRoute, err := createRawPredictorHTTPRoute(isvc, ingressConfig, isvcConfig) + g.Expect(err).ToNot(HaveOccurred()) + g.Expect(desiredPredictorRoute).NotTo(BeNil()) + + readyPredictorHTTPRoute := desiredPredictorRoute.DeepCopy() + // Set controller reference to match what the reconciler will set + err = controllerutil.SetControllerReference(isvc, readyPredictorHTTPRoute, s) + g.Expect(err).ToNot(HaveOccurred()) + readyPredictorHTTPRoute.Status = gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ + { + Conditions: []metav1.Condition{ + { + Type: string(gwapiv1.RouteConditionAccepted), + Status: metav1.ConditionTrue, + }, + { + Type: string(gwapiv1.RouteConditionResolvedRefs), + Status: metav1.ConditionTrue, + }, + }, + }, + }, + }, + } + + desiredTransformerRoute, err := createRawTransformerHTTPRoute(isvc, ingressConfig, isvcConfig) + g.Expect(err).ToNot(HaveOccurred()) + g.Expect(desiredTransformerRoute).NotTo(BeNil()) + + notReadyTransformerHTTPRoute := desiredTransformerRoute.DeepCopy() + // Set controller reference to match what the reconciler will set + err = controllerutil.SetControllerReference(isvc, notReadyTransformerHTTPRoute, s) + g.Expect(err).ToNot(HaveOccurred()) + + // Create a temporary client to perform dry-run update on the test HTTPRoute + // This ensures it has the same defaults as what the reconciler will apply + tempClient := fake.NewClientBuilder().WithScheme(s).Build() + err = tempClient.Create(t.Context(), notReadyTransformerHTTPRoute) + g.Expect(err).ToNot(HaveOccurred()) + + // Perform the same dry-run update that the reconciler will do + err = tempClient.Update(t.Context(), notReadyTransformerHTTPRoute, client.DryRunAll) + g.Expect(err).ToNot(HaveOccurred()) + + notReadyTransformerHTTPRoute.Status = gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ + { + Conditions: []metav1.Condition{ + { + Type: string(gwapiv1.RouteConditionResolvedRefs), + Status: metav1.ConditionFalse, + Reason: "BackendNotFound", + Message: "Backend service not found", + }, + }, + }, + }, + }, + } + + // Create ready top-level HTTPRoute + desiredTopLevelRoute, err := createRawTopLevelHTTPRoute(isvc, ingressConfig, isvcConfig) + g.Expect(err).ToNot(HaveOccurred()) + g.Expect(desiredTopLevelRoute).NotTo(BeNil()) + + readyTopLevelHTTPRoute := desiredTopLevelRoute.DeepCopy() + // Set controller reference to match what the reconciler will set + err = controllerutil.SetControllerReference(isvc, readyTopLevelHTTPRoute, s) + g.Expect(err).ToNot(HaveOccurred()) + readyTopLevelHTTPRoute.Status = gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ + { + Conditions: []metav1.Condition{ + { + Type: string(gwapiv1.RouteConditionAccepted), + Status: metav1.ConditionTrue, + }, + { + Type: string(gwapiv1.RouteConditionResolvedRefs), + Status: metav1.ConditionTrue, + }, + }, + }, + }, + }, + } + + client := fake.NewClientBuilder(). + WithScheme(s). + WithObjects( + readyPredictorHTTPRoute, + notReadyTransformerHTTPRoute, + readyTopLevelHTTPRoute, + ). + Build() + + reconciler := NewRawHTTPRouteReconciler(client, s, ingressConfig, isvcConfig) + result, err := reconciler.Reconcile(t.Context(), isvc) + g.Expect(err).ToNot(HaveOccurred()) + g.Expect(result.Requeue).To(BeTrue()) + cond := isvc.Status.GetCondition(v1beta1.IngressReady) + g.Expect(cond).NotTo(BeNil()) + g.Expect(cond.Status).To(Equal(corev1.ConditionFalse)) + g.Expect(cond.Reason).To(Equal("BackendNotFound")) + g.Expect(cond.Message).To(ContainSubstring("Transformer")) + }) + + t.Run("Reconcile requeues when explainer HTTPRoute not ready", func(t *testing.T) { + isvc := &v1beta1.InferenceService{ + ObjectMeta: metav1.ObjectMeta{ + Name: "test-isvc-explainer", + Namespace: "default", + }, + Spec: v1beta1.InferenceServiceSpec{ + Predictor: v1beta1.PredictorSpec{}, + Explainer: &v1beta1.ExplainerSpec{}, + }, + Status: v1beta1.InferenceServiceStatus{}, + } + isvc.Status.SetCondition(v1beta1.PredictorReady, &apis.Condition{ + Type: v1beta1.PredictorReady, + Status: corev1.ConditionTrue, + }) + isvc.Status.SetCondition(v1beta1.ExplainerReady, &apis.Condition{ + Type: v1beta1.ExplainerReady, + Status: corev1.ConditionTrue, + }) + + // Create ready predictor HTTPRoute but not ready explainer HTTPRoute + desiredPredictorRoute, err := createRawPredictorHTTPRoute(isvc, ingressConfig, isvcConfig) + g.Expect(err).ToNot(HaveOccurred()) + g.Expect(desiredPredictorRoute).NotTo(BeNil()) + + readyPredictorHTTPRoute := desiredPredictorRoute.DeepCopy() + // Set controller reference to match what the reconciler will set + err = controllerutil.SetControllerReference(isvc, readyPredictorHTTPRoute, s) + g.Expect(err).ToNot(HaveOccurred()) + readyPredictorHTTPRoute.Status = gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ + { + Conditions: []metav1.Condition{ + { + Type: string(gwapiv1.RouteConditionAccepted), + Status: metav1.ConditionTrue, + }, + { + Type: string(gwapiv1.RouteConditionResolvedRefs), + Status: metav1.ConditionTrue, + }, + }, + }, + }, + }, + } + + desiredExplainerRoute, err := createRawExplainerHTTPRoute(isvc, ingressConfig, isvcConfig) + g.Expect(err).ToNot(HaveOccurred()) + g.Expect(desiredExplainerRoute).NotTo(BeNil()) + + notReadyExplainerHTTPRoute := desiredExplainerRoute.DeepCopy() + // Set controller reference to match what the reconciler will set + err = controllerutil.SetControllerReference(isvc, notReadyExplainerHTTPRoute, s) + g.Expect(err).ToNot(HaveOccurred()) + notReadyExplainerHTTPRoute.Status = gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ + { + Conditions: []metav1.Condition{ + { + Type: string(gwapiv1.RouteConditionAccepted), + Status: metav1.ConditionFalse, + Reason: "UnsupportedProtocol", + Message: "Protocol not supported", + }, + }, + }, + }, + }, + } + + desiredTopLevelRoute, err := createRawTopLevelHTTPRoute(isvc, ingressConfig, isvcConfig) + g.Expect(err).ToNot(HaveOccurred()) + g.Expect(desiredTopLevelRoute).NotTo(BeNil()) + + readyTopLevelHTTPRoute := desiredTopLevelRoute.DeepCopy() + // Set controller reference to match what the reconciler will set + err = controllerutil.SetControllerReference(isvc, readyTopLevelHTTPRoute, s) + g.Expect(err).ToNot(HaveOccurred()) + readyTopLevelHTTPRoute.Status = gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ + { + Conditions: []metav1.Condition{ + { + Type: string(gwapiv1.RouteConditionAccepted), + Status: metav1.ConditionTrue, + }, + { + Type: string(gwapiv1.RouteConditionResolvedRefs), + Status: metav1.ConditionTrue, + }, + }, + }, + }, + }, + } + + client := fake.NewClientBuilder(). + WithScheme(s). + WithObjects( + readyPredictorHTTPRoute, + notReadyExplainerHTTPRoute, + readyTopLevelHTTPRoute, + ). + Build() + + reconciler := NewRawHTTPRouteReconciler(client, s, ingressConfig, isvcConfig) + result, err := reconciler.Reconcile(t.Context(), isvc) + g.Expect(err).ToNot(HaveOccurred()) + g.Expect(result.Requeue).To(BeTrue()) + cond := isvc.Status.GetCondition(v1beta1.IngressReady) + g.Expect(cond).NotTo(BeNil()) + g.Expect(cond.Status).To(Equal(corev1.ConditionFalse)) + g.Expect(cond.Reason).To(Equal("UnsupportedProtocol")) + g.Expect(cond.Message).To(ContainSubstring("Explainer")) + }) + + t.Run("Reconcile requeues when top-level HTTPRoute not ready", func(t *testing.T) { + isvc := &v1beta1.InferenceService{ + ObjectMeta: metav1.ObjectMeta{ + Name: "test-isvc-toplevel", + Namespace: "default", + }, + Spec: v1beta1.InferenceServiceSpec{ + Predictor: v1beta1.PredictorSpec{}, + }, + Status: v1beta1.InferenceServiceStatus{}, + } + isvc.Status.SetCondition(v1beta1.PredictorReady, &apis.Condition{ + Type: v1beta1.PredictorReady, + Status: corev1.ConditionTrue, + }) + + // Create ready predictor HTTPRoute but not ready top-level HTTPRoute + desiredTopLevelRoute, err := createRawTopLevelHTTPRoute(isvc, ingressConfig, isvcConfig) + g.Expect(err).ToNot(HaveOccurred()) + g.Expect(desiredTopLevelRoute).NotTo(BeNil()) + + notReadyTopLevelHTTPRoute := desiredTopLevelRoute.DeepCopy() + // Set controller reference to match what the reconciler will set + err = controllerutil.SetControllerReference(isvc, notReadyTopLevelHTTPRoute, s) + g.Expect(err).ToNot(HaveOccurred()) + notReadyTopLevelHTTPRoute.Status = gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ + { + Conditions: []metav1.Condition{ + { + Type: string(gwapiv1.RouteConditionAccepted), + Status: metav1.ConditionTrue, + }, + { + Type: string(gwapiv1.RouteConditionResolvedRefs), + Status: metav1.ConditionFalse, + Reason: "InvalidKind", + Message: "Invalid backend kind", + }, + }, + }, + }, + }, + } + + desiredPredictorRoute, err := createRawPredictorHTTPRoute(isvc, ingressConfig, isvcConfig) + g.Expect(err).ToNot(HaveOccurred()) + g.Expect(desiredPredictorRoute).NotTo(BeNil()) + + readyPredictorHTTPRoute := desiredPredictorRoute.DeepCopy() + // Set controller reference to match what the reconciler will set + err = controllerutil.SetControllerReference(isvc, readyPredictorHTTPRoute, s) + g.Expect(err).ToNot(HaveOccurred()) + readyPredictorHTTPRoute.Status = gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ + { + Conditions: []metav1.Condition{ + { + Type: string(gwapiv1.RouteConditionAccepted), + Status: metav1.ConditionTrue, + }, + { + Type: string(gwapiv1.RouteConditionResolvedRefs), + Status: metav1.ConditionTrue, + }, + }, + }, + }, + }, + } + + client := fake.NewClientBuilder(). + WithScheme(s). + WithObjects( + readyPredictorHTTPRoute, + notReadyTopLevelHTTPRoute, + ). + Build() + + reconciler := NewRawHTTPRouteReconciler(client, s, ingressConfig, isvcConfig) + result, err := reconciler.Reconcile(t.Context(), isvc) + g.Expect(err).ToNot(HaveOccurred()) + g.Expect(result.Requeue).To(BeTrue()) + cond := isvc.Status.GetCondition(v1beta1.IngressReady) + g.Expect(cond).NotTo(BeNil()) + g.Expect(cond.Status).To(Equal(corev1.ConditionFalse)) + g.Expect(cond.Reason).To(Equal("InvalidKind")) + g.Expect(cond.Message).To(ContainSubstring("InferenceService")) + }) + + t.Run("Reconcile does not requeue when all HTTPRoutes are ready", func(t *testing.T) { + isvc := &v1beta1.InferenceService{ + ObjectMeta: metav1.ObjectMeta{ + Name: "test-isvc-all-ready", + Namespace: "default", + }, + Spec: v1beta1.InferenceServiceSpec{ + Predictor: v1beta1.PredictorSpec{}, + Transformer: &v1beta1.TransformerSpec{}, + Explainer: &v1beta1.ExplainerSpec{}, + }, + Status: v1beta1.InferenceServiceStatus{}, + } + isvc.Status.SetCondition(v1beta1.PredictorReady, &apis.Condition{ + Type: v1beta1.PredictorReady, + Status: corev1.ConditionTrue, + }) + isvc.Status.SetCondition(v1beta1.TransformerReady, &apis.Condition{ + Type: v1beta1.TransformerReady, + Status: corev1.ConditionTrue, + }) + isvc.Status.SetCondition(v1beta1.ExplainerReady, &apis.Condition{ + Type: v1beta1.ExplainerReady, + Status: corev1.ConditionTrue, + }) + + desiredPredictorRoute, err := createRawPredictorHTTPRoute(isvc, ingressConfig, isvcConfig) + g.Expect(err).ToNot(HaveOccurred()) + g.Expect(desiredPredictorRoute).NotTo(BeNil()) + + readyPredictorHTTPRoute := desiredPredictorRoute.DeepCopy() + err = controllerutil.SetControllerReference(isvc, readyPredictorHTTPRoute, s) + g.Expect(err).ToNot(HaveOccurred()) + readyPredictorHTTPRoute.Status = gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ + { + Conditions: []metav1.Condition{ + { + Type: string(gwapiv1.RouteConditionAccepted), + Status: metav1.ConditionTrue, + }, + { + Type: string(gwapiv1.RouteConditionResolvedRefs), + Status: metav1.ConditionTrue, + }, + }, + }, + }, + }, + } + + desiredTransformerRoute, err := createRawTransformerHTTPRoute(isvc, ingressConfig, isvcConfig) + g.Expect(err).ToNot(HaveOccurred()) + g.Expect(desiredTransformerRoute).NotTo(BeNil()) + + readyTransformerHTTPRoute := desiredTransformerRoute.DeepCopy() + err = controllerutil.SetControllerReference(isvc, readyTransformerHTTPRoute, s) + g.Expect(err).ToNot(HaveOccurred()) + readyTransformerHTTPRoute.Status = gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ + { + Conditions: []metav1.Condition{ + { + Type: string(gwapiv1.RouteConditionAccepted), + Status: metav1.ConditionTrue, + }, + { + Type: string(gwapiv1.RouteConditionResolvedRefs), + Status: metav1.ConditionTrue, + }, + }, + }, + }, + }, + } + + desiredExplainerRoute, err := createRawExplainerHTTPRoute(isvc, ingressConfig, isvcConfig) + g.Expect(err).ToNot(HaveOccurred()) + g.Expect(desiredExplainerRoute).NotTo(BeNil()) + + readyExplainerHTTPRoute := desiredExplainerRoute.DeepCopy() + err = controllerutil.SetControllerReference(isvc, readyExplainerHTTPRoute, s) + g.Expect(err).ToNot(HaveOccurred()) + readyExplainerHTTPRoute.Status = gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ + { + Conditions: []metav1.Condition{ + { + Type: string(gwapiv1.RouteConditionAccepted), + Status: metav1.ConditionTrue, + }, + { + Type: string(gwapiv1.RouteConditionResolvedRefs), + Status: metav1.ConditionTrue, + }, + }, + }, + }, + }, + } + + desiredTopLevelRoute, err := createRawTopLevelHTTPRoute(isvc, ingressConfig, isvcConfig) + g.Expect(err).ToNot(HaveOccurred()) + g.Expect(desiredTopLevelRoute).NotTo(BeNil()) + + readyTopLevelHTTPRoute := desiredTopLevelRoute.DeepCopy() + err = controllerutil.SetControllerReference(isvc, readyTopLevelHTTPRoute, s) + g.Expect(err).ToNot(HaveOccurred()) + readyTopLevelHTTPRoute.Status = gwapiv1.HTTPRouteStatus{ + RouteStatus: gwapiv1.RouteStatus{ + Parents: []gwapiv1.RouteParentStatus{ + { + Conditions: []metav1.Condition{ + { + Type: string(gwapiv1.RouteConditionAccepted), + Status: metav1.ConditionTrue, + }, + { + Type: string(gwapiv1.RouteConditionResolvedRefs), + Status: metav1.ConditionTrue, + }, + }, + }, + }, + }, + } + + client := fake.NewClientBuilder(). + WithScheme(s). + WithObjects( + readyPredictorHTTPRoute, + readyTransformerHTTPRoute, + readyExplainerHTTPRoute, + readyTopLevelHTTPRoute, + ). + Build() + + reconciler := NewRawHTTPRouteReconciler(client, s, ingressConfig, isvcConfig) + result, err := reconciler.Reconcile(t.Context(), isvc) + g.Expect(err).ToNot(HaveOccurred()) + g.Expect(result.Requeue).To(BeFalse()) + g.Expect(result.RequeueAfter).To(BeZero()) + cond := isvc.Status.GetCondition(v1beta1.IngressReady) + g.Expect(cond).NotTo(BeNil()) + g.Expect(cond.Status).To(Equal(corev1.ConditionTrue)) + }) + + t.Run("Reconcile handles HTTPRoute not found (IsNotFound error)", func(t *testing.T) { + // This test specifically covers the edge case where checkHTTPRouteStatuses + // encounters an IsNotFound error when trying to get HTTPRoutes + isvc := &v1beta1.InferenceService{ + ObjectMeta: metav1.ObjectMeta{ + Name: "test-isvc-not-found", + Namespace: "default", + }, + Spec: v1beta1.InferenceServiceSpec{ + Predictor: v1beta1.PredictorSpec{}, + }, + Status: v1beta1.InferenceServiceStatus{}, + } + isvc.Status.SetCondition(v1beta1.PredictorReady, &apis.Condition{ + Type: v1beta1.PredictorReady, + Status: corev1.ConditionTrue, + }) + + // Create an interceptor client that blocks HTTPRoute creation + // This ensures that when checkHTTPRouteStatuses tries to get HTTPRoutes, + // it will encounter IsNotFound errors and trigger the edge case + baseClient := fake.NewClientBuilder(). + WithScheme(s). + WithObjects( + // Add a Service to simulate that components are ready + &corev1.Service{ + ObjectMeta: metav1.ObjectMeta{ + Name: constants.PredictorServiceName(isvc.Name), + Namespace: isvc.Namespace, + }, + }, + ). + Build() + + interceptorClient := &httpRouteClientInterceptor{ + Client: baseClient, + blockHTTPRouteCreation: true, + } + + reconciler := NewRawHTTPRouteReconciler(interceptorClient, s, ingressConfig, isvcConfig) + result, err := reconciler.Reconcile(t.Context(), isvc) + g.Expect(err).ToNot(HaveOccurred()) + g.Expect(result.Requeue).To(BeTrue()) + + cond := isvc.Status.GetCondition(v1beta1.IngressReady) + g.Expect(cond).NotTo(BeNil()) + g.Expect(cond.Status).To(Equal(corev1.ConditionFalse)) + // This is the specific edge case we're testing - when HTTPRoute is not found, + // the condition should be set with reason "Predictor Deployment NotReady" and + // message "Predictor HTTPRoute not created" + g.Expect(cond.Reason).To(Equal("Predictor Deployment NotReady")) + g.Expect(cond.Message).To(Equal("Predictor HTTPRoute not created")) }) } diff --git a/pkg/testing/envtest_setup.go b/pkg/testing/envtest_setup.go index 22eb63db06b..acd696a84ae 100644 --- a/pkg/testing/envtest_setup.go +++ b/pkg/testing/envtest_setup.go @@ -32,7 +32,7 @@ import ( "sigs.k8s.io/controller-runtime/pkg/envtest" logf "sigs.k8s.io/controller-runtime/pkg/log" "sigs.k8s.io/controller-runtime/pkg/manager" - gatewayapiv1 "sigs.k8s.io/gateway-api/apis/v1" + gwapiv1 "sigs.k8s.io/gateway-api/apis/v1" ) var log = logf.Log.WithName("TestingEnvSetup") @@ -58,7 +58,7 @@ func SetupEnvTest(crdDirectoryPaths []string) *envtest.Environment { log.Error(err, "Failed to add istio scheme") } - if err := gatewayapiv1.Install(scheme.Scheme); err != nil { + if err := gwapiv1.Install(scheme.Scheme); err != nil { log.Error(err, "Failed to add gateway scheme") } if err := kedav1alpha1.SchemeBuilder.AddToScheme(scheme.Scheme); err != nil { From 8346495232b00c5789ddaa0982215a42c78ee623 Mon Sep 17 00:00:00 2001 From: Sivanantham <90966311+sivanantha321@users.noreply.github.com> Date: Sun, 29 Jun 2025 03:49:30 +0530 Subject: [PATCH 2/9] Refactor KServe to use global context for PredictorConfig (#4526) Signed-off-by: Sivanantham Chinnaiyan --- python/aiffairness/aifserver/__main__.py | 1 - python/aiffairness/aifserver/model.py | 9 +- python/artexplainer/artserver/__main__.py | 10 - python/artexplainer/artserver/model.py | 4 +- python/custom_tokenizer/transformer.py | 21 +- python/custom_transformer/model.py | 33 +- python/custom_transformer/model_grpc.py | 16 +- .../huggingfaceserver/__main__.py | 8 - .../huggingfaceserver/encoder_model.py | 15 +- python/huggingfaceserver/tests/test_model.py | 37 +- python/kserve/kserve/__init__.py | 1 + python/kserve/kserve/context.py | 45 ++ python/kserve/kserve/model.py | 130 ++---- python/kserve/kserve/model_server.py | 12 +- python/kserve/kserve/predictor_config.py | 106 +++++ python/kserve/kserve/protocol/dataplane.py | 40 +- python/kserve/test/test_dataplane.py | 384 +++++++++--------- python/kserve/test/test_server.py | 120 +++++- 18 files changed, 559 insertions(+), 433 deletions(-) create mode 100644 python/kserve/kserve/context.py create mode 100644 python/kserve/kserve/predictor_config.py diff --git a/python/aiffairness/aifserver/__main__.py b/python/aiffairness/aifserver/__main__.py index c64a166d6fb..291c98478c5 100644 --- a/python/aiffairness/aifserver/__main__.py +++ b/python/aiffairness/aifserver/__main__.py @@ -70,7 +70,6 @@ logging.configure_logging(args.log_config_file) model = AIFModel( name=args.model_name, - predictor_host=args.predictor_host, feature_names=args.feature_names, label_names=args.label_names, favorable_label=args.favorable_label, diff --git a/python/aiffairness/aifserver/model.py b/python/aiffairness/aifserver/model.py index 5dd23ac1e2c..a7ddf8c6aea 100644 --- a/python/aiffairness/aifserver/model.py +++ b/python/aiffairness/aifserver/model.py @@ -11,16 +11,17 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. -from typing import Dict +from typing import Dict import asyncio -import kserve + +import nest_asyncio import numpy as np import pandas as pd from aif360.metrics import BinaryLabelDatasetMetric from aif360.datasets import BinaryLabelDataset -import nest_asyncio +import kserve nest_asyncio.apply() @@ -29,7 +30,6 @@ class AIFModel(kserve.Model): def __init__( self, name: str, - predictor_host: str, feature_names: list, label_names: list, favorable_label: float, @@ -39,7 +39,6 @@ def __init__( ): super().__init__(name) self.name = name - self.predictor_host = predictor_host self.ready = False self.feature_names = feature_names self.label_names = label_names diff --git a/python/artexplainer/artserver/__main__.py b/python/artexplainer/artserver/__main__.py index 7cf873d34d1..9a9bb664251 100644 --- a/python/artexplainer/artserver/__main__.py +++ b/python/artexplainer/artserver/__main__.py @@ -18,7 +18,6 @@ import kserve from kserve import logging -from kserve.model import PredictorConfig DEFAULT_ADVERSARY_TYPE = "SquareAttack" @@ -45,17 +44,8 @@ if __name__ == "__main__": if args.configure_logging: logging.configure_logging(args.log_config_file) - predictor_config = PredictorConfig( - predictor_host=args.predictor_host, - predictor_protocol=args.predictor_protocol, - predictor_use_ssl=args.predictor_use_ssl, - predictor_request_timeout_seconds=args.predictor_request_timeout_seconds, - predictor_request_retries=args.predictor_request_retries, - predictor_health_check=args.enable_predictor_health_check, - ) model = ARTModel( args.model_name, - predictor_config, adversary_type=args.adversary_type, nb_classes=args.nb_classes, max_iter=args.max_iter, diff --git a/python/artexplainer/artserver/model.py b/python/artexplainer/artserver/model.py index 297c6b0f9da..ae91b54f1ce 100644 --- a/python/artexplainer/artserver/model.py +++ b/python/artexplainer/artserver/model.py @@ -22,7 +22,6 @@ import kserve from kserve.logging import logger -from kserve.model import PredictorConfig nest_asyncio.apply() @@ -32,12 +31,11 @@ class ARTModel(kserve.Model): # pylint:disable=c-extension-no-member def __init__( self, name: str, - predictor_config: PredictorConfig, adversary_type: str, nb_classes: str, max_iter: str, ): - super().__init__(name, predictor_config) + super().__init__(name) if str.lower(adversary_type) != "squareattack": raise Exception("Invalid adversary type: %s" % adversary_type) self.adversary_type = adversary_type diff --git a/python/custom_tokenizer/transformer.py b/python/custom_tokenizer/transformer.py index 6b492c673ba..5ad1956a916 100644 --- a/python/custom_tokenizer/transformer.py +++ b/python/custom_tokenizer/transformer.py @@ -28,16 +28,11 @@ ModelServer, logging, ) -from kserve.model import PredictorConfig class Tokenizer(kserve.Model): - def __init__( - self, - name: str, - predictor_config: PredictorConfig, - ): - super().__init__(name, predictor_config) + def __init__(self, name: str): + super().__init__(name) self.short_paragraph_text = ( "The Apollo program was the third United States human spaceflight program. " "First conceived as a three-man spacecraft to follow the one-man Project Mercury " @@ -122,15 +117,5 @@ def postprocess( if __name__ == "__main__": if args.configure_logging: logging.configure_logging(args.log_config_file) - model = Tokenizer( - args.model_name, - PredictorConfig( - args.predictor_host, - args.predictor_protocol, - args.predictor_use_ssl, - args.predictor_request_timeout_seconds, - args.predictor_request_retries, - args.enable_predictor_health_check, - ), - ) + model = Tokenizer(args.model_name) ModelServer().start([model]) diff --git a/python/custom_transformer/model.py b/python/custom_transformer/model.py index 06a25d8f613..e479db99e11 100644 --- a/python/custom_transformer/model.py +++ b/python/custom_transformer/model.py @@ -30,7 +30,7 @@ InferResponse, logging, ) -from kserve.model import PredictorProtocol, PredictorConfig +from kserve.model import PredictorProtocol def image_transform(model_name, data): @@ -60,16 +60,8 @@ def image_transform(model_name, data): class ImageTransformer(Model): - def __init__( - self, - name: str, - predictor_config: PredictorConfig, - ): - super().__init__( - name, - predictor_config, - return_response_headers=True, - ) + def __init__(self, name: str): + super().__init__(name, return_response_headers=True) self.ready = True def preprocess( @@ -100,7 +92,7 @@ def preprocess( infer_request = InferRequest(model_name=self.name, infer_inputs=infer_inputs) # Transform to KServe v1/v2 inference protocol - if self.protocol == PredictorProtocol.REST_V1.value: + if self.predictor_config.predictor_protocol == PredictorProtocol.REST_V1.value: inputs = [{"data": input_tensor.tolist()} for input_tensor in input_tensors] payload = {"instances": inputs} return payload @@ -114,7 +106,10 @@ def postprocess( response_headers: Dict[str, str] = None, ) -> Union[Dict, InferResponse]: if "request-type" in headers and headers["request-type"] == "v1": - if self.protocol == PredictorProtocol.REST_V1.value: + if ( + self.predictor_config.predictor_protocol + == PredictorProtocol.REST_V1.value + ): return infer_response else: # if predictor protocol is v2 but transformer uses v1 @@ -129,15 +124,5 @@ def postprocess( if __name__ == "__main__": if args.configure_logging: logging.configure_logging(args.log_config_file) - model = ImageTransformer( - args.model_name, - PredictorConfig( - args.predictor_host, - args.predictor_protocol, - args.predictor_use_ssl, - args.predictor_request_timeout_seconds, - args.predictor_request_retries, - args.enable_predictor_health_check, - ), - ) + model = ImageTransformer(args.model_name) ModelServer().start([model]) diff --git a/python/custom_transformer/model_grpc.py b/python/custom_transformer/model_grpc.py index 70c341aacd5..b66c7e97c73 100644 --- a/python/custom_transformer/model_grpc.py +++ b/python/custom_transformer/model_grpc.py @@ -19,7 +19,6 @@ from PIL import Image from torchvision import transforms from kserve import Model, ModelServer, model_server, InferInput, InferRequest, logging -from kserve.model import PredictorConfig def image_transform(data): @@ -47,9 +46,8 @@ class ImageTransformer(Model): def __init__( self, name: str, - predictor_config: PredictorConfig, ): - super().__init__(name, predictor_config) + super().__init__(name) self.ready = True def preprocess( @@ -77,15 +75,5 @@ def preprocess( if __name__ == "__main__": if args.configure_logging: logging.configure_logging(args.log_config_file) - model = ImageTransformer( - args.model_name, - PredictorConfig( - args.predictor_host, - args.predictor_protocol, - args.predictor_use_ssl, - args.predictor_request_timeout_seconds, - args.predictor_request_retries, - args.enable_predictor_health_check, - ), - ) + model = ImageTransformer(args.model_name) ModelServer(workers=1).start([model]) diff --git a/python/huggingfaceserver/huggingfaceserver/__main__.py b/python/huggingfaceserver/huggingfaceserver/__main__.py index a3dcc3dce4c..7fb41f6a0af 100644 --- a/python/huggingfaceserver/huggingfaceserver/__main__.py +++ b/python/huggingfaceserver/huggingfaceserver/__main__.py @@ -21,7 +21,6 @@ from huggingfaceserver.request_logger import RequestLogger from kserve import logging from kserve.logging import logger -from kserve.model import PredictorConfig from kserve.storage import Storage from transformers import AutoConfig @@ -275,12 +274,6 @@ def load_model(): request_logger=request_logger, ) else: - predictor_config = PredictorConfig( - args.predictor_host, - args.predictor_protocol, - args.predictor_use_ssl, - args.predictor_request_timeout_seconds, - ) logger.info(f"Loading encoder model for task '{task.name}' in {dtype}") model = HuggingfaceEncoderModel( model_name=args.model_name, @@ -296,7 +289,6 @@ def load_model(): trust_remote_code=kwargs["trust_remote_code"], tensor_input_names=kwargs.get("tensor_input_names", None), return_token_type_ids=kwargs.get("return_token_type_ids", None), - predictor_config=predictor_config, request_logger=request_logger, return_probabilities=kwargs.get("return_probabilities", False), ) diff --git a/python/huggingfaceserver/huggingfaceserver/encoder_model.py b/python/huggingfaceserver/huggingfaceserver/encoder_model.py index ba7ec10b3e1..267d40828bd 100644 --- a/python/huggingfaceserver/huggingfaceserver/encoder_model.py +++ b/python/huggingfaceserver/huggingfaceserver/encoder_model.py @@ -23,7 +23,6 @@ from accelerate import init_empty_weights from kserve import Model from kserve.logging import logger -from kserve.model import PredictorConfig from kserve.protocol.infer_type import InferInput, InferRequest, InferResponse from kserve.utils.utils import ( from_np_dtype, @@ -64,6 +63,7 @@ RerankRequest, UsageInfo, ) +from kserve import context as kserve_context class HuggingfaceEncoderModel( @@ -101,10 +101,9 @@ def __init__( tokenizer_revision: Optional[str] = None, trust_remote_code: bool = False, return_probabilities: bool = False, - predictor_config: Optional[PredictorConfig] = None, request_logger: Optional[RequestLogger] = None, ): - super().__init__(model_name, predictor_config) + super().__init__(model_name) self._device = torch.device("cuda" if torch.cuda.is_available() else "cpu") self.model_id_or_path = model_id_or_path self.do_lower_case = do_lower_case @@ -183,7 +182,9 @@ def load(self) -> bool: logger.info("Successfully loaded tokenizer") # load huggingface model using from_pretrained for inference mode - if not self.predictor_host: + # If predictor_host is not set + predictor_config = kserve_context.get_predictor_config() + if predictor_config is None or predictor_config.predictor_host is None: self._model = model_cls.from_pretrained( model_id_or_path, revision=self.model_revision, @@ -219,7 +220,8 @@ def preprocess( request_id = "N.A." self._log_request(request_id, instances) # Serialize to tensor - if self.predictor_host: + predictor_config = kserve_context.get_predictor_config() + if predictor_config and predictor_config.predictor_host: inputs = self._tokenizer( instances, max_length=self.max_length, @@ -268,7 +270,8 @@ async def predict( input_batch: Union[BatchEncoding, InferRequest], context: Dict[str, Any], ) -> Union[Tensor, InferResponse]: - if self.predictor_host: + predictor_config = kserve_context.get_predictor_config() + if predictor_config and predictor_config.predictor_host: # when predictor_host is provided, serialize the tensor and send to optimized model serving runtime # like NVIDIA triton inference server return await super().predict(input_batch, context) diff --git a/python/huggingfaceserver/tests/test_model.py b/python/huggingfaceserver/tests/test_model.py index c94535505ba..692ef942c69 100644 --- a/python/huggingfaceserver/tests/test_model.py +++ b/python/huggingfaceserver/tests/test_model.py @@ -15,13 +15,12 @@ import pytest import torch import json -from kserve.model import PredictorConfig + from kserve.protocol.rest.openai.types import ( ChatCompletionRequest, CompletionRequest, ) from kserve.protocol.rest.openai.errors import OpenAIError -from pytest_httpx import HTTPXMock from transformers import AutoConfig from pytest import approx @@ -236,40 +235,6 @@ async def test_model_revision(request: HuggingfaceEncoderModel): assert response == {"predictions": ["paris", "france"]} -@pytest.mark.asyncio -async def test_bert_predictor_host(request, httpx_mock: HTTPXMock): - model_name = "bert" - httpx_mock.add_response( - json={ - "model_name": model_name, - "outputs": [ - { - "name": "OUTPUT__0", - "shape": [1, 9, 758], - "data": [1] * 9 * 758, - "datatype": "INT64", - } - ], - } - ) - - model = HuggingfaceEncoderModel( - model_name, - model_id_or_path="google-bert/bert-base-uncased", - tensor_input_names="input_ids", - predictor_config=PredictorConfig( - predictor_host="localhost:8081", predictor_protocol="v2" - ), - ) - model.load() - request.addfinalizer(model.stop) - - response, _ = await model( - {"instances": ["The capital of France is [MASK]."]}, headers={} - ) - assert response == {"predictions": ["[PAD]"]} - - @pytest.mark.asyncio async def test_bert_sequence_classification(bert_base_yelp_polarity): request = "Hello, my dog is cute." diff --git a/python/kserve/kserve/__init__.py b/python/kserve/kserve/__init__.py index 79244b6a0f9..75640c6352b 100644 --- a/python/kserve/kserve/__init__.py +++ b/python/kserve/kserve/__init__.py @@ -15,6 +15,7 @@ from __future__ import absolute_import from .model import Model +from .predictor_config import PredictorConfig from .model_server import ModelServer from .inference_client import InferenceGRPCClient, InferenceRESTClient, RESTConfig from .protocol.infer_type import InferRequest, InferInput, InferResponse, InferOutput diff --git a/python/kserve/kserve/context.py b/python/kserve/kserve/context.py new file mode 100644 index 00000000000..1be22290d9b --- /dev/null +++ b/python/kserve/kserve/context.py @@ -0,0 +1,45 @@ +# Copyright 2024 The KServe Authors. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +"""Global context management for KServe model server configuration.""" + +import contextvars +from typing import Optional + +from .predictor_config import PredictorConfig + +# Global context variable for predictor configuration +_predictor_config_var: contextvars.ContextVar[Optional[PredictorConfig]] = ( + contextvars.ContextVar("predictor_config", default=None) +) + + +def set_predictor_config(config: PredictorConfig) -> None: + """Set the predictor configuration for the current context. + + This should be called once during ModelServer initialization. + + Args: + config: The PredictorConfig instance to set + """ + _predictor_config_var.set(config) + + +def get_predictor_config() -> Optional[PredictorConfig]: + """Get the predictor configuration from the current context. + + Returns: + The PredictorConfig instance if set, None otherwise + """ + return _predictor_config_var.get() diff --git a/python/kserve/kserve/model.py b/python/kserve/kserve/model.py index 765675ed7e0..42a302d3310 100644 --- a/python/kserve/kserve/model.py +++ b/python/kserve/kserve/model.py @@ -20,6 +20,8 @@ from cloudevents.http import CloudEvent +from . import context as kserve_context +from .predictor_config import PredictorConfig from .constants.constants import ( PredictorProtocol, EXPLAINER_BASE_URL_FORMAT, @@ -141,50 +143,10 @@ def get_latency_ms(start: float, end: float) -> float: return round((end - start) * 1000, 9) -class PredictorConfig: - def __init__( - self, - predictor_host: str, - predictor_protocol: str = PredictorProtocol.REST_V1.value, - predictor_use_ssl: bool = False, - predictor_request_timeout_seconds: int = 600, - predictor_request_retries: int = 0, - predictor_health_check: bool = False, - ): - """The configuration for the http call to the predictor - - Args: - predictor_host: The host name of the predictor - predictor_protocol: The inference protocol used for predictor http call - predictor_use_ssl: Enable using ssl for http connection to the predictor - predictor_request_timeout_seconds: The request timeout seconds for the predictor http call. Default is 600 seconds. - predictor_request_retries: The number of retries if the predictor request fails. Default is 0. - predictor_health_check: Enable predictor health check - """ - self.predictor_host = predictor_host - self.predictor_protocol = predictor_protocol - self.predictor_use_ssl = predictor_use_ssl - self.predictor_request_timeout_seconds = predictor_request_timeout_seconds - self.predictor_request_retries = predictor_request_retries - self.predictor_health_check = predictor_health_check - - @property - def predictor_base_url(self) -> str: - """ - Get the base url for the predictor. - - Returns: - str: The base url for the predictor - """ - protocol = "https" if self.predictor_use_ssl else "http" - return f"{protocol}://{self.predictor_host}" - - class Model(InferenceModel): def __init__( self, name: str, - predictor_config: Optional[PredictorConfig] = None, return_response_headers: bool = False, ): """KServe Model Public Interface @@ -193,40 +155,20 @@ def __init__( Args: name: The name of the model. - predictor_config: The configurations for http call to the predictor. """ super().__init__(name) - # The predictor config member fields are kept for backwards compatibility as they could be set outside - self.protocol = ( - predictor_config.predictor_protocol - if predictor_config - else PredictorProtocol.REST_V1.value - ) - self.predictor_host = ( - predictor_config.predictor_host if predictor_config else None - ) - # The default timeout matches what is set in generated Istio virtual service resources. - # We generally don't want things to time out at the request level here, - # timeouts should be handled elsewhere in the system. - self.timeout = ( - predictor_config.predictor_request_timeout_seconds - if predictor_config - else 600 - ) - self.use_ssl = predictor_config.predictor_use_ssl if predictor_config else False - self.retries = ( - predictor_config.predictor_request_retries if predictor_config else 0 - ) self.explainer_host = None - self._predictor_base_url = ( - predictor_config.predictor_base_url if predictor_config else None - ) self._http_client_instance = None self._grpc_client_stub = None self.enable_latency_logging = False self.required_response_headers = return_response_headers + @property + def predictor_config(self) -> Optional[PredictorConfig]: + # Return predictor config from context, may be None + return kserve_context.get_predictor_config() + async def __call__( self, body: Union[Dict, CloudEvent, InferRequest], @@ -317,9 +259,16 @@ async def __call__( @property def _http_client(self) -> InferenceRESTClient: - if self._http_client_instance is None and self.predictor_host: + predictor_config = self.predictor_config + if predictor_config is None: + raise RuntimeError( + "PredictorConfig is required to create HTTP client but is None." + ) + if self._http_client_instance is None and self.predictor_config.predictor_host: config = RESTConfig( - protocol=self.protocol, timeout=self.timeout, retries=self.retries + protocol=self.predictor_config.protocol, + timeout=self.predictor_config.timeout, + retries=self.predictor_config.retries, ) self._http_client_instance = InferenceClientFactory().get_rest_client( config=config @@ -328,12 +277,17 @@ def _http_client(self) -> InferenceRESTClient: @property def _grpc_client(self) -> InferenceGRPCClient: - if self._grpc_client_stub is None and self.predictor_host: + predictor_config = self.predictor_config + if predictor_config is None: + raise RuntimeError( + "PredictorConfig is required to create GRPC client but is None." + ) + if self._grpc_client_stub is None and self.predictor_config.predictor_host: self._grpc_client_stub = InferenceClientFactory().get_grpc_client( - url=self.predictor_host, - use_ssl=self.use_ssl, - timeout=self.timeout, - retries=self.retries, + url=self.predictor_config.predictor_host, + use_ssl=self.predictor_config.use_ssl, + timeout=self.predictor_config.timeout, + retries=self.predictor_config.retries, ) return self._grpc_client_stub @@ -343,16 +297,19 @@ def validate(self, payload): if isinstance(payload, InferRequest): return payload # TODO: validate the request if self.get_input_types() defines the input types. - if self.protocol == PredictorProtocol.REST_V2.value: - if "inputs" in payload and not isinstance(payload["inputs"], list): - raise InvalidInput('Expected "inputs" to be a list') - elif self.protocol == PredictorProtocol.REST_V1.value: - if ( - isinstance(payload, Dict) - and "instances" in payload - and not isinstance(payload["instances"], list) - ): - raise InvalidInput('Expected "instances" to be a list') + predictor_config = self.predictor_config + if predictor_config is not None: + if predictor_config.protocol == PredictorProtocol.REST_V2.value: + if "inputs" in payload and not isinstance(payload["inputs"], list): + raise InvalidInput('Expected "inputs" to be a list') + elif predictor_config.protocol == PredictorProtocol.REST_V1.value: + if ( + isinstance(payload, Dict) + and "instances" in payload + and not isinstance(payload["instances"], list) + ): + raise InvalidInput('Expected "instances" to be a list') + # If predictor_config is None, skip protocol-specific validation return payload def load(self) -> bool: @@ -416,7 +373,7 @@ async def _http_predict( predict_headers["x-b3-traceid"] = headers["x-b3-traceid"] response = await self._http_client.infer( - self._predictor_base_url, + self.predictor_config.predictor_base_url, model_name=self.name, data=payload, headers=predict_headers, @@ -461,9 +418,12 @@ async def predict( Raises: HTTPStatusError when getting back an error response from the predictor. """ - if not self.predictor_host: + predictor_config = self.predictor_config + if predictor_config is None: + raise NotImplementedError("Could not find PredictorConfig.") + if not self.predictor_config.predictor_host: raise NotImplementedError("Could not find predictor_host.") - if self.protocol == PredictorProtocol.GRPC_V2.value: + if self.predictor_config.protocol == PredictorProtocol.GRPC_V2.value: return await self._grpc_predict(payload, headers) else: return await self._http_predict(payload, headers, response_headers) diff --git a/python/kserve/kserve/model_server.py b/python/kserve/kserve/model_server.py index af7b365edf5..addeedb5df9 100644 --- a/python/kserve/kserve/model_server.py +++ b/python/kserve/kserve/model_server.py @@ -24,6 +24,7 @@ from fastapi.responses import ORJSONResponse from . import logging +from . import context as kserve_context from .constants.constants import ( DEFAULT_HTTP_PORT, DEFAULT_GRPC_PORT, @@ -32,7 +33,8 @@ ) from .errors import NoModelReady from .logging import logger -from .model import BaseKServeModel, PredictorConfig +from .model import BaseKServeModel +from .predictor_config import PredictorConfig from .model_repository import ModelRepository from .protocol.dataplane import DataPlane from .protocol.grpc.server import GRPCServer @@ -261,9 +263,11 @@ def __init__( predictor_request_retries=args.predictor_request_retries, predictor_health_check=args.enable_predictor_health_check, ) - self.dataplane = DataPlane( - model_registry=self.registered_models, predictor_config=_predictor_config - ) + + # Set the predictor config in the global context + kserve_context.set_predictor_config(_predictor_config) + + self.dataplane = DataPlane(model_registry=self.registered_models) self._rest_server = None self._rest_multiprocess_server = None self._grpc_server = None diff --git a/python/kserve/kserve/predictor_config.py b/python/kserve/kserve/predictor_config.py new file mode 100644 index 00000000000..a727313529e --- /dev/null +++ b/python/kserve/kserve/predictor_config.py @@ -0,0 +1,106 @@ +# Copyright 2021 The KServe Authors. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +"""Configuration classes for KServe.""" + +from .constants.constants import PredictorProtocol + + +class PredictorConfig: + def __init__( + self, + predictor_host: str, + predictor_protocol: str = PredictorProtocol.REST_V1.value, + predictor_use_ssl: bool = False, + predictor_request_timeout_seconds: int = 600, + predictor_request_retries: int = 0, + predictor_health_check: bool = False, + ): + """The configuration for the http call to the predictor + + Args: + predictor_host: The host name of the predictor + predictor_protocol: The inference protocol used for predictor http call + predictor_use_ssl: Enable using ssl for http connection to the predictor + predictor_request_timeout_seconds: The request timeout seconds for the predictor http call. Default is 600 seconds. + predictor_request_retries: The number of retries if the predictor request fails. Default is 0. + predictor_health_check: Enable predictor health check + """ + self._predictor_host = predictor_host + self._predictor_protocol = predictor_protocol + self._predictor_use_ssl = predictor_use_ssl + self._predictor_request_timeout_seconds = predictor_request_timeout_seconds + self._predictor_request_retries = predictor_request_retries + self._predictor_health_check = predictor_health_check + + @property + def predictor_host(self) -> str: + """Get the predictor host.""" + return self._predictor_host + + @property + def predictor_protocol(self) -> str: + """Get the predictor protocol.""" + return self._predictor_protocol + + @property + def predictor_use_ssl(self) -> bool: + """Get the predictor use ssl flag.""" + return self._predictor_use_ssl + + @property + def predictor_request_timeout_seconds(self) -> int: + """Get the predictor request timeout in seconds.""" + return self._predictor_request_timeout_seconds + + @property + def predictor_request_retries(self) -> int: + """Get the predictor request retries.""" + return self._predictor_request_retries + + @property + def predictor_health_check(self) -> bool: + """Get the predictor health check flag.""" + return self._predictor_health_check + + @property + def predictor_base_url(self) -> str: + """ + Get the base url for the predictor. + + Returns: + str: The base url for the predictor + """ + protocol = "https" if self._predictor_use_ssl else "http" + return f"{protocol}://{self._predictor_host}" + + @property + def protocol(self) -> str: + """Alias for predictor_protocol for backward compatibility.""" + return self._predictor_protocol + + @property + def timeout(self) -> int: + """Alias for predictor_request_timeout_seconds for backward compatibility.""" + return self._predictor_request_timeout_seconds + + @property + def retries(self) -> int: + """Alias for predictor_request_retries for backward compatibility.""" + return self._predictor_request_retries + + @property + def use_ssl(self) -> bool: + """Alias for predictor_use_ssl for backward compatibility.""" + return self._predictor_use_ssl diff --git a/python/kserve/kserve/protocol/dataplane.py b/python/kserve/kserve/protocol/dataplane.py index dd70dbbf1bd..fadecf73526 100644 --- a/python/kserve/kserve/protocol/dataplane.py +++ b/python/kserve/kserve/protocol/dataplane.py @@ -29,10 +29,12 @@ from ..errors import InvalidInput, ModelNotFound from ..inference_client import RESTConfig from ..logging import logger -from ..model import BaseKServeModel, InferenceModel, InferenceVerb, PredictorConfig +from ..model import BaseKServeModel, InferenceModel, InferenceVerb +from ..predictor_config import PredictorConfig from ..model_repository import ModelRepository from ..utils.inference_client_factory import InferenceClientFactory from ..utils.utils import create_response_cloudevent, is_structured_cloudevent +from .. import context as kserve_context from .infer_type import InferRequest, InferResponse from .rest.v2_datamodels import InferenceRequest @@ -47,18 +49,13 @@ class DataPlane: """KServe DataPlane""" - def __init__( - self, - model_registry: ModelRepository, - predictor_config: Optional[PredictorConfig] = None, - ): + def __init__(self, model_registry: ModelRepository): self._model_registry = model_registry self._server_name = constants.KSERVE_MODEL_SERVER_NAME # Dynamically fetching version of the installed 'kserve' distribution. The assumption is # that 'kserve' will already be installed by the time this class is instantiated. self._server_version = metadata.version("kserve") - self.predictor_config = predictor_config self._inference_grpc_client = None self._inference_rest_client = None @@ -66,14 +63,24 @@ def __init__( def model_registry(self): return self._model_registry + @property + def predictor_config(self) -> Optional[PredictorConfig]: + # Return predictor config from context, may be None + return kserve_context.get_predictor_config() + @property def rest_client(self): if self._inference_rest_client is None: + predictor_config = self.predictor_config + if predictor_config is None: + raise RuntimeError( + "PredictorConfig is required to create REST client but is None." + ) self._inference_rest_client = InferenceClientFactory().get_rest_client( RESTConfig( - protocol=self.predictor_config.predictor_protocol, - retries=self.predictor_config.predictor_request_retries, - timeout=self.predictor_config.predictor_request_timeout_seconds, + protocol=predictor_config.predictor_protocol, + retries=predictor_config.predictor_request_retries, + timeout=predictor_config.predictor_request_timeout_seconds, ) ) return self._inference_rest_client @@ -81,11 +88,16 @@ def rest_client(self): @property def grpc_client(self): if self._inference_grpc_client is None: + predictor_config = self.predictor_config + if predictor_config is None: + raise RuntimeError( + "PredictorConfig is required to create GRPC client but is None." + ) self._inference_grpc_client = InferenceClientFactory().get_grpc_client( - url=self.predictor_config.predictor_host, - timeout=self.predictor_config.predictor_request_timeout_seconds, - retries=self.predictor_config.predictor_request_retries, - use_ssl=self.predictor_config.predictor_use_ssl, + url=predictor_config.predictor_host, + timeout=predictor_config.predictor_request_timeout_seconds, + retries=predictor_config.predictor_request_retries, + use_ssl=predictor_config.predictor_use_ssl, ) return self._inference_grpc_client diff --git a/python/kserve/test/test_dataplane.py b/python/kserve/test/test_dataplane.py index 645fb7a65f7..8dc3d554da7 100644 --- a/python/kserve/test/test_dataplane.py +++ b/python/kserve/test/test_dataplane.py @@ -35,8 +35,10 @@ ) from typing import AsyncIterator, Union from kserve.errors import InvalidInput, ModelNotFound -from kserve.model import PredictorProtocol, PredictorConfig +from kserve.model import PredictorProtocol +from kserve.predictor_config import PredictorConfig from kserve.protocol.dataplane import DataPlane +from kserve import context as kserve_context from kserve.protocol.rest.openai import CompletionRequest, OpenAIGenerativeModel from kserve.model_repository import ModelRepository from kserve.ray import RayModel @@ -462,34 +464,33 @@ async def test_dataplane_rest_with_ssl_enabled(self, httpx_mock): httpx_mock.add_response( url=re.compile(f"https://{predictor_host}/*"), json={"status": "alive"} ) - dataplane = DataPlane( - model_registry=ModelRepository(), - predictor_config=PredictorConfig( - predictor_host=predictor_host, - predictor_protocol=PredictorProtocol.REST_V1.value, - predictor_request_retries=2, - predictor_request_timeout_seconds=5, - predictor_health_check=True, - predictor_use_ssl=True, - ), + predictor_config = PredictorConfig( + predictor_host=predictor_host, + predictor_protocol=PredictorProtocol.REST_V1.value, + predictor_request_retries=2, + predictor_request_timeout_seconds=5, + predictor_health_check=True, + predictor_use_ssl=True, ) + kserve_context.set_predictor_config(predictor_config) + dataplane = DataPlane(model_registry=ModelRepository()) + assert (await dataplane.ready()) is True @patch("kserve.protocol.dataplane.InferenceClientFactory.get_grpc_client") async def test_dataplane_grpc_with_ssl_enabled(self, mock_grpc_client): # scenario: getting a 2xx response from predictor with ssl enabled predictor_host = "ready.host" - dataplane = DataPlane( - model_registry=ModelRepository(), - predictor_config=PredictorConfig( - predictor_host=predictor_host, - predictor_protocol=PredictorProtocol.GRPC_V2.value, - predictor_request_retries=2, - predictor_request_timeout_seconds=5, - predictor_health_check=True, - predictor_use_ssl=True, - ), - ) + predictor_config = PredictorConfig( + predictor_host=predictor_host, + predictor_protocol=PredictorProtocol.GRPC_V2.value, + predictor_request_retries=2, + predictor_request_timeout_seconds=5, + predictor_health_check=True, + predictor_use_ssl=True, + ) + kserve_context.set_predictor_config(predictor_config) + dataplane = DataPlane(model_registry=ModelRepository()) mock_is_server_ready = mock.AsyncMock(return_value=True) mock_grpc_client.return_value.is_server_ready = mock_is_server_ready assert (await dataplane.ready()) is True @@ -503,16 +504,15 @@ async def test_server_readiness_v1(self, httpx_mock): httpx_mock.add_response( url=re.compile(f"http://{predictor_host}/*"), json={"status": "alive"} ) - dataplane = DataPlane( - model_registry=ModelRepository(), - predictor_config=PredictorConfig( - predictor_host=predictor_host, - predictor_protocol=PredictorProtocol.REST_V1.value, - predictor_request_retries=2, - predictor_request_timeout_seconds=5, - predictor_health_check=True, - ), + predictor_config = PredictorConfig( + predictor_host=predictor_host, + predictor_protocol=PredictorProtocol.REST_V1.value, + predictor_request_retries=2, + predictor_request_timeout_seconds=5, + predictor_health_check=True, ) + kserve_context.set_predictor_config(predictor_config) + dataplane = DataPlane(model_registry=ModelRepository()) assert (await dataplane.ready()) is True # scenario: not a 2xx response from predictor @@ -520,16 +520,15 @@ async def test_server_readiness_v1(self, httpx_mock): httpx_mock.add_response( url=re.compile(f"http://{predictor_host}/*"), status_code=500 ) - dataplane = DataPlane( - model_registry=ModelRepository(), - predictor_config=PredictorConfig( - predictor_host=predictor_host, - predictor_protocol=PredictorProtocol.REST_V1.value, - predictor_request_retries=2, - predictor_request_timeout_seconds=5, - predictor_health_check=True, - ), + predictor_config = PredictorConfig( + predictor_host=predictor_host, + predictor_protocol=PredictorProtocol.REST_V1.value, + predictor_request_retries=2, + predictor_request_timeout_seconds=5, + predictor_health_check=True, ) + kserve_context.set_predictor_config(predictor_config) + dataplane = DataPlane(model_registry=ModelRepository()) with pytest.raises(httpx.HTTPStatusError): await dataplane.ready() @@ -539,16 +538,15 @@ async def test_server_readiness_v2(self, httpx_mock): httpx_mock.add_response( url=re.compile(f"http://{predictor_host}/v2/*"), json={"ready": True} ) - dataplane = DataPlane( - model_registry=ModelRepository(), - predictor_config=PredictorConfig( - predictor_host=predictor_host, - predictor_protocol=PredictorProtocol.REST_V2.value, - predictor_request_retries=2, - predictor_request_timeout_seconds=5, - predictor_health_check=True, - ), + predictor_config = PredictorConfig( + predictor_host=predictor_host, + predictor_protocol=PredictorProtocol.REST_V2.value, + predictor_request_retries=2, + predictor_request_timeout_seconds=5, + predictor_health_check=True, ) + kserve_context.set_predictor_config(predictor_config) + dataplane = DataPlane(model_registry=ModelRepository()) assert (await dataplane.ready()) is True # scenario: getting a 2xx response from predictor and server not ready @@ -556,16 +554,15 @@ async def test_server_readiness_v2(self, httpx_mock): httpx_mock.add_response( url=re.compile(f"http://{predictor_host}/v2/*"), json={"ready": False} ) - dataplane = DataPlane( - model_registry=ModelRepository(), - predictor_config=PredictorConfig( - predictor_host=predictor_host, - predictor_protocol=PredictorProtocol.REST_V2.value, - predictor_request_retries=2, - predictor_request_timeout_seconds=5, - predictor_health_check=True, - ), + predictor_config = PredictorConfig( + predictor_host=predictor_host, + predictor_protocol=PredictorProtocol.REST_V2.value, + predictor_request_retries=2, + predictor_request_timeout_seconds=5, + predictor_health_check=True, ) + kserve_context.set_predictor_config(predictor_config) + dataplane = DataPlane(model_registry=ModelRepository()) assert (await dataplane.ready()) is False # scenario: not a 2xx response from predictor @@ -573,16 +570,15 @@ async def test_server_readiness_v2(self, httpx_mock): httpx_mock.add_response( url=re.compile(f"http://{predictor_host}/v2/*"), status_code=500 ) - dataplane = DataPlane( - model_registry=ModelRepository(), - predictor_config=PredictorConfig( - predictor_host=predictor_host, - predictor_protocol=PredictorProtocol.REST_V2.value, - predictor_request_retries=2, - predictor_request_timeout_seconds=5, - predictor_health_check=True, - ), + predictor_config = PredictorConfig( + predictor_host=predictor_host, + predictor_protocol=PredictorProtocol.REST_V2.value, + predictor_request_retries=2, + predictor_request_timeout_seconds=5, + predictor_health_check=True, ) + kserve_context.set_predictor_config(predictor_config) + dataplane = DataPlane(model_registry=ModelRepository()) with pytest.raises(httpx.HTTPStatusError): await dataplane.ready() @@ -590,16 +586,15 @@ async def test_server_readiness_v2(self, httpx_mock): async def test_server_readiness_grpc_v2(self, mock_grpc_client): # scenario: getting a 2xx response from predictor predictor_host = "ready.host" - dataplane = DataPlane( - model_registry=ModelRepository(), - predictor_config=PredictorConfig( - predictor_host=predictor_host, - predictor_protocol=PredictorProtocol.GRPC_V2.value, - predictor_request_retries=2, - predictor_request_timeout_seconds=5, - predictor_health_check=True, - ), - ) + predictor_config = PredictorConfig( + predictor_host=predictor_host, + predictor_protocol=PredictorProtocol.GRPC_V2.value, + predictor_request_retries=2, + predictor_request_timeout_seconds=5, + predictor_health_check=True, + ) + kserve_context.set_predictor_config(predictor_config) + dataplane = DataPlane(model_registry=ModelRepository()) mock_is_server_ready = mock.AsyncMock(return_value=True) mock_grpc_client.return_value.is_server_ready = mock_is_server_ready assert (await dataplane.ready()) is True @@ -609,16 +604,15 @@ async def test_server_readiness_grpc_v2(self, mock_grpc_client): # scenario: getting a 2xx response from predictor and server not ready predictor_host = "not-ready.host" - dataplane = DataPlane( - model_registry=ModelRepository(), - predictor_config=PredictorConfig( - predictor_host=predictor_host, - predictor_protocol=PredictorProtocol.GRPC_V2.value, - predictor_request_retries=2, - predictor_request_timeout_seconds=5, - predictor_health_check=True, - ), - ) + predictor_config = PredictorConfig( + predictor_host=predictor_host, + predictor_protocol=PredictorProtocol.GRPC_V2.value, + predictor_request_retries=2, + predictor_request_timeout_seconds=5, + predictor_health_check=True, + ) + kserve_context.set_predictor_config(predictor_config) + dataplane = DataPlane(model_registry=ModelRepository()) mock_is_server_ready = mock.AsyncMock(return_value=False) mock_grpc_client.return_value.is_server_ready = mock_is_server_ready assert (await dataplane.ready()) is False @@ -632,16 +626,15 @@ async def test_model_readiness_v1(self, httpx_mock): httpx_mock.add_response( url=re.compile(f"http://{predictor_host}/v1/*"), json={"ready": True} ) - dataplane = DataPlane( - model_registry=ModelRepository(), - predictor_config=PredictorConfig( - predictor_host=predictor_host, - predictor_protocol=PredictorProtocol.REST_V1.value, - predictor_request_retries=2, - predictor_request_timeout_seconds=5, - predictor_health_check=True, - ), + predictor_config = PredictorConfig( + predictor_host=predictor_host, + predictor_protocol=PredictorProtocol.REST_V1.value, + predictor_request_retries=2, + predictor_request_timeout_seconds=5, + predictor_health_check=True, ) + kserve_context.set_predictor_config(predictor_config) + dataplane = DataPlane(model_registry=ModelRepository()) # Transformer model ready ready_model = DummyModel("ReadyModel") dataplane._model_registry.update(ready_model) @@ -652,16 +645,15 @@ async def test_model_readiness_v1(self, httpx_mock): httpx_mock.add_response( url=re.compile(f"http://{predictor_host}/v1/*"), json={"ready": False} ) - dataplane = DataPlane( - model_registry=ModelRepository(), - predictor_config=PredictorConfig( - predictor_host=predictor_host, - predictor_protocol=PredictorProtocol.REST_V1.value, - predictor_request_retries=2, - predictor_request_timeout_seconds=5, - predictor_health_check=True, - ), + predictor_config = PredictorConfig( + predictor_host=predictor_host, + predictor_protocol=PredictorProtocol.REST_V1.value, + predictor_request_retries=2, + predictor_request_timeout_seconds=5, + predictor_health_check=True, ) + kserve_context.set_predictor_config(predictor_config) + dataplane = DataPlane(model_registry=ModelRepository()) # Transformer model ready not_ready_model = DummyModel("NotReadyModel") dataplane._model_registry.update(not_ready_model) @@ -672,16 +664,15 @@ async def test_model_readiness_v1(self, httpx_mock): httpx_mock.add_response( url=re.compile(f"http://{predictor_host}/v1/*"), status_code=503 ) - dataplane = DataPlane( - model_registry=ModelRepository(), - predictor_config=PredictorConfig( - predictor_host=predictor_host, - predictor_protocol=PredictorProtocol.REST_V1.value, - predictor_request_retries=2, - predictor_request_timeout_seconds=5, - predictor_health_check=True, - ), + predictor_config = PredictorConfig( + predictor_host=predictor_host, + predictor_protocol=PredictorProtocol.REST_V1.value, + predictor_request_retries=2, + predictor_request_timeout_seconds=5, + predictor_health_check=True, ) + kserve_context.set_predictor_config(predictor_config) + dataplane = DataPlane(model_registry=ModelRepository()) # Transformer model is not ready not_ready_model = DummyModel("NotReadyModel") dataplane._model_registry.update(not_ready_model) @@ -691,16 +682,15 @@ async def test_model_readiness_v2(self, httpx_mock): # scenario: getting a 2xx response from predictor predictor_host = "ready.host" httpx_mock.add_response(url=re.compile(f"http://{predictor_host}/v2/*")) - dataplane = DataPlane( - model_registry=ModelRepository(), - predictor_config=PredictorConfig( - predictor_host=predictor_host, - predictor_protocol=PredictorProtocol.REST_V2.value, - predictor_request_retries=2, - predictor_request_timeout_seconds=5, - predictor_health_check=True, - ), - ) + predictor_config = PredictorConfig( + predictor_host=predictor_host, + predictor_protocol=PredictorProtocol.REST_V2.value, + predictor_request_retries=2, + predictor_request_timeout_seconds=5, + predictor_health_check=True, + ) + kserve_context.set_predictor_config(predictor_config) + dataplane = DataPlane(model_registry=ModelRepository()) # Transformer model ready ready_model = DummyModel("ReadyModel") dataplane._model_registry.update(ready_model) @@ -712,16 +702,15 @@ async def test_model_readiness_v2(self, httpx_mock): httpx_mock.add_response( url=re.compile(f"http://{predictor_host}/v2/*"), status_code=400 ) - dataplane = DataPlane( - model_registry=ModelRepository(), - predictor_config=PredictorConfig( - predictor_host=predictor_host, - predictor_protocol=PredictorProtocol.REST_V2.value, - predictor_request_retries=2, - predictor_request_timeout_seconds=5, - predictor_health_check=True, - ), + predictor_config = PredictorConfig( + predictor_host=predictor_host, + predictor_protocol=PredictorProtocol.REST_V2.value, + predictor_request_retries=2, + predictor_request_timeout_seconds=5, + predictor_health_check=True, ) + kserve_context.set_predictor_config(predictor_config) + dataplane = DataPlane(model_registry=ModelRepository()) # Transformer model ready not_ready_model = DummyModel("NotReadyModel") dataplane._model_registry.update(not_ready_model) @@ -735,16 +724,15 @@ async def test_model_readiness_v2(self, httpx_mock): httpx_mock.add_response( url=re.compile(f"http://{predictor_host}/v2/*"), status_code=503 ) - dataplane = DataPlane( - model_registry=ModelRepository(), - predictor_config=PredictorConfig( - predictor_host=predictor_host, - predictor_protocol=PredictorProtocol.REST_V2.value, - predictor_request_retries=2, - predictor_request_timeout_seconds=5, - predictor_health_check=True, - ), + predictor_config = PredictorConfig( + predictor_host=predictor_host, + predictor_protocol=PredictorProtocol.REST_V2.value, + predictor_request_retries=2, + predictor_request_timeout_seconds=5, + predictor_health_check=True, ) + kserve_context.set_predictor_config(predictor_config) + dataplane = DataPlane(model_registry=ModelRepository()) # Transformer model is not ready not_ready_model = DummyModel("NotReadyModel") dataplane._model_registry.update(not_ready_model) @@ -752,16 +740,15 @@ async def test_model_readiness_v2(self, httpx_mock): # Connection error predictor_host = "not-reachable.host" - dataplane = DataPlane( - model_registry=ModelRepository(), - predictor_config=PredictorConfig( - predictor_host=predictor_host, - predictor_protocol=PredictorProtocol.REST_V2.value, - predictor_request_retries=2, - predictor_request_timeout_seconds=5, - predictor_health_check=True, - ), - ) + predictor_config = PredictorConfig( + predictor_host=predictor_host, + predictor_protocol=PredictorProtocol.REST_V2.value, + predictor_request_retries=2, + predictor_request_timeout_seconds=5, + predictor_health_check=True, + ) + kserve_context.set_predictor_config(predictor_config) + dataplane = DataPlane(model_registry=ModelRepository()) # Transformer model is not ready not_ready_model = DummyModel("NotReadyModel") dataplane._model_registry.update(not_ready_model) @@ -775,16 +762,15 @@ async def test_model_readiness_v2(self, httpx_mock): async def test_model_readiness_grpc_v2(self, mock_grpc_client): # scenario: getting a 2xx response from predictor predictor_host = "ready.host" - dataplane = DataPlane( - model_registry=ModelRepository(), - predictor_config=PredictorConfig( - predictor_host=predictor_host, - predictor_protocol=PredictorProtocol.GRPC_V2.value, - predictor_request_retries=2, - predictor_request_timeout_seconds=5, - predictor_health_check=True, - ), - ) + predictor_config = PredictorConfig( + predictor_host=predictor_host, + predictor_protocol=PredictorProtocol.GRPC_V2.value, + predictor_request_retries=2, + predictor_request_timeout_seconds=5, + predictor_health_check=True, + ) + kserve_context.set_predictor_config(predictor_config) + dataplane = DataPlane(model_registry=ModelRepository()) # Transformer model ready ready_model = DummyModel("ReadyModel") dataplane._model_registry.update(ready_model) @@ -797,16 +783,15 @@ async def test_model_readiness_grpc_v2(self, mock_grpc_client): # scenario: getting a 2xx response from predictor and server not ready predictor_host = "not-ready.host" - dataplane = DataPlane( - model_registry=ModelRepository(), - predictor_config=PredictorConfig( - predictor_host=predictor_host, - predictor_protocol=PredictorProtocol.GRPC_V2.value, - predictor_request_retries=2, - predictor_request_timeout_seconds=5, - predictor_health_check=True, - ), - ) + predictor_config = PredictorConfig( + predictor_host=predictor_host, + predictor_protocol=PredictorProtocol.GRPC_V2.value, + predictor_request_retries=2, + predictor_request_timeout_seconds=5, + predictor_health_check=True, + ) + kserve_context.set_predictor_config(predictor_config) + dataplane = DataPlane(model_registry=ModelRepository()) # Transformer model is not ready not_ready_model = DummyModel("NotReadyModel") dataplane._model_registry.update(not_ready_model) @@ -819,16 +804,15 @@ async def test_model_readiness_grpc_v2(self, mock_grpc_client): # Connection error predictor_host = "not-reachable.host" - dataplane = DataPlane( - model_registry=ModelRepository(), - predictor_config=PredictorConfig( - predictor_host=predictor_host, - predictor_protocol=PredictorProtocol.GRPC_V2.value, - predictor_request_retries=2, - predictor_request_timeout_seconds=5, - predictor_health_check=True, - ), - ) + predictor_config = PredictorConfig( + predictor_host=predictor_host, + predictor_protocol=PredictorProtocol.GRPC_V2.value, + predictor_request_retries=2, + predictor_request_timeout_seconds=5, + predictor_health_check=True, + ) + kserve_context.set_predictor_config(predictor_config) + dataplane = DataPlane(model_registry=ModelRepository()) dataplane._model_registry.update(ready_model) mock_grpc_client.side_effect = grpc.RpcError("Mocked exception") assert (await dataplane.model_ready(ready_model.name)) is False @@ -840,26 +824,24 @@ async def test_dataplane_with_predictor_health_check_false( ): # Inference client should not be created when predictor_health_check is False predictor_host = "ready.host" - _ = DataPlane( - model_registry=ModelRepository(), - predictor_config=PredictorConfig( - predictor_host=predictor_host, - predictor_protocol=PredictorProtocol.GRPC_V2.value, - predictor_request_retries=2, - predictor_request_timeout_seconds=5, - predictor_health_check=False, - ), - ) + predictor_config = PredictorConfig( + predictor_host=predictor_host, + predictor_protocol=PredictorProtocol.GRPC_V2.value, + predictor_request_retries=2, + predictor_request_timeout_seconds=5, + predictor_health_check=False, + ) + kserve_context.set_predictor_config(predictor_config) + _ = DataPlane(model_registry=ModelRepository()) mock_grpc_client.assert_not_called() - _ = DataPlane( - model_registry=ModelRepository(), - predictor_config=PredictorConfig( - predictor_host=predictor_host, - predictor_protocol=PredictorProtocol.REST_V2.value, - predictor_request_retries=2, - predictor_request_timeout_seconds=5, - predictor_health_check=False, - ), + predictor_config = PredictorConfig( + predictor_host=predictor_host, + predictor_protocol=PredictorProtocol.REST_V2.value, + predictor_request_retries=2, + predictor_request_timeout_seconds=5, + predictor_health_check=False, ) + kserve_context.set_predictor_config(predictor_config) + _ = DataPlane(model_registry=ModelRepository()) mock_rest_client.assert_not_called() diff --git a/python/kserve/test/test_server.py b/python/kserve/test/test_server.py index 82b38838a24..45521c45c4b 100644 --- a/python/kserve/test/test_server.py +++ b/python/kserve/test/test_server.py @@ -24,9 +24,6 @@ import avro.io import avro.schema import httpx -from kserve.protocol.dataplane import DataPlane -from kserve.protocol.model_repository_extension import ModelRepositoryExtension -from kserve.protocol.rest.multiprocess.server import RESTServerMultiProcess import numpy as np import pandas as pd import pytest @@ -53,6 +50,11 @@ RequestedOutput, ) from kserve.utils.utils import generate_uuid, get_predict_input, get_predict_response +from kserve.protocol.dataplane import DataPlane +from kserve.protocol.model_repository_extension import ModelRepositoryExtension +from kserve.protocol.rest.multiprocess.server import RESTServerMultiProcess +from kserve.predictor_config import PredictorConfig +from kserve import context as kserve_context test_avsc_schema = """ { @@ -376,6 +378,14 @@ def http_server_client(): class TestModel: async def test_validate(self): model = DummyModel("TestModel") + + # Test REST_V1 protocol validation + predictor_config_v1 = PredictorConfig( + predictor_host="localhost", + predictor_protocol=PredictorProtocol.REST_V1.value, + ) + kserve_context.set_predictor_config(predictor_config_v1) + good_request = {"instances": []} validated_request = model.validate(good_request) assert validated_request == good_request @@ -383,7 +393,13 @@ async def test_validate(self): with pytest.raises(InvalidInput): model.validate(bad_request) - model.protocol = PredictorProtocol.REST_V2.value + # Test REST_V2 protocol validation + predictor_config_v2 = PredictorConfig( + predictor_host="localhost", + predictor_protocol=PredictorProtocol.REST_V2.value, + ) + kserve_context.set_predictor_config(predictor_config_v2) + good_request = {"inputs": []} validated_request = model.validate(good_request) assert validated_request == good_request @@ -1300,3 +1316,99 @@ async def test_rest_server_multiprocess(self): await server.stop() await asyncio.sleep(5) task.cancel() + + +@pytest.mark.asyncio +class TestModelServerWithPredictorConfig: + """Test ModelServer initialization and functionality with PredictorConfig.""" + + async def test_model_server_with_predictor_config(self): + """Test that ModelServer properly sets PredictorConfig in the global context.""" + # Create a PredictorConfig + predictor_config = PredictorConfig( + predictor_host="test-predictor.example.com", + predictor_protocol=PredictorProtocol.REST_V1.value, + predictor_request_retries=3, + predictor_request_timeout_seconds=10, + predictor_health_check=True, + predictor_use_ssl=False, + ) + + # Create ModelServer with PredictorConfig + model_repository = ModelRepository() + model_server = ModelServer( + registered_models=model_repository, predictor_config=predictor_config + ) + + # Verify that the predictor config was set in the global context + context_config = kserve_context.get_predictor_config() + assert context_config is not None + assert context_config.predictor_host == "test-predictor.example.com" + assert context_config.predictor_protocol == PredictorProtocol.REST_V1.value + assert context_config.predictor_request_retries == 3 + assert context_config.predictor_request_timeout_seconds == 10 + assert context_config.predictor_health_check is True + assert context_config.predictor_use_ssl is False + + # Verify that the DataPlane can access the config from context + dataplane = model_server.dataplane + assert dataplane is not None + + # Test with None predictor_config (should not fail) + model_server_no_config = ModelServer( + registered_models=ModelRepository(), predictor_config=None + ) + assert model_server_no_config.dataplane is not None + + async def test_model_server_dataplane_with_predictor_config(self): + """Test that the DataPlane created by ModelServer uses the PredictorConfig from context.""" + # Create a PredictorConfig with specific settings + predictor_config = PredictorConfig( + predictor_host="grpc-predictor.example.com", + predictor_protocol=PredictorProtocol.GRPC_V2.value, + predictor_request_retries=5, + predictor_request_timeout_seconds=30, + predictor_health_check=False, # Disabled to avoid network calls in test + predictor_use_ssl=True, + ) + + # Create ModelServer with the config + model_repository = ModelRepository() + dummy_model = DummyModel("TestModel") + dummy_model.load() + model_repository.update(dummy_model) + + model_server = ModelServer( + registered_models=model_repository, predictor_config=predictor_config + ) + + # Verify the DataPlane was created and can access the config + dataplane = model_server.dataplane + assert dataplane is not None + + # Verify the context has the correct config + context_config = kserve_context.get_predictor_config() + assert context_config.predictor_host == "grpc-predictor.example.com" + assert context_config.predictor_protocol == PredictorProtocol.GRPC_V2.value + assert context_config.predictor_use_ssl is True + + # Test that model operations work + assert await dataplane.model_ready("TestModel") is True + + # Test inference (should work even with predictor config since health_check is disabled) + body = b'{"instances":[[1,2]]}' + infer_request, req_attributes = dataplane.decode(body, None) + resp, headers = await dataplane.infer("TestModel", infer_request) + assert resp is not None + + def test_model_server_backwards_compatibility(self): + """Test that ModelServer works without PredictorConfig for backwards compatibility.""" + # Create ModelServer without predictor_config (should work) + model_repository = ModelRepository() + model_server = ModelServer(registered_models=model_repository) + + # Should create DataPlane successfully + assert model_server.dataplane is not None + + # Context should handle None predictor config gracefully + # The DataPlane should still be functional even without predictor config From d3e5e211a81eadb1ff0c628dae3f1ade546310a6 Mon Sep 17 00:00:00 2001 From: Tamir Ohana <90143687+takamai06@users.noreply.github.com> Date: Sun, 29 Jun 2025 04:34:53 +0300 Subject: [PATCH 3/9] feat: refactor storage initializer resources configuration (#4411) Signed-off-by: tohana Co-authored-by: Sivanantham <90966311+sivanantha321@users.noreply.github.com> --- charts/kserve-resources/README.md | 4 ++++ .../templates/clusterstoragecontainer.yaml | 9 +++------ charts/kserve-resources/values.yaml | 8 +++++++- 3 files changed, 14 insertions(+), 7 deletions(-) diff --git a/charts/kserve-resources/README.md b/charts/kserve-resources/README.md index c9df5b1691f..7f2035f90f4 100644 --- a/charts/kserve-resources/README.md +++ b/charts/kserve-resources/README.md @@ -202,6 +202,10 @@ $ helm install kserve oci://ghcr.io/kserve/charts/kserve --version v0.15.2 | kserve.storage.enableModelcar | bool | `true` | Flag for enabling model sidecar feature. | | kserve.storage.image | string | `"kserve/storage-initializer"` | | | kserve.storage.memoryModelcar | string | `"15Mi"` | Model sidecar memory requirement. | +| kserve.storage.resources.limits.cpu | string | `"1"` | | +| kserve.storage.resources.limits.memory | string | `"1Gi"` | | +| kserve.storage.resources.requests.cpu | string | `"100m"` | | +| kserve.storage.resources.requests.memory | string | `"100Mi"` | | | kserve.storage.s3 | object | `{"CABundle":"","accessKeyIdName":"AWS_ACCESS_KEY_ID","endpoint":"","region":"","secretAccessKeyName":"AWS_SECRET_ACCESS_KEY","useAnonymousCredential":"","useHttps":"","useVirtualBucket":"","verifySSL":""}` | Configurations for S3 storage | | kserve.storage.s3.CABundle | string | `""` | The path to the certificate bundle to use for HTTPS certificate validation. | | kserve.storage.s3.accessKeyIdName | string | `"AWS_ACCESS_KEY_ID"` | AWS S3 static access key id. | diff --git a/charts/kserve-resources/templates/clusterstoragecontainer.yaml b/charts/kserve-resources/templates/clusterstoragecontainer.yaml index 2aa54468b08..121a765bf63 100644 --- a/charts/kserve-resources/templates/clusterstoragecontainer.yaml +++ b/charts/kserve-resources/templates/clusterstoragecontainer.yaml @@ -7,12 +7,9 @@ spec: name: storage-initializer image: "{{ .Values.kserve.storage.image }}:{{ .Values.kserve.storage.tag }}" resources: - requests: - memory: 100Mi - cpu: 100m - limits: - memory: 1Gi - cpu: "1" + {{- with .Values.kserve.storage.resources }} + {{- toYaml . | nindent 6 }} + {{- end }} securityContext: {{- with .Values.kserve.storage.containerSecurityContext}} {{- toYaml . | nindent 6 }} diff --git a/charts/kserve-resources/values.yaml b/charts/kserve-resources/values.yaml index 17e898e9a43..86f28367c79 100644 --- a/charts/kserve-resources/values.yaml +++ b/charts/kserve-resources/values.yaml @@ -15,7 +15,13 @@ kserve: storage: image: kserve/storage-initializer tag: *defaultVersion - + resources: + requests: + memory: 100Mi + cpu: 100m + limits: + memory: 1Gi + cpu: "1" # security context for the default storage container containerSecurityContext: allowPrivilegeEscalation: false From 5809a9e5b90b84fd44e953e0483879b9eeb29bda Mon Sep 17 00:00:00 2001 From: Bartosz Majsak Date: Wed, 2 Jul 2025 08:15:05 +0200 Subject: [PATCH 4/9] feat(envtest): simplifies CRD lookup (#4564) Signed-off-by: Bartosz Majsak --- .../v1alpha1/inferencegraph/suite_test.go | 2 +- .../v1alpha1/localmodel/suite_test.go | 2 +- .../v1alpha1/localmodelnode/suite_test.go | 2 +- .../v1alpha1/trainedmodel/suite_test.go | 2 +- .../v1beta1/inferenceservice/suite_test.go | 2 +- pkg/credentials/credentials_suite_test.go | 2 +- pkg/testing/envtest_setup.go | 22 +------- pkg/testing/utils.go | 53 +++++++++++++++++++ pkg/webhook/admission/pod/suite_test.go | 2 +- 9 files changed, 62 insertions(+), 27 deletions(-) create mode 100644 pkg/testing/utils.go diff --git a/pkg/controller/v1alpha1/inferencegraph/suite_test.go b/pkg/controller/v1alpha1/inferencegraph/suite_test.go index 1f132fbd0c0..20dccdfbb36 100644 --- a/pkg/controller/v1alpha1/inferencegraph/suite_test.go +++ b/pkg/controller/v1alpha1/inferencegraph/suite_test.go @@ -60,7 +60,7 @@ var _ = BeforeSuite(func() { ctx, cancel := context.WithCancel(context.Background()) By("bootstrapping test environment") crdDirectoryPaths := []string{ - filepath.Join("..", "..", "..", "..", "test", "crds"), + filepath.Join(pkgtest.ProjectRoot(), "test", "crds"), } testEnv := pkgtest.SetupEnvTest(crdDirectoryPaths) var err error diff --git a/pkg/controller/v1alpha1/localmodel/suite_test.go b/pkg/controller/v1alpha1/localmodel/suite_test.go index 485ec46adb2..b92b79cfb11 100644 --- a/pkg/controller/v1alpha1/localmodel/suite_test.go +++ b/pkg/controller/v1alpha1/localmodel/suite_test.go @@ -56,7 +56,7 @@ var _ = BeforeSuite(func() { logf.SetLogger(zap.New(zap.WriteTo(GinkgoWriter), zap.UseDevMode(true))) By("bootstrapping test environment") crdDirectoryPaths := []string{ - filepath.Join("..", "..", "..", "..", "test", "crds"), + filepath.Join(pkgtest.ProjectRoot(), "test", "crds"), } testEnv := pkgtest.SetupEnvTest(crdDirectoryPaths) var err error diff --git a/pkg/controller/v1alpha1/localmodelnode/suite_test.go b/pkg/controller/v1alpha1/localmodelnode/suite_test.go index 8782481336e..be56a911d7d 100644 --- a/pkg/controller/v1alpha1/localmodelnode/suite_test.go +++ b/pkg/controller/v1alpha1/localmodelnode/suite_test.go @@ -61,7 +61,7 @@ var _ = BeforeSuite(func() { ctx, cancel := context.WithCancel(context.TODO()) By("bootstrapping test environment") crdDirectoryPaths := []string{ - filepath.Join("..", "..", "..", "..", "test", "crds"), + filepath.Join(pkgtest.ProjectRoot(), "test", "crds"), } testEnv := pkgtest.SetupEnvTest(crdDirectoryPaths) var err error diff --git a/pkg/controller/v1alpha1/trainedmodel/suite_test.go b/pkg/controller/v1alpha1/trainedmodel/suite_test.go index 48d7729ecf3..cae40f2b017 100644 --- a/pkg/controller/v1alpha1/trainedmodel/suite_test.go +++ b/pkg/controller/v1alpha1/trainedmodel/suite_test.go @@ -65,7 +65,7 @@ var _ = BeforeSuite(func() { ctx, cancel := context.WithCancel(context.TODO()) By("bootstrapping test environment") crdDirectoryPaths := []string{ - filepath.Join("..", "..", "..", "..", "test", "crds"), + filepath.Join(pkgtest.ProjectRoot(), "test", "crds"), } testEnv := pkgtest.SetupEnvTest(crdDirectoryPaths) var err error diff --git a/pkg/controller/v1beta1/inferenceservice/suite_test.go b/pkg/controller/v1beta1/inferenceservice/suite_test.go index bf3293ddf48..cd83604fd92 100644 --- a/pkg/controller/v1beta1/inferenceservice/suite_test.go +++ b/pkg/controller/v1beta1/inferenceservice/suite_test.go @@ -63,7 +63,7 @@ var _ = BeforeSuite(func() { ctx, cancel := context.WithCancel(context.TODO()) By("bootstrapping test environment") crdDirectoryPaths := []string{ - filepath.Join("..", "..", "..", "..", "test", "crds"), + filepath.Join(pkgtest.ProjectRoot(), "test", "crds"), } testEnv := pkgtest.SetupEnvTest(crdDirectoryPaths) var err error diff --git a/pkg/credentials/credentials_suite_test.go b/pkg/credentials/credentials_suite_test.go index 103fbe06a38..e8665df2f2c 100644 --- a/pkg/credentials/credentials_suite_test.go +++ b/pkg/credentials/credentials_suite_test.go @@ -37,7 +37,7 @@ var ( func TestMain(m *testing.M) { crdDirectoryPaths := []string{ - filepath.Join("..", "..", "test", "crds"), + filepath.Join(pkgtest.ProjectRoot(), "test", "crds"), } t := pkgtest.SetupEnvTest(crdDirectoryPaths) var err error diff --git a/pkg/testing/envtest_setup.go b/pkg/testing/envtest_setup.go index acd696a84ae..9a315aedf36 100644 --- a/pkg/testing/envtest_setup.go +++ b/pkg/testing/envtest_setup.go @@ -17,21 +17,16 @@ limitations under the License. package testing import ( - "context" - "sync" - "google.golang.org/protobuf/proto" istioclientv1beta1 "istio.io/client-go/pkg/apis/networking/v1beta1" netv1 "k8s.io/api/networking/v1" kedav1alpha1 "github.com/kedacore/keda/v2/apis/keda/v1alpha1" - "github.com/onsi/gomega" otelv1beta1 "github.com/open-telemetry/opentelemetry-operator/apis/v1beta1" "k8s.io/client-go/kubernetes/scheme" knservingv1 "knative.dev/serving/pkg/apis/serving/v1" "sigs.k8s.io/controller-runtime/pkg/envtest" logf "sigs.k8s.io/controller-runtime/pkg/log" - "sigs.k8s.io/controller-runtime/pkg/manager" gwapiv1 "sigs.k8s.io/gateway-api/apis/v1" ) @@ -40,10 +35,8 @@ var log = logf.Log.WithName("TestingEnvSetup") func SetupEnvTest(crdDirectoryPaths []string) *envtest.Environment { t := &envtest.Environment{ ErrorIfCRDPathMissing: true, - // The relative paths must be provided for each level of test nesting - // This code should be illegal - CRDDirectoryPaths: crdDirectoryPaths, - UseExistingCluster: proto.Bool(false), + CRDDirectoryPaths: crdDirectoryPaths, + UseExistingCluster: proto.Bool(false), } if err := netv1.SchemeBuilder.AddToScheme(scheme.Scheme); err != nil { @@ -69,14 +62,3 @@ func SetupEnvTest(crdDirectoryPaths []string) *envtest.Environment { } return t } - -// StartTestManager adds recFn -func StartTestManager(ctx context.Context, mgr manager.Manager, g *gomega.GomegaWithT) *sync.WaitGroup { - wg := &sync.WaitGroup{} - wg.Add(1) - go func() { - defer wg.Done() - g.Expect(mgr.Start(ctx)).NotTo(gomega.HaveOccurred()) - }() - return wg -} diff --git a/pkg/testing/utils.go b/pkg/testing/utils.go new file mode 100644 index 00000000000..be18d9f01b8 --- /dev/null +++ b/pkg/testing/utils.go @@ -0,0 +1,53 @@ +/* +Copyright 2025 The KServe Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package testing + +import ( + "fmt" + "os" + "path/filepath" +) + +// ProjectRoot returns the root directory of the project by searching for the go.mod file up from where it is called. +func ProjectRoot() string { + rootDir := "" + + currentDir, errCurrDir := os.Getwd() + if errCurrDir != nil { + panic(fmt.Sprintf("failed to get current working directory: %v", errCurrDir)) + } + + for { + if _, err := os.Stat(filepath.Join(currentDir, "go.mod")); err == nil { + rootDir = filepath.FromSlash(currentDir) + break + } + + parentDir := filepath.Dir(currentDir) + if parentDir == currentDir { + break + } + + currentDir = parentDir + } + + if rootDir == "" { + panic("failed to get project root directory. no go.mod file found") + } + + return rootDir +} diff --git a/pkg/webhook/admission/pod/suite_test.go b/pkg/webhook/admission/pod/suite_test.go index 6ac01a1bff4..e2e10404370 100644 --- a/pkg/webhook/admission/pod/suite_test.go +++ b/pkg/webhook/admission/pod/suite_test.go @@ -39,7 +39,7 @@ var ( func TestMain(m *testing.M) { crdDirectoryPaths := []string{ - filepath.Join("..", "..", "..", "..", "test", "crds"), + filepath.Join(pkgtest.ProjectRoot(), "test", "crds"), } t := pkgtest.SetupEnvTest(crdDirectoryPaths) From 7c590aba6de9274d07323e83303d6ae77c94d100 Mon Sep 17 00:00:00 2001 From: Sivanantham <90966311+sivanantha321@users.noreply.github.com> Date: Thu, 3 Jul 2025 13:32:56 +0530 Subject: [PATCH 5/9] llmisvc: Initial controller scaffold and helm chart (#4557) Signed-off-by: Sivanantham Chinnaiyan --- Makefile | 8 + charts/llmisvc-crd/Chart.yaml | 21 + charts/llmisvc-crd/README.md | 13 + charts/llmisvc-crd/README.md.gotmpl | 12 + ....kserve.io_llminferenceserviceconfigs.yaml | 19546 +++++++++++++++ ...erving.kserve.io_llminferenceservices.yaml | 19623 ++++++++++++++++ charts/llmisvc-crd/values.yaml | 0 charts/llmisvc-resources/Chart.yaml | 23 + charts/llmisvc-resources/README.md | 54 + charts/llmisvc-resources/README.md.gotmpl | 16 + .../llmisvc-resources/templates/_helpers.tpl | 88 + .../templates/clusterrole.yaml | 27 + .../templates/deployment.yaml | 153 + .../llmisvc-resources/templates/service.yaml | 32 + .../templates/serviceaccount.yaml | 17 + charts/llmisvc-resources/values.schema.json | 99 + charts/llmisvc-resources/values.yaml | 200 + cmd/llmisvc/main.go | 159 + config/rbac/llmisvc/role.yaml | 27 + go.mod | 11 + go.sum | 22 + llmisvc-controller.Dockerfile | 28 + pkg/controller/v1alpha1/llmisvc/controller.go | 52 + 23 files changed, 40231 insertions(+) create mode 100644 charts/llmisvc-crd/Chart.yaml create mode 100644 charts/llmisvc-crd/README.md create mode 100644 charts/llmisvc-crd/README.md.gotmpl create mode 100644 charts/llmisvc-crd/templates/serving.kserve.io_llminferenceserviceconfigs.yaml create mode 100644 charts/llmisvc-crd/templates/serving.kserve.io_llminferenceservices.yaml create mode 100644 charts/llmisvc-crd/values.yaml create mode 100644 charts/llmisvc-resources/Chart.yaml create mode 100644 charts/llmisvc-resources/README.md create mode 100644 charts/llmisvc-resources/README.md.gotmpl create mode 100644 charts/llmisvc-resources/templates/_helpers.tpl create mode 100644 charts/llmisvc-resources/templates/clusterrole.yaml create mode 100644 charts/llmisvc-resources/templates/deployment.yaml create mode 100644 charts/llmisvc-resources/templates/service.yaml create mode 100644 charts/llmisvc-resources/templates/serviceaccount.yaml create mode 100644 charts/llmisvc-resources/values.schema.json create mode 100644 charts/llmisvc-resources/values.yaml create mode 100644 cmd/llmisvc/main.go create mode 100644 config/rbac/llmisvc/role.yaml create mode 100644 llmisvc-controller.Dockerfile create mode 100644 pkg/controller/v1alpha1/llmisvc/controller.go diff --git a/Makefile b/Makefile index 930ae2d2938..0a93ed70aa6 100644 --- a/Makefile +++ b/Makefile @@ -116,6 +116,14 @@ manifests: controller-gen yq # Copy the minimal crd to the helm chart cp config/crd/minimal/* charts/kserve-crd-minimal/templates/ rm charts/kserve-crd-minimal/templates/kustomization.yaml + + # Generate llmisvc rbac + @$(CONTROLLER_GEN) rbac:roleName=llmisvc-manager-role paths={./pkg/controller/v1alpha1/llmisvc} output:rbac:artifacts:config=config/rbac/llmisvc + # Copy the cluster role to the helm chart + cat config/rbac/llmisvc/role.yaml > charts/llmisvc-resources/templates/clusterrole.yaml + # Copy llmisvc crd + cp config/crd/full/serving.kserve.io_llminferenceservices.yaml charts/llmisvc-crd/templates/ + cp config/crd/full/serving.kserve.io_llminferenceserviceconfigs.yaml charts/llmisvc-crd/templates/ # Generate code generate: controller-gen helm-docs diff --git a/charts/llmisvc-crd/Chart.yaml b/charts/llmisvc-crd/Chart.yaml new file mode 100644 index 00000000000..08ed84e365d --- /dev/null +++ b/charts/llmisvc-crd/Chart.yaml @@ -0,0 +1,21 @@ +apiVersion: v1 +name: llmisvc-crd +version: v0.15.2 +description: Helm chart for deploying LLMInferenceService crds +keywords: + - kserve + - llm + - llm-d + - inference + - generative-ai + - machine-learning + - model-serving +home: https://kserve.github.io/website/ +sources: + - https://github.com/kserve/kserve +maintainers: + - name: KServe Team + url: https://github.com/kserve/kserve +icon: https://raw.githubusercontent.com/kserve/website/main/docs/images/logo.png +annotations: + category: AI/Machine Learning diff --git a/charts/llmisvc-crd/README.md b/charts/llmisvc-crd/README.md new file mode 100644 index 00000000000..f2998f6ce5a --- /dev/null +++ b/charts/llmisvc-crd/README.md @@ -0,0 +1,13 @@ +# llmisvc-crd + +Helm chart for deploying LLMInferenceService crds + +![Version: v0.15.2](https://img.shields.io/badge/Version-v0.15.2-informational?style=flat-square) + +## Installing the Chart + +To install the chart, run the following: + +```console +$ helm install llmisvc-crd oci://ghcr.io/kserve/charts/llmisvc-crd --version v0.15.2 +``` diff --git a/charts/llmisvc-crd/README.md.gotmpl b/charts/llmisvc-crd/README.md.gotmpl new file mode 100644 index 00000000000..c85b4e9f7f2 --- /dev/null +++ b/charts/llmisvc-crd/README.md.gotmpl @@ -0,0 +1,12 @@ +{{ template "chart.header" . }} +{{ template "chart.description" . }} + +{{ template "chart.versionBadge" . }}{{ template "chart.typeBadge" . }}{{ template "chart.appVersionBadge" . }} + +## Installing the Chart + +To install the chart, run the following: + +```console +$ helm install llmisvc-crd oci://ghcr.io/kserve/charts/llmisvc-crd --version {{ template "chart.version" . }} +``` diff --git a/charts/llmisvc-crd/templates/serving.kserve.io_llminferenceserviceconfigs.yaml b/charts/llmisvc-crd/templates/serving.kserve.io_llminferenceserviceconfigs.yaml new file mode 100644 index 00000000000..4122b60eced --- /dev/null +++ b/charts/llmisvc-crd/templates/serving.kserve.io_llminferenceserviceconfigs.yaml @@ -0,0 +1,19546 @@ +--- +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + annotations: + controller-gen.kubebuilder.io/version: v0.16.2 + name: llminferenceserviceconfigs.serving.kserve.io +spec: + group: serving.kserve.io + names: + kind: LLMInferenceServiceConfig + listKind: LLMInferenceServiceConfigList + plural: llminferenceserviceconfigs + singular: llminferenceserviceconfig + scope: Namespaced + versions: + - name: v1alpha1 + schema: + openAPIV3Schema: + properties: + apiVersion: + type: string + kind: + type: string + metadata: + type: object + spec: + properties: + baseRefs: + items: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + type: array + model: + properties: + criticality: + enum: + - Critical + - Standard + - Sheddable + type: string + lora: + properties: + adapters: + items: + properties: + framework: + type: string + memory: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + storageUri: + type: string + required: + - framework + - memory + - storageUri + type: object + type: array + type: object + name: + type: string + storage: + properties: + key: + type: string + parameters: + additionalProperties: + type: string + type: object + path: + type: string + type: object + uri: + type: string + required: + - uri + type: object + parallelism: + properties: + pipeline: + format: int64 + type: integer + tensor: + format: int64 + type: integer + type: object + prefill: + properties: + parallelism: + properties: + pipeline: + format: int64 + type: integer + tensor: + format: int64 + type: integer + type: object + replicas: + format: int32 + type: integer + template: + properties: + activeDeadlineSeconds: + format: int64 + type: integer + affinity: + properties: + nodeAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + preference: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + weight: + format: int32 + type: integer + required: + - preference + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + properties: + nodeSelectorTerms: + items: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + type: array + x-kubernetes-list-type: atomic + required: + - nodeSelectorTerms + type: object + x-kubernetes-map-type: atomic + type: object + podAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + podAntiAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + type: object + automountServiceAccountToken: + type: boolean + containers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + dnsConfig: + properties: + nameservers: + items: + type: string + type: array + x-kubernetes-list-type: atomic + options: + items: + properties: + name: + type: string + value: + type: string + type: object + type: array + x-kubernetes-list-type: atomic + searches: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + dnsPolicy: + type: string + enableServiceLinks: + type: boolean + ephemeralContainers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + targetContainerName: + type: string + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + hostAliases: + items: + properties: + hostnames: + items: + type: string + type: array + x-kubernetes-list-type: atomic + ip: + type: string + required: + - ip + type: object + type: array + x-kubernetes-list-map-keys: + - ip + x-kubernetes-list-type: map + hostIPC: + type: boolean + hostNetwork: + type: boolean + hostPID: + type: boolean + hostUsers: + type: boolean + hostname: + type: string + imagePullSecrets: + items: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + initContainers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + nodeName: + type: string + nodeSelector: + additionalProperties: + type: string + type: object + x-kubernetes-map-type: atomic + os: + properties: + name: + type: string + required: + - name + type: object + overhead: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + preemptionPolicy: + type: string + priority: + format: int32 + type: integer + priorityClassName: + type: string + readinessGates: + items: + properties: + conditionType: + type: string + required: + - conditionType + type: object + type: array + x-kubernetes-list-type: atomic + resourceClaims: + items: + properties: + name: + type: string + resourceClaimName: + type: string + resourceClaimTemplateName: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + runtimeClassName: + type: string + schedulerName: + type: string + schedulingGates: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + securityContext: + properties: + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + fsGroup: + format: int64 + type: integer + fsGroupChangePolicy: + type: string + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxChangePolicy: + type: string + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + supplementalGroups: + items: + format: int64 + type: integer + type: array + x-kubernetes-list-type: atomic + supplementalGroupsPolicy: + type: string + sysctls: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + serviceAccount: + type: string + serviceAccountName: + type: string + setHostnameAsFQDN: + type: boolean + shareProcessNamespace: + type: boolean + subdomain: + type: string + terminationGracePeriodSeconds: + format: int64 + type: integer + tolerations: + items: + properties: + effect: + type: string + key: + type: string + operator: + type: string + tolerationSeconds: + format: int64 + type: integer + value: + type: string + type: object + type: array + x-kubernetes-list-type: atomic + topologySpreadConstraints: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + maxSkew: + format: int32 + type: integer + minDomains: + format: int32 + type: integer + nodeAffinityPolicy: + type: string + nodeTaintsPolicy: + type: string + topologyKey: + type: string + whenUnsatisfiable: + type: string + required: + - maxSkew + - topologyKey + - whenUnsatisfiable + type: object + type: array + x-kubernetes-list-map-keys: + - topologyKey + - whenUnsatisfiable + x-kubernetes-list-type: map + volumes: + items: + properties: + awsElasticBlockStore: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + azureDisk: + properties: + cachingMode: + type: string + diskName: + type: string + diskURI: + type: string + fsType: + default: ext4 + type: string + kind: + type: string + readOnly: + default: false + type: boolean + required: + - diskName + - diskURI + type: object + azureFile: + properties: + readOnly: + type: boolean + secretName: + type: string + shareName: + type: string + required: + - secretName + - shareName + type: object + cephfs: + properties: + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + path: + type: string + readOnly: + type: boolean + secretFile: + type: string + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + type: string + required: + - monitors + type: object + cinder: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeID: + type: string + required: + - volumeID + type: object + configMap: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + csi: + properties: + driver: + type: string + fsType: + type: string + nodePublishSecretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + readOnly: + type: boolean + volumeAttributes: + additionalProperties: + type: string + type: object + required: + - driver + type: object + downwardAPI: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + emptyDir: + properties: + medium: + type: string + sizeLimit: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + ephemeral: + properties: + volumeClaimTemplate: + properties: + metadata: + type: object + spec: + properties: + accessModes: + items: + type: string + type: array + x-kubernetes-list-type: atomic + dataSource: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + required: + - kind + - name + type: object + x-kubernetes-map-type: atomic + dataSourceRef: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + namespace: + type: string + required: + - kind + - name + type: object + resources: + properties: + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + selector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + storageClassName: + type: string + volumeAttributesClassName: + type: string + volumeMode: + type: string + volumeName: + type: string + type: object + required: + - spec + type: object + type: object + fc: + properties: + fsType: + type: string + lun: + format: int32 + type: integer + readOnly: + type: boolean + targetWWNs: + items: + type: string + type: array + x-kubernetes-list-type: atomic + wwids: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + flexVolume: + properties: + driver: + type: string + fsType: + type: string + options: + additionalProperties: + type: string + type: object + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + required: + - driver + type: object + flocker: + properties: + datasetName: + type: string + datasetUUID: + type: string + type: object + gcePersistentDisk: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + pdName: + type: string + readOnly: + type: boolean + required: + - pdName + type: object + gitRepo: + properties: + directory: + type: string + repository: + type: string + revision: + type: string + required: + - repository + type: object + glusterfs: + properties: + endpoints: + type: string + path: + type: string + readOnly: + type: boolean + required: + - endpoints + - path + type: object + hostPath: + properties: + path: + type: string + type: + type: string + required: + - path + type: object + image: + properties: + pullPolicy: + type: string + reference: + type: string + type: object + iscsi: + properties: + chapAuthDiscovery: + type: boolean + chapAuthSession: + type: boolean + fsType: + type: string + initiatorName: + type: string + iqn: + type: string + iscsiInterface: + default: default + type: string + lun: + format: int32 + type: integer + portals: + items: + type: string + type: array + x-kubernetes-list-type: atomic + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + targetPortal: + type: string + required: + - iqn + - lun + - targetPortal + type: object + name: + type: string + nfs: + properties: + path: + type: string + readOnly: + type: boolean + server: + type: string + required: + - path + - server + type: object + persistentVolumeClaim: + properties: + claimName: + type: string + readOnly: + type: boolean + required: + - claimName + type: object + photonPersistentDisk: + properties: + fsType: + type: string + pdID: + type: string + required: + - pdID + type: object + portworxVolume: + properties: + fsType: + type: string + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + projected: + properties: + defaultMode: + format: int32 + type: integer + sources: + items: + properties: + clusterTrustBundle: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + name: + type: string + optional: + type: boolean + path: + type: string + signerName: + type: string + required: + - path + type: object + configMap: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + downwardAPI: + properties: + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + secret: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + serviceAccountToken: + properties: + audience: + type: string + expirationSeconds: + format: int64 + type: integer + path: + type: string + required: + - path + type: object + type: object + type: array + x-kubernetes-list-type: atomic + type: object + quobyte: + properties: + group: + type: string + readOnly: + type: boolean + registry: + type: string + tenant: + type: string + user: + type: string + volume: + type: string + required: + - registry + - volume + type: object + rbd: + properties: + fsType: + type: string + image: + type: string + keyring: + default: /etc/ceph/keyring + type: string + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + pool: + default: rbd + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + default: admin + type: string + required: + - image + - monitors + type: object + scaleIO: + properties: + fsType: + default: xfs + type: string + gateway: + type: string + protectionDomain: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + sslEnabled: + type: boolean + storageMode: + default: ThinProvisioned + type: string + storagePool: + type: string + system: + type: string + volumeName: + type: string + required: + - gateway + - secretRef + - system + type: object + secret: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + optional: + type: boolean + secretName: + type: string + type: object + storageos: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeName: + type: string + volumeNamespace: + type: string + type: object + vsphereVolume: + properties: + fsType: + type: string + storagePolicyID: + type: string + storagePolicyName: + type: string + volumePath: + type: string + required: + - volumePath + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + required: + - containers + type: object + worker: + properties: + activeDeadlineSeconds: + format: int64 + type: integer + affinity: + properties: + nodeAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + preference: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + weight: + format: int32 + type: integer + required: + - preference + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + properties: + nodeSelectorTerms: + items: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + type: array + x-kubernetes-list-type: atomic + required: + - nodeSelectorTerms + type: object + x-kubernetes-map-type: atomic + type: object + podAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + podAntiAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + type: object + automountServiceAccountToken: + type: boolean + containers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + dnsConfig: + properties: + nameservers: + items: + type: string + type: array + x-kubernetes-list-type: atomic + options: + items: + properties: + name: + type: string + value: + type: string + type: object + type: array + x-kubernetes-list-type: atomic + searches: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + dnsPolicy: + type: string + enableServiceLinks: + type: boolean + ephemeralContainers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + targetContainerName: + type: string + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + hostAliases: + items: + properties: + hostnames: + items: + type: string + type: array + x-kubernetes-list-type: atomic + ip: + type: string + required: + - ip + type: object + type: array + x-kubernetes-list-map-keys: + - ip + x-kubernetes-list-type: map + hostIPC: + type: boolean + hostNetwork: + type: boolean + hostPID: + type: boolean + hostUsers: + type: boolean + hostname: + type: string + imagePullSecrets: + items: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + initContainers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + nodeName: + type: string + nodeSelector: + additionalProperties: + type: string + type: object + x-kubernetes-map-type: atomic + os: + properties: + name: + type: string + required: + - name + type: object + overhead: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + preemptionPolicy: + type: string + priority: + format: int32 + type: integer + priorityClassName: + type: string + readinessGates: + items: + properties: + conditionType: + type: string + required: + - conditionType + type: object + type: array + x-kubernetes-list-type: atomic + resourceClaims: + items: + properties: + name: + type: string + resourceClaimName: + type: string + resourceClaimTemplateName: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + runtimeClassName: + type: string + schedulerName: + type: string + schedulingGates: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + securityContext: + properties: + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + fsGroup: + format: int64 + type: integer + fsGroupChangePolicy: + type: string + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxChangePolicy: + type: string + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + supplementalGroups: + items: + format: int64 + type: integer + type: array + x-kubernetes-list-type: atomic + supplementalGroupsPolicy: + type: string + sysctls: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + serviceAccount: + type: string + serviceAccountName: + type: string + setHostnameAsFQDN: + type: boolean + shareProcessNamespace: + type: boolean + subdomain: + type: string + terminationGracePeriodSeconds: + format: int64 + type: integer + tolerations: + items: + properties: + effect: + type: string + key: + type: string + operator: + type: string + tolerationSeconds: + format: int64 + type: integer + value: + type: string + type: object + type: array + x-kubernetes-list-type: atomic + topologySpreadConstraints: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + maxSkew: + format: int32 + type: integer + minDomains: + format: int32 + type: integer + nodeAffinityPolicy: + type: string + nodeTaintsPolicy: + type: string + topologyKey: + type: string + whenUnsatisfiable: + type: string + required: + - maxSkew + - topologyKey + - whenUnsatisfiable + type: object + type: array + x-kubernetes-list-map-keys: + - topologyKey + - whenUnsatisfiable + x-kubernetes-list-type: map + volumes: + items: + properties: + awsElasticBlockStore: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + azureDisk: + properties: + cachingMode: + type: string + diskName: + type: string + diskURI: + type: string + fsType: + default: ext4 + type: string + kind: + type: string + readOnly: + default: false + type: boolean + required: + - diskName + - diskURI + type: object + azureFile: + properties: + readOnly: + type: boolean + secretName: + type: string + shareName: + type: string + required: + - secretName + - shareName + type: object + cephfs: + properties: + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + path: + type: string + readOnly: + type: boolean + secretFile: + type: string + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + type: string + required: + - monitors + type: object + cinder: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeID: + type: string + required: + - volumeID + type: object + configMap: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + csi: + properties: + driver: + type: string + fsType: + type: string + nodePublishSecretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + readOnly: + type: boolean + volumeAttributes: + additionalProperties: + type: string + type: object + required: + - driver + type: object + downwardAPI: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + emptyDir: + properties: + medium: + type: string + sizeLimit: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + ephemeral: + properties: + volumeClaimTemplate: + properties: + metadata: + type: object + spec: + properties: + accessModes: + items: + type: string + type: array + x-kubernetes-list-type: atomic + dataSource: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + required: + - kind + - name + type: object + x-kubernetes-map-type: atomic + dataSourceRef: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + namespace: + type: string + required: + - kind + - name + type: object + resources: + properties: + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + selector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + storageClassName: + type: string + volumeAttributesClassName: + type: string + volumeMode: + type: string + volumeName: + type: string + type: object + required: + - spec + type: object + type: object + fc: + properties: + fsType: + type: string + lun: + format: int32 + type: integer + readOnly: + type: boolean + targetWWNs: + items: + type: string + type: array + x-kubernetes-list-type: atomic + wwids: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + flexVolume: + properties: + driver: + type: string + fsType: + type: string + options: + additionalProperties: + type: string + type: object + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + required: + - driver + type: object + flocker: + properties: + datasetName: + type: string + datasetUUID: + type: string + type: object + gcePersistentDisk: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + pdName: + type: string + readOnly: + type: boolean + required: + - pdName + type: object + gitRepo: + properties: + directory: + type: string + repository: + type: string + revision: + type: string + required: + - repository + type: object + glusterfs: + properties: + endpoints: + type: string + path: + type: string + readOnly: + type: boolean + required: + - endpoints + - path + type: object + hostPath: + properties: + path: + type: string + type: + type: string + required: + - path + type: object + image: + properties: + pullPolicy: + type: string + reference: + type: string + type: object + iscsi: + properties: + chapAuthDiscovery: + type: boolean + chapAuthSession: + type: boolean + fsType: + type: string + initiatorName: + type: string + iqn: + type: string + iscsiInterface: + default: default + type: string + lun: + format: int32 + type: integer + portals: + items: + type: string + type: array + x-kubernetes-list-type: atomic + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + targetPortal: + type: string + required: + - iqn + - lun + - targetPortal + type: object + name: + type: string + nfs: + properties: + path: + type: string + readOnly: + type: boolean + server: + type: string + required: + - path + - server + type: object + persistentVolumeClaim: + properties: + claimName: + type: string + readOnly: + type: boolean + required: + - claimName + type: object + photonPersistentDisk: + properties: + fsType: + type: string + pdID: + type: string + required: + - pdID + type: object + portworxVolume: + properties: + fsType: + type: string + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + projected: + properties: + defaultMode: + format: int32 + type: integer + sources: + items: + properties: + clusterTrustBundle: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + name: + type: string + optional: + type: boolean + path: + type: string + signerName: + type: string + required: + - path + type: object + configMap: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + downwardAPI: + properties: + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + secret: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + serviceAccountToken: + properties: + audience: + type: string + expirationSeconds: + format: int64 + type: integer + path: + type: string + required: + - path + type: object + type: object + type: array + x-kubernetes-list-type: atomic + type: object + quobyte: + properties: + group: + type: string + readOnly: + type: boolean + registry: + type: string + tenant: + type: string + user: + type: string + volume: + type: string + required: + - registry + - volume + type: object + rbd: + properties: + fsType: + type: string + image: + type: string + keyring: + default: /etc/ceph/keyring + type: string + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + pool: + default: rbd + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + default: admin + type: string + required: + - image + - monitors + type: object + scaleIO: + properties: + fsType: + default: xfs + type: string + gateway: + type: string + protectionDomain: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + sslEnabled: + type: boolean + storageMode: + default: ThinProvisioned + type: string + storagePool: + type: string + system: + type: string + volumeName: + type: string + required: + - gateway + - secretRef + - system + type: object + secret: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + optional: + type: boolean + secretName: + type: string + type: object + storageos: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeName: + type: string + volumeNamespace: + type: string + type: object + vsphereVolume: + properties: + fsType: + type: string + storagePolicyID: + type: string + storagePolicyName: + type: string + volumePath: + type: string + required: + - volumePath + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + required: + - containers + type: object + type: object + replicas: + format: int32 + type: integer + router: + properties: + gateway: + properties: + refs: + items: + properties: + name: + maxLength: 253 + minLength: 1 + type: string + namespace: + maxLength: 63 + minLength: 1 + pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$ + type: string + type: object + type: array + type: object + ingress: + properties: + refs: + items: + properties: + name: + maxLength: 253 + minLength: 1 + type: string + namespace: + maxLength: 63 + minLength: 1 + pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$ + type: string + type: object + type: array + type: object + route: + properties: + http: + properties: + refs: + items: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + type: array + spec: + properties: + hostnames: + items: + maxLength: 253 + minLength: 1 + pattern: ^(\*\.)?[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + maxItems: 16 + type: array + parentRefs: + items: + properties: + group: + default: gateway.networking.k8s.io + maxLength: 253 + pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + kind: + default: Gateway + maxLength: 63 + minLength: 1 + pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$ + type: string + name: + maxLength: 253 + minLength: 1 + type: string + namespace: + maxLength: 63 + minLength: 1 + pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$ + type: string + port: + format: int32 + maximum: 65535 + minimum: 1 + type: integer + sectionName: + maxLength: 253 + minLength: 1 + pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + required: + - name + type: object + maxItems: 32 + type: array + rules: + default: + - matches: + - path: + type: PathPrefix + value: / + items: + properties: + backendRefs: + items: + properties: + filters: + items: + properties: + extensionRef: + properties: + group: + maxLength: 253 + pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + kind: + maxLength: 63 + minLength: 1 + pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$ + type: string + name: + maxLength: 253 + minLength: 1 + type: string + required: + - group + - kind + - name + type: object + requestHeaderModifier: + properties: + add: + items: + properties: + name: + maxLength: 256 + minLength: 1 + pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$ + type: string + value: + maxLength: 4096 + minLength: 1 + type: string + required: + - name + - value + type: object + maxItems: 16 + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + remove: + items: + type: string + maxItems: 16 + type: array + x-kubernetes-list-type: set + set: + items: + properties: + name: + maxLength: 256 + minLength: 1 + pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$ + type: string + value: + maxLength: 4096 + minLength: 1 + type: string + required: + - name + - value + type: object + maxItems: 16 + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + type: object + requestMirror: + properties: + backendRef: + properties: + group: + default: "" + maxLength: 253 + pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + kind: + default: Service + maxLength: 63 + minLength: 1 + pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$ + type: string + name: + maxLength: 253 + minLength: 1 + type: string + namespace: + maxLength: 63 + minLength: 1 + pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$ + type: string + port: + format: int32 + maximum: 65535 + minimum: 1 + type: integer + required: + - name + type: object + x-kubernetes-validations: + - message: Must have port for + Service reference + rule: '(size(self.group) == + 0 && self.kind == ''Service'') + ? has(self.port) : true' + fraction: + properties: + denominator: + default: 100 + format: int32 + minimum: 1 + type: integer + numerator: + format: int32 + minimum: 0 + type: integer + required: + - numerator + type: object + x-kubernetes-validations: + - message: numerator must be + less than or equal to denominator + rule: self.numerator <= self.denominator + percent: + format: int32 + maximum: 100 + minimum: 0 + type: integer + required: + - backendRef + type: object + requestRedirect: + properties: + hostname: + maxLength: 253 + minLength: 1 + pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + path: + properties: + replaceFullPath: + maxLength: 1024 + type: string + replacePrefixMatch: + maxLength: 1024 + type: string + type: + enum: + - ReplaceFullPath + - ReplacePrefixMatch + type: string + required: + - type + type: object + x-kubernetes-validations: + - message: replaceFullPath must + be specified when type is + set to 'ReplaceFullPath' + rule: 'self.type == ''ReplaceFullPath'' + ? has(self.replaceFullPath) + : true' + - message: type must be 'ReplaceFullPath' + when replaceFullPath is + set + rule: 'has(self.replaceFullPath) + ? self.type == ''ReplaceFullPath'' + : true' + - message: replacePrefixMatch + must be specified when type + is set to 'ReplacePrefixMatch' + rule: 'self.type == ''ReplacePrefixMatch'' + ? has(self.replacePrefixMatch) + : true' + - message: type must be 'ReplacePrefixMatch' + when replacePrefixMatch + is set + rule: 'has(self.replacePrefixMatch) + ? self.type == ''ReplacePrefixMatch'' + : true' + port: + format: int32 + maximum: 65535 + minimum: 1 + type: integer + scheme: + enum: + - http + - https + type: string + statusCode: + default: 302 + enum: + - 301 + - 302 + type: integer + type: object + responseHeaderModifier: + properties: + add: + items: + properties: + name: + maxLength: 256 + minLength: 1 + pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$ + type: string + value: + maxLength: 4096 + minLength: 1 + type: string + required: + - name + - value + type: object + maxItems: 16 + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + remove: + items: + type: string + maxItems: 16 + type: array + x-kubernetes-list-type: set + set: + items: + properties: + name: + maxLength: 256 + minLength: 1 + pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$ + type: string + value: + maxLength: 4096 + minLength: 1 + type: string + required: + - name + - value + type: object + maxItems: 16 + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + type: object + type: + enum: + - RequestHeaderModifier + - ResponseHeaderModifier + - RequestMirror + - RequestRedirect + - URLRewrite + - ExtensionRef + type: string + urlRewrite: + properties: + hostname: + maxLength: 253 + minLength: 1 + pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + path: + properties: + replaceFullPath: + maxLength: 1024 + type: string + replacePrefixMatch: + maxLength: 1024 + type: string + type: + enum: + - ReplaceFullPath + - ReplacePrefixMatch + type: string + required: + - type + type: object + x-kubernetes-validations: + - message: replaceFullPath must + be specified when type is + set to 'ReplaceFullPath' + rule: 'self.type == ''ReplaceFullPath'' + ? has(self.replaceFullPath) + : true' + - message: type must be 'ReplaceFullPath' + when replaceFullPath is + set + rule: 'has(self.replaceFullPath) + ? self.type == ''ReplaceFullPath'' + : true' + - message: replacePrefixMatch + must be specified when type + is set to 'ReplacePrefixMatch' + rule: 'self.type == ''ReplacePrefixMatch'' + ? has(self.replacePrefixMatch) + : true' + - message: type must be 'ReplacePrefixMatch' + when replacePrefixMatch + is set + rule: 'has(self.replacePrefixMatch) + ? self.type == ''ReplacePrefixMatch'' + : true' + type: object + required: + - type + type: object + x-kubernetes-validations: + - message: filter.requestHeaderModifier + must be nil if the filter.type is + not RequestHeaderModifier + rule: '!(has(self.requestHeaderModifier) + && self.type != ''RequestHeaderModifier'')' + - message: filter.requestHeaderModifier + must be specified for RequestHeaderModifier + filter.type + rule: '!(!has(self.requestHeaderModifier) + && self.type == ''RequestHeaderModifier'')' + - message: filter.responseHeaderModifier + must be nil if the filter.type is + not ResponseHeaderModifier + rule: '!(has(self.responseHeaderModifier) + && self.type != ''ResponseHeaderModifier'')' + - message: filter.responseHeaderModifier + must be specified for ResponseHeaderModifier + filter.type + rule: '!(!has(self.responseHeaderModifier) + && self.type == ''ResponseHeaderModifier'')' + - message: filter.requestMirror must + be nil if the filter.type is not + RequestMirror + rule: '!(has(self.requestMirror) && + self.type != ''RequestMirror'')' + - message: filter.requestMirror must + be specified for RequestMirror filter.type + rule: '!(!has(self.requestMirror) + && self.type == ''RequestMirror'')' + - message: filter.requestRedirect must + be nil if the filter.type is not + RequestRedirect + rule: '!(has(self.requestRedirect) + && self.type != ''RequestRedirect'')' + - message: filter.requestRedirect must + be specified for RequestRedirect + filter.type + rule: '!(!has(self.requestRedirect) + && self.type == ''RequestRedirect'')' + - message: filter.urlRewrite must be + nil if the filter.type is not URLRewrite + rule: '!(has(self.urlRewrite) && self.type + != ''URLRewrite'')' + - message: filter.urlRewrite must be + specified for URLRewrite filter.type + rule: '!(!has(self.urlRewrite) && + self.type == ''URLRewrite'')' + - message: filter.extensionRef must + be nil if the filter.type is not + ExtensionRef + rule: '!(has(self.extensionRef) && + self.type != ''ExtensionRef'')' + - message: filter.extensionRef must + be specified for ExtensionRef filter.type + rule: '!(!has(self.extensionRef) && + self.type == ''ExtensionRef'')' + maxItems: 16 + type: array + x-kubernetes-validations: + - message: May specify either httpRouteFilterRequestRedirect + or httpRouteFilterRequestRewrite, + but not both + rule: '!(self.exists(f, f.type == ''RequestRedirect'') + && self.exists(f, f.type == ''URLRewrite''))' + - message: May specify either httpRouteFilterRequestRedirect + or httpRouteFilterRequestRewrite, + but not both + rule: '!(self.exists(f, f.type == ''RequestRedirect'') + && self.exists(f, f.type == ''URLRewrite''))' + - message: RequestHeaderModifier filter + cannot be repeated + rule: self.filter(f, f.type == 'RequestHeaderModifier').size() + <= 1 + - message: ResponseHeaderModifier filter + cannot be repeated + rule: self.filter(f, f.type == 'ResponseHeaderModifier').size() + <= 1 + - message: RequestRedirect filter cannot + be repeated + rule: self.filter(f, f.type == 'RequestRedirect').size() + <= 1 + - message: URLRewrite filter cannot be + repeated + rule: self.filter(f, f.type == 'URLRewrite').size() + <= 1 + group: + default: "" + maxLength: 253 + pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + kind: + default: Service + maxLength: 63 + minLength: 1 + pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$ + type: string + name: + maxLength: 253 + minLength: 1 + type: string + namespace: + maxLength: 63 + minLength: 1 + pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$ + type: string + port: + format: int32 + maximum: 65535 + minimum: 1 + type: integer + weight: + default: 1 + format: int32 + maximum: 1000000 + minimum: 0 + type: integer + required: + - name + type: object + x-kubernetes-validations: + - message: Must have port for Service reference + rule: '(size(self.group) == 0 && self.kind + == ''Service'') ? has(self.port) : true' + maxItems: 16 + type: array + filters: + items: + properties: + extensionRef: + properties: + group: + maxLength: 253 + pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + kind: + maxLength: 63 + minLength: 1 + pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$ + type: string + name: + maxLength: 253 + minLength: 1 + type: string + required: + - group + - kind + - name + type: object + requestHeaderModifier: + properties: + add: + items: + properties: + name: + maxLength: 256 + minLength: 1 + pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$ + type: string + value: + maxLength: 4096 + minLength: 1 + type: string + required: + - name + - value + type: object + maxItems: 16 + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + remove: + items: + type: string + maxItems: 16 + type: array + x-kubernetes-list-type: set + set: + items: + properties: + name: + maxLength: 256 + minLength: 1 + pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$ + type: string + value: + maxLength: 4096 + minLength: 1 + type: string + required: + - name + - value + type: object + maxItems: 16 + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + type: object + requestMirror: + properties: + backendRef: + properties: + group: + default: "" + maxLength: 253 + pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + kind: + default: Service + maxLength: 63 + minLength: 1 + pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$ + type: string + name: + maxLength: 253 + minLength: 1 + type: string + namespace: + maxLength: 63 + minLength: 1 + pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$ + type: string + port: + format: int32 + maximum: 65535 + minimum: 1 + type: integer + required: + - name + type: object + x-kubernetes-validations: + - message: Must have port for Service + reference + rule: '(size(self.group) == 0 && + self.kind == ''Service'') ? has(self.port) + : true' + fraction: + properties: + denominator: + default: 100 + format: int32 + minimum: 1 + type: integer + numerator: + format: int32 + minimum: 0 + type: integer + required: + - numerator + type: object + x-kubernetes-validations: + - message: numerator must be less + than or equal to denominator + rule: self.numerator <= self.denominator + percent: + format: int32 + maximum: 100 + minimum: 0 + type: integer + required: + - backendRef + type: object + requestRedirect: + properties: + hostname: + maxLength: 253 + minLength: 1 + pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + path: + properties: + replaceFullPath: + maxLength: 1024 + type: string + replacePrefixMatch: + maxLength: 1024 + type: string + type: + enum: + - ReplaceFullPath + - ReplacePrefixMatch + type: string + required: + - type + type: object + x-kubernetes-validations: + - message: replaceFullPath must be + specified when type is set to + 'ReplaceFullPath' + rule: 'self.type == ''ReplaceFullPath'' + ? has(self.replaceFullPath) : + true' + - message: type must be 'ReplaceFullPath' + when replaceFullPath is set + rule: 'has(self.replaceFullPath) + ? self.type == ''ReplaceFullPath'' + : true' + - message: replacePrefixMatch must + be specified when type is set + to 'ReplacePrefixMatch' + rule: 'self.type == ''ReplacePrefixMatch'' + ? has(self.replacePrefixMatch) + : true' + - message: type must be 'ReplacePrefixMatch' + when replacePrefixMatch is set + rule: 'has(self.replacePrefixMatch) + ? self.type == ''ReplacePrefixMatch'' + : true' + port: + format: int32 + maximum: 65535 + minimum: 1 + type: integer + scheme: + enum: + - http + - https + type: string + statusCode: + default: 302 + enum: + - 301 + - 302 + type: integer + type: object + responseHeaderModifier: + properties: + add: + items: + properties: + name: + maxLength: 256 + minLength: 1 + pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$ + type: string + value: + maxLength: 4096 + minLength: 1 + type: string + required: + - name + - value + type: object + maxItems: 16 + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + remove: + items: + type: string + maxItems: 16 + type: array + x-kubernetes-list-type: set + set: + items: + properties: + name: + maxLength: 256 + minLength: 1 + pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$ + type: string + value: + maxLength: 4096 + minLength: 1 + type: string + required: + - name + - value + type: object + maxItems: 16 + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + type: object + type: + enum: + - RequestHeaderModifier + - ResponseHeaderModifier + - RequestMirror + - RequestRedirect + - URLRewrite + - ExtensionRef + type: string + urlRewrite: + properties: + hostname: + maxLength: 253 + minLength: 1 + pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + path: + properties: + replaceFullPath: + maxLength: 1024 + type: string + replacePrefixMatch: + maxLength: 1024 + type: string + type: + enum: + - ReplaceFullPath + - ReplacePrefixMatch + type: string + required: + - type + type: object + x-kubernetes-validations: + - message: replaceFullPath must be + specified when type is set to + 'ReplaceFullPath' + rule: 'self.type == ''ReplaceFullPath'' + ? has(self.replaceFullPath) : + true' + - message: type must be 'ReplaceFullPath' + when replaceFullPath is set + rule: 'has(self.replaceFullPath) + ? self.type == ''ReplaceFullPath'' + : true' + - message: replacePrefixMatch must + be specified when type is set + to 'ReplacePrefixMatch' + rule: 'self.type == ''ReplacePrefixMatch'' + ? has(self.replacePrefixMatch) + : true' + - message: type must be 'ReplacePrefixMatch' + when replacePrefixMatch is set + rule: 'has(self.replacePrefixMatch) + ? self.type == ''ReplacePrefixMatch'' + : true' + type: object + required: + - type + type: object + x-kubernetes-validations: + - message: filter.requestHeaderModifier must + be nil if the filter.type is not RequestHeaderModifier + rule: '!(has(self.requestHeaderModifier) + && self.type != ''RequestHeaderModifier'')' + - message: filter.requestHeaderModifier must + be specified for RequestHeaderModifier + filter.type + rule: '!(!has(self.requestHeaderModifier) + && self.type == ''RequestHeaderModifier'')' + - message: filter.responseHeaderModifier must + be nil if the filter.type is not ResponseHeaderModifier + rule: '!(has(self.responseHeaderModifier) + && self.type != ''ResponseHeaderModifier'')' + - message: filter.responseHeaderModifier must + be specified for ResponseHeaderModifier + filter.type + rule: '!(!has(self.responseHeaderModifier) + && self.type == ''ResponseHeaderModifier'')' + - message: filter.requestMirror must be nil + if the filter.type is not RequestMirror + rule: '!(has(self.requestMirror) && self.type + != ''RequestMirror'')' + - message: filter.requestMirror must be specified + for RequestMirror filter.type + rule: '!(!has(self.requestMirror) && self.type + == ''RequestMirror'')' + - message: filter.requestRedirect must be + nil if the filter.type is not RequestRedirect + rule: '!(has(self.requestRedirect) && self.type + != ''RequestRedirect'')' + - message: filter.requestRedirect must be + specified for RequestRedirect filter.type + rule: '!(!has(self.requestRedirect) && self.type + == ''RequestRedirect'')' + - message: filter.urlRewrite must be nil if + the filter.type is not URLRewrite + rule: '!(has(self.urlRewrite) && self.type + != ''URLRewrite'')' + - message: filter.urlRewrite must be specified + for URLRewrite filter.type + rule: '!(!has(self.urlRewrite) && self.type + == ''URLRewrite'')' + - message: filter.extensionRef must be nil + if the filter.type is not ExtensionRef + rule: '!(has(self.extensionRef) && self.type + != ''ExtensionRef'')' + - message: filter.extensionRef must be specified + for ExtensionRef filter.type + rule: '!(!has(self.extensionRef) && self.type + == ''ExtensionRef'')' + maxItems: 16 + type: array + x-kubernetes-validations: + - message: May specify either httpRouteFilterRequestRedirect + or httpRouteFilterRequestRewrite, but not + both + rule: '!(self.exists(f, f.type == ''RequestRedirect'') + && self.exists(f, f.type == ''URLRewrite''))' + - message: RequestHeaderModifier filter cannot + be repeated + rule: self.filter(f, f.type == 'RequestHeaderModifier').size() + <= 1 + - message: ResponseHeaderModifier filter cannot + be repeated + rule: self.filter(f, f.type == 'ResponseHeaderModifier').size() + <= 1 + - message: RequestRedirect filter cannot be + repeated + rule: self.filter(f, f.type == 'RequestRedirect').size() + <= 1 + - message: URLRewrite filter cannot be repeated + rule: self.filter(f, f.type == 'URLRewrite').size() + <= 1 + matches: + default: + - path: + type: PathPrefix + value: / + items: + properties: + headers: + items: + properties: + name: + maxLength: 256 + minLength: 1 + pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$ + type: string + type: + default: Exact + enum: + - Exact + - RegularExpression + type: string + value: + maxLength: 4096 + minLength: 1 + type: string + required: + - name + - value + type: object + maxItems: 16 + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + method: + enum: + - GET + - HEAD + - POST + - PUT + - DELETE + - CONNECT + - OPTIONS + - TRACE + - PATCH + type: string + path: + default: + type: PathPrefix + value: / + properties: + type: + default: PathPrefix + enum: + - Exact + - PathPrefix + - RegularExpression + type: string + value: + default: / + maxLength: 1024 + type: string + type: object + x-kubernetes-validations: + - message: value must be an absolute path + and start with '/' when type one of + ['Exact', 'PathPrefix'] + rule: '(self.type in [''Exact'',''PathPrefix'']) + ? self.value.startsWith(''/'') : true' + - message: must not contain '//' when + type one of ['Exact', 'PathPrefix'] + rule: '(self.type in [''Exact'',''PathPrefix'']) + ? !self.value.contains(''//'') : true' + - message: must not contain '/./' when + type one of ['Exact', 'PathPrefix'] + rule: '(self.type in [''Exact'',''PathPrefix'']) + ? !self.value.contains(''/./'') : + true' + - message: must not contain '/../' when + type one of ['Exact', 'PathPrefix'] + rule: '(self.type in [''Exact'',''PathPrefix'']) + ? !self.value.contains(''/../'') : + true' + - message: must not contain '%2f' when + type one of ['Exact', 'PathPrefix'] + rule: '(self.type in [''Exact'',''PathPrefix'']) + ? !self.value.contains(''%2f'') : + true' + - message: must not contain '%2F' when + type one of ['Exact', 'PathPrefix'] + rule: '(self.type in [''Exact'',''PathPrefix'']) + ? !self.value.contains(''%2F'') : + true' + - message: must not contain '#' when type + one of ['Exact', 'PathPrefix'] + rule: '(self.type in [''Exact'',''PathPrefix'']) + ? !self.value.contains(''#'') : true' + - message: must not end with '/..' when + type one of ['Exact', 'PathPrefix'] + rule: '(self.type in [''Exact'',''PathPrefix'']) + ? !self.value.endsWith(''/..'') : + true' + - message: must not end with '/.' when + type one of ['Exact', 'PathPrefix'] + rule: '(self.type in [''Exact'',''PathPrefix'']) + ? !self.value.endsWith(''/.'') : true' + - message: type must be one of ['Exact', + 'PathPrefix', 'RegularExpression'] + rule: self.type in ['Exact','PathPrefix'] + || self.type == 'RegularExpression' + - message: must only contain valid characters + (matching ^(?:[-A-Za-z0-9/._~!$&'()*+,;=:@]|[%][0-9a-fA-F]{2})+$) + for types ['Exact', 'PathPrefix'] + rule: '(self.type in [''Exact'',''PathPrefix'']) + ? self.value.matches(r"""^(?:[-A-Za-z0-9/._~!$&''()*+,;=:@]|[%][0-9a-fA-F]{2})+$""") + : true' + queryParams: + items: + properties: + name: + maxLength: 256 + minLength: 1 + pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$ + type: string + type: + default: Exact + enum: + - Exact + - RegularExpression + type: string + value: + maxLength: 1024 + minLength: 1 + type: string + required: + - name + - value + type: object + maxItems: 16 + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + type: object + maxItems: 64 + type: array + name: + maxLength: 253 + minLength: 1 + pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + retry: + properties: + attempts: + type: integer + backoff: + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + codes: + items: + maximum: 599 + minimum: 400 + type: integer + type: array + type: object + sessionPersistence: + properties: + absoluteTimeout: + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + cookieConfig: + properties: + lifetimeType: + default: Session + enum: + - Permanent + - Session + type: string + type: object + idleTimeout: + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + sessionName: + maxLength: 128 + type: string + type: + default: Cookie + enum: + - Cookie + - Header + type: string + type: object + x-kubernetes-validations: + - message: AbsoluteTimeout must be specified + when cookie lifetimeType is Permanent + rule: '!has(self.cookieConfig) || !has(self.cookieConfig.lifetimeType) + || self.cookieConfig.lifetimeType != ''Permanent'' + || has(self.absoluteTimeout)' + timeouts: + properties: + backendRequest: + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + request: + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object + x-kubernetes-validations: + - message: backendRequest timeout cannot be + longer than request timeout + rule: '!(has(self.request) && has(self.backendRequest) + && duration(self.request) != duration(''0s'') + && duration(self.backendRequest) > duration(self.request))' + type: object + x-kubernetes-validations: + - message: RequestRedirect filter must not be used + together with backendRefs + rule: '(has(self.backendRefs) && size(self.backendRefs) + > 0) ? (!has(self.filters) || self.filters.all(f, + !has(f.requestRedirect))): true' + - message: When using RequestRedirect filter with + path.replacePrefixMatch, exactly one PathPrefix + match must be specified + rule: '(has(self.filters) && self.filters.exists_one(f, + has(f.requestRedirect) && has(f.requestRedirect.path) + && f.requestRedirect.path.type == ''ReplacePrefixMatch'' + && has(f.requestRedirect.path.replacePrefixMatch))) + ? ((size(self.matches) != 1 || !has(self.matches[0].path) + || self.matches[0].path.type != ''PathPrefix'') + ? false : true) : true' + - message: When using URLRewrite filter with path.replacePrefixMatch, + exactly one PathPrefix match must be specified + rule: '(has(self.filters) && self.filters.exists_one(f, + has(f.urlRewrite) && has(f.urlRewrite.path) + && f.urlRewrite.path.type == ''ReplacePrefixMatch'' + && has(f.urlRewrite.path.replacePrefixMatch))) + ? ((size(self.matches) != 1 || !has(self.matches[0].path) + || self.matches[0].path.type != ''PathPrefix'') + ? false : true) : true' + - message: Within backendRefs, when using RequestRedirect + filter with path.replacePrefixMatch, exactly + one PathPrefix match must be specified + rule: '(has(self.backendRefs) && self.backendRefs.exists_one(b, + (has(b.filters) && b.filters.exists_one(f, has(f.requestRedirect) + && has(f.requestRedirect.path) && f.requestRedirect.path.type + == ''ReplacePrefixMatch'' && has(f.requestRedirect.path.replacePrefixMatch))) + )) ? ((size(self.matches) != 1 || !has(self.matches[0].path) + || self.matches[0].path.type != ''PathPrefix'') + ? false : true) : true' + - message: Within backendRefs, When using URLRewrite + filter with path.replacePrefixMatch, exactly + one PathPrefix match must be specified + rule: '(has(self.backendRefs) && self.backendRefs.exists_one(b, + (has(b.filters) && b.filters.exists_one(f, has(f.urlRewrite) + && has(f.urlRewrite.path) && f.urlRewrite.path.type + == ''ReplacePrefixMatch'' && has(f.urlRewrite.path.replacePrefixMatch))) + )) ? ((size(self.matches) != 1 || !has(self.matches[0].path) + || self.matches[0].path.type != ''PathPrefix'') + ? false : true) : true' + maxItems: 16 + type: array + x-kubernetes-validations: + - message: While 16 rules and 64 matches per rule + are allowed, the total number of matches across + all rules in a route must be less than 128 + rule: '(self.size() > 0 ? self[0].matches.size() + : 0) + (self.size() > 1 ? self[1].matches.size() + : 0) + (self.size() > 2 ? self[2].matches.size() + : 0) + (self.size() > 3 ? self[3].matches.size() + : 0) + (self.size() > 4 ? self[4].matches.size() + : 0) + (self.size() > 5 ? self[5].matches.size() + : 0) + (self.size() > 6 ? self[6].matches.size() + : 0) + (self.size() > 7 ? self[7].matches.size() + : 0) + (self.size() > 8 ? self[8].matches.size() + : 0) + (self.size() > 9 ? self[9].matches.size() + : 0) + (self.size() > 10 ? self[10].matches.size() + : 0) + (self.size() > 11 ? self[11].matches.size() + : 0) + (self.size() > 12 ? self[12].matches.size() + : 0) + (self.size() > 13 ? self[13].matches.size() + : 0) + (self.size() > 14 ? self[14].matches.size() + : 0) + (self.size() > 15 ? self[15].matches.size() + : 0) <= 128' + type: object + type: object + type: object + scheduler: + properties: + pool: + properties: + ref: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + spec: + properties: + extensionRef: + properties: + failureMode: + default: FailClose + enum: + - FailOpen + - FailClose + type: string + group: + default: "" + maxLength: 253 + pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + kind: + default: Service + maxLength: 63 + minLength: 1 + pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$ + type: string + name: + maxLength: 253 + minLength: 1 + type: string + portNumber: + format: int32 + maximum: 65535 + minimum: 1 + type: integer + required: + - name + type: object + selector: + additionalProperties: + maxLength: 63 + minLength: 0 + pattern: ^(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])?$ + type: string + type: object + targetPortNumber: + format: int32 + maximum: 65535 + minimum: 1 + type: integer + required: + - extensionRef + - selector + - targetPortNumber + type: object + type: object + template: + properties: + activeDeadlineSeconds: + format: int64 + type: integer + affinity: + properties: + nodeAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + preference: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + weight: + format: int32 + type: integer + required: + - preference + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + properties: + nodeSelectorTerms: + items: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + type: array + x-kubernetes-list-type: atomic + required: + - nodeSelectorTerms + type: object + x-kubernetes-map-type: atomic + type: object + podAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + podAntiAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + type: object + automountServiceAccountToken: + type: boolean + containers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + dnsConfig: + properties: + nameservers: + items: + type: string + type: array + x-kubernetes-list-type: atomic + options: + items: + properties: + name: + type: string + value: + type: string + type: object + type: array + x-kubernetes-list-type: atomic + searches: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + dnsPolicy: + type: string + enableServiceLinks: + type: boolean + ephemeralContainers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + targetContainerName: + type: string + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + hostAliases: + items: + properties: + hostnames: + items: + type: string + type: array + x-kubernetes-list-type: atomic + ip: + type: string + required: + - ip + type: object + type: array + x-kubernetes-list-map-keys: + - ip + x-kubernetes-list-type: map + hostIPC: + type: boolean + hostNetwork: + type: boolean + hostPID: + type: boolean + hostUsers: + type: boolean + hostname: + type: string + imagePullSecrets: + items: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + initContainers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + nodeName: + type: string + nodeSelector: + additionalProperties: + type: string + type: object + x-kubernetes-map-type: atomic + os: + properties: + name: + type: string + required: + - name + type: object + overhead: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + preemptionPolicy: + type: string + priority: + format: int32 + type: integer + priorityClassName: + type: string + readinessGates: + items: + properties: + conditionType: + type: string + required: + - conditionType + type: object + type: array + x-kubernetes-list-type: atomic + resourceClaims: + items: + properties: + name: + type: string + resourceClaimName: + type: string + resourceClaimTemplateName: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + runtimeClassName: + type: string + schedulerName: + type: string + schedulingGates: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + securityContext: + properties: + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + fsGroup: + format: int64 + type: integer + fsGroupChangePolicy: + type: string + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxChangePolicy: + type: string + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + supplementalGroups: + items: + format: int64 + type: integer + type: array + x-kubernetes-list-type: atomic + supplementalGroupsPolicy: + type: string + sysctls: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + serviceAccount: + type: string + serviceAccountName: + type: string + setHostnameAsFQDN: + type: boolean + shareProcessNamespace: + type: boolean + subdomain: + type: string + terminationGracePeriodSeconds: + format: int64 + type: integer + tolerations: + items: + properties: + effect: + type: string + key: + type: string + operator: + type: string + tolerationSeconds: + format: int64 + type: integer + value: + type: string + type: object + type: array + x-kubernetes-list-type: atomic + topologySpreadConstraints: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + maxSkew: + format: int32 + type: integer + minDomains: + format: int32 + type: integer + nodeAffinityPolicy: + type: string + nodeTaintsPolicy: + type: string + topologyKey: + type: string + whenUnsatisfiable: + type: string + required: + - maxSkew + - topologyKey + - whenUnsatisfiable + type: object + type: array + x-kubernetes-list-map-keys: + - topologyKey + - whenUnsatisfiable + x-kubernetes-list-type: map + volumes: + items: + properties: + awsElasticBlockStore: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + azureDisk: + properties: + cachingMode: + type: string + diskName: + type: string + diskURI: + type: string + fsType: + default: ext4 + type: string + kind: + type: string + readOnly: + default: false + type: boolean + required: + - diskName + - diskURI + type: object + azureFile: + properties: + readOnly: + type: boolean + secretName: + type: string + shareName: + type: string + required: + - secretName + - shareName + type: object + cephfs: + properties: + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + path: + type: string + readOnly: + type: boolean + secretFile: + type: string + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + type: string + required: + - monitors + type: object + cinder: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeID: + type: string + required: + - volumeID + type: object + configMap: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + csi: + properties: + driver: + type: string + fsType: + type: string + nodePublishSecretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + readOnly: + type: boolean + volumeAttributes: + additionalProperties: + type: string + type: object + required: + - driver + type: object + downwardAPI: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + emptyDir: + properties: + medium: + type: string + sizeLimit: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + ephemeral: + properties: + volumeClaimTemplate: + properties: + metadata: + type: object + spec: + properties: + accessModes: + items: + type: string + type: array + x-kubernetes-list-type: atomic + dataSource: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + required: + - kind + - name + type: object + x-kubernetes-map-type: atomic + dataSourceRef: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + namespace: + type: string + required: + - kind + - name + type: object + resources: + properties: + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + selector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + storageClassName: + type: string + volumeAttributesClassName: + type: string + volumeMode: + type: string + volumeName: + type: string + type: object + required: + - spec + type: object + type: object + fc: + properties: + fsType: + type: string + lun: + format: int32 + type: integer + readOnly: + type: boolean + targetWWNs: + items: + type: string + type: array + x-kubernetes-list-type: atomic + wwids: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + flexVolume: + properties: + driver: + type: string + fsType: + type: string + options: + additionalProperties: + type: string + type: object + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + required: + - driver + type: object + flocker: + properties: + datasetName: + type: string + datasetUUID: + type: string + type: object + gcePersistentDisk: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + pdName: + type: string + readOnly: + type: boolean + required: + - pdName + type: object + gitRepo: + properties: + directory: + type: string + repository: + type: string + revision: + type: string + required: + - repository + type: object + glusterfs: + properties: + endpoints: + type: string + path: + type: string + readOnly: + type: boolean + required: + - endpoints + - path + type: object + hostPath: + properties: + path: + type: string + type: + type: string + required: + - path + type: object + image: + properties: + pullPolicy: + type: string + reference: + type: string + type: object + iscsi: + properties: + chapAuthDiscovery: + type: boolean + chapAuthSession: + type: boolean + fsType: + type: string + initiatorName: + type: string + iqn: + type: string + iscsiInterface: + default: default + type: string + lun: + format: int32 + type: integer + portals: + items: + type: string + type: array + x-kubernetes-list-type: atomic + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + targetPortal: + type: string + required: + - iqn + - lun + - targetPortal + type: object + name: + type: string + nfs: + properties: + path: + type: string + readOnly: + type: boolean + server: + type: string + required: + - path + - server + type: object + persistentVolumeClaim: + properties: + claimName: + type: string + readOnly: + type: boolean + required: + - claimName + type: object + photonPersistentDisk: + properties: + fsType: + type: string + pdID: + type: string + required: + - pdID + type: object + portworxVolume: + properties: + fsType: + type: string + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + projected: + properties: + defaultMode: + format: int32 + type: integer + sources: + items: + properties: + clusterTrustBundle: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + name: + type: string + optional: + type: boolean + path: + type: string + signerName: + type: string + required: + - path + type: object + configMap: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + downwardAPI: + properties: + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + secret: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + serviceAccountToken: + properties: + audience: + type: string + expirationSeconds: + format: int64 + type: integer + path: + type: string + required: + - path + type: object + type: object + type: array + x-kubernetes-list-type: atomic + type: object + quobyte: + properties: + group: + type: string + readOnly: + type: boolean + registry: + type: string + tenant: + type: string + user: + type: string + volume: + type: string + required: + - registry + - volume + type: object + rbd: + properties: + fsType: + type: string + image: + type: string + keyring: + default: /etc/ceph/keyring + type: string + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + pool: + default: rbd + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + default: admin + type: string + required: + - image + - monitors + type: object + scaleIO: + properties: + fsType: + default: xfs + type: string + gateway: + type: string + protectionDomain: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + sslEnabled: + type: boolean + storageMode: + default: ThinProvisioned + type: string + storagePool: + type: string + system: + type: string + volumeName: + type: string + required: + - gateway + - secretRef + - system + type: object + secret: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + optional: + type: boolean + secretName: + type: string + type: object + storageos: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeName: + type: string + volumeNamespace: + type: string + type: object + vsphereVolume: + properties: + fsType: + type: string + storagePolicyID: + type: string + storagePolicyName: + type: string + volumePath: + type: string + required: + - volumePath + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + required: + - containers + type: object + type: object + type: object + template: + properties: + activeDeadlineSeconds: + format: int64 + type: integer + affinity: + properties: + nodeAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + preference: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + weight: + format: int32 + type: integer + required: + - preference + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + properties: + nodeSelectorTerms: + items: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + type: array + x-kubernetes-list-type: atomic + required: + - nodeSelectorTerms + type: object + x-kubernetes-map-type: atomic + type: object + podAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + podAntiAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + type: object + automountServiceAccountToken: + type: boolean + containers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + dnsConfig: + properties: + nameservers: + items: + type: string + type: array + x-kubernetes-list-type: atomic + options: + items: + properties: + name: + type: string + value: + type: string + type: object + type: array + x-kubernetes-list-type: atomic + searches: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + dnsPolicy: + type: string + enableServiceLinks: + type: boolean + ephemeralContainers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + targetContainerName: + type: string + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + hostAliases: + items: + properties: + hostnames: + items: + type: string + type: array + x-kubernetes-list-type: atomic + ip: + type: string + required: + - ip + type: object + type: array + x-kubernetes-list-map-keys: + - ip + x-kubernetes-list-type: map + hostIPC: + type: boolean + hostNetwork: + type: boolean + hostPID: + type: boolean + hostUsers: + type: boolean + hostname: + type: string + imagePullSecrets: + items: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + initContainers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + nodeName: + type: string + nodeSelector: + additionalProperties: + type: string + type: object + x-kubernetes-map-type: atomic + os: + properties: + name: + type: string + required: + - name + type: object + overhead: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + preemptionPolicy: + type: string + priority: + format: int32 + type: integer + priorityClassName: + type: string + readinessGates: + items: + properties: + conditionType: + type: string + required: + - conditionType + type: object + type: array + x-kubernetes-list-type: atomic + resourceClaims: + items: + properties: + name: + type: string + resourceClaimName: + type: string + resourceClaimTemplateName: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + runtimeClassName: + type: string + schedulerName: + type: string + schedulingGates: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + securityContext: + properties: + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + fsGroup: + format: int64 + type: integer + fsGroupChangePolicy: + type: string + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxChangePolicy: + type: string + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + supplementalGroups: + items: + format: int64 + type: integer + type: array + x-kubernetes-list-type: atomic + supplementalGroupsPolicy: + type: string + sysctls: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + serviceAccount: + type: string + serviceAccountName: + type: string + setHostnameAsFQDN: + type: boolean + shareProcessNamespace: + type: boolean + subdomain: + type: string + terminationGracePeriodSeconds: + format: int64 + type: integer + tolerations: + items: + properties: + effect: + type: string + key: + type: string + operator: + type: string + tolerationSeconds: + format: int64 + type: integer + value: + type: string + type: object + type: array + x-kubernetes-list-type: atomic + topologySpreadConstraints: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + maxSkew: + format: int32 + type: integer + minDomains: + format: int32 + type: integer + nodeAffinityPolicy: + type: string + nodeTaintsPolicy: + type: string + topologyKey: + type: string + whenUnsatisfiable: + type: string + required: + - maxSkew + - topologyKey + - whenUnsatisfiable + type: object + type: array + x-kubernetes-list-map-keys: + - topologyKey + - whenUnsatisfiable + x-kubernetes-list-type: map + volumes: + items: + properties: + awsElasticBlockStore: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + azureDisk: + properties: + cachingMode: + type: string + diskName: + type: string + diskURI: + type: string + fsType: + default: ext4 + type: string + kind: + type: string + readOnly: + default: false + type: boolean + required: + - diskName + - diskURI + type: object + azureFile: + properties: + readOnly: + type: boolean + secretName: + type: string + shareName: + type: string + required: + - secretName + - shareName + type: object + cephfs: + properties: + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + path: + type: string + readOnly: + type: boolean + secretFile: + type: string + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + type: string + required: + - monitors + type: object + cinder: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeID: + type: string + required: + - volumeID + type: object + configMap: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + csi: + properties: + driver: + type: string + fsType: + type: string + nodePublishSecretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + readOnly: + type: boolean + volumeAttributes: + additionalProperties: + type: string + type: object + required: + - driver + type: object + downwardAPI: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + emptyDir: + properties: + medium: + type: string + sizeLimit: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + ephemeral: + properties: + volumeClaimTemplate: + properties: + metadata: + type: object + spec: + properties: + accessModes: + items: + type: string + type: array + x-kubernetes-list-type: atomic + dataSource: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + required: + - kind + - name + type: object + x-kubernetes-map-type: atomic + dataSourceRef: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + namespace: + type: string + required: + - kind + - name + type: object + resources: + properties: + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + selector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + storageClassName: + type: string + volumeAttributesClassName: + type: string + volumeMode: + type: string + volumeName: + type: string + type: object + required: + - spec + type: object + type: object + fc: + properties: + fsType: + type: string + lun: + format: int32 + type: integer + readOnly: + type: boolean + targetWWNs: + items: + type: string + type: array + x-kubernetes-list-type: atomic + wwids: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + flexVolume: + properties: + driver: + type: string + fsType: + type: string + options: + additionalProperties: + type: string + type: object + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + required: + - driver + type: object + flocker: + properties: + datasetName: + type: string + datasetUUID: + type: string + type: object + gcePersistentDisk: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + pdName: + type: string + readOnly: + type: boolean + required: + - pdName + type: object + gitRepo: + properties: + directory: + type: string + repository: + type: string + revision: + type: string + required: + - repository + type: object + glusterfs: + properties: + endpoints: + type: string + path: + type: string + readOnly: + type: boolean + required: + - endpoints + - path + type: object + hostPath: + properties: + path: + type: string + type: + type: string + required: + - path + type: object + image: + properties: + pullPolicy: + type: string + reference: + type: string + type: object + iscsi: + properties: + chapAuthDiscovery: + type: boolean + chapAuthSession: + type: boolean + fsType: + type: string + initiatorName: + type: string + iqn: + type: string + iscsiInterface: + default: default + type: string + lun: + format: int32 + type: integer + portals: + items: + type: string + type: array + x-kubernetes-list-type: atomic + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + targetPortal: + type: string + required: + - iqn + - lun + - targetPortal + type: object + name: + type: string + nfs: + properties: + path: + type: string + readOnly: + type: boolean + server: + type: string + required: + - path + - server + type: object + persistentVolumeClaim: + properties: + claimName: + type: string + readOnly: + type: boolean + required: + - claimName + type: object + photonPersistentDisk: + properties: + fsType: + type: string + pdID: + type: string + required: + - pdID + type: object + portworxVolume: + properties: + fsType: + type: string + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + projected: + properties: + defaultMode: + format: int32 + type: integer + sources: + items: + properties: + clusterTrustBundle: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + name: + type: string + optional: + type: boolean + path: + type: string + signerName: + type: string + required: + - path + type: object + configMap: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + downwardAPI: + properties: + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + secret: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + serviceAccountToken: + properties: + audience: + type: string + expirationSeconds: + format: int64 + type: integer + path: + type: string + required: + - path + type: object + type: object + type: array + x-kubernetes-list-type: atomic + type: object + quobyte: + properties: + group: + type: string + readOnly: + type: boolean + registry: + type: string + tenant: + type: string + user: + type: string + volume: + type: string + required: + - registry + - volume + type: object + rbd: + properties: + fsType: + type: string + image: + type: string + keyring: + default: /etc/ceph/keyring + type: string + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + pool: + default: rbd + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + default: admin + type: string + required: + - image + - monitors + type: object + scaleIO: + properties: + fsType: + default: xfs + type: string + gateway: + type: string + protectionDomain: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + sslEnabled: + type: boolean + storageMode: + default: ThinProvisioned + type: string + storagePool: + type: string + system: + type: string + volumeName: + type: string + required: + - gateway + - secretRef + - system + type: object + secret: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + optional: + type: boolean + secretName: + type: string + type: object + storageos: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeName: + type: string + volumeNamespace: + type: string + type: object + vsphereVolume: + properties: + fsType: + type: string + storagePolicyID: + type: string + storagePolicyName: + type: string + volumePath: + type: string + required: + - volumePath + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + required: + - containers + type: object + worker: + properties: + activeDeadlineSeconds: + format: int64 + type: integer + affinity: + properties: + nodeAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + preference: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + weight: + format: int32 + type: integer + required: + - preference + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + properties: + nodeSelectorTerms: + items: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + type: array + x-kubernetes-list-type: atomic + required: + - nodeSelectorTerms + type: object + x-kubernetes-map-type: atomic + type: object + podAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + podAntiAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + type: object + automountServiceAccountToken: + type: boolean + containers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + dnsConfig: + properties: + nameservers: + items: + type: string + type: array + x-kubernetes-list-type: atomic + options: + items: + properties: + name: + type: string + value: + type: string + type: object + type: array + x-kubernetes-list-type: atomic + searches: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + dnsPolicy: + type: string + enableServiceLinks: + type: boolean + ephemeralContainers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + targetContainerName: + type: string + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + hostAliases: + items: + properties: + hostnames: + items: + type: string + type: array + x-kubernetes-list-type: atomic + ip: + type: string + required: + - ip + type: object + type: array + x-kubernetes-list-map-keys: + - ip + x-kubernetes-list-type: map + hostIPC: + type: boolean + hostNetwork: + type: boolean + hostPID: + type: boolean + hostUsers: + type: boolean + hostname: + type: string + imagePullSecrets: + items: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + initContainers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + nodeName: + type: string + nodeSelector: + additionalProperties: + type: string + type: object + x-kubernetes-map-type: atomic + os: + properties: + name: + type: string + required: + - name + type: object + overhead: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + preemptionPolicy: + type: string + priority: + format: int32 + type: integer + priorityClassName: + type: string + readinessGates: + items: + properties: + conditionType: + type: string + required: + - conditionType + type: object + type: array + x-kubernetes-list-type: atomic + resourceClaims: + items: + properties: + name: + type: string + resourceClaimName: + type: string + resourceClaimTemplateName: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + runtimeClassName: + type: string + schedulerName: + type: string + schedulingGates: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + securityContext: + properties: + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + fsGroup: + format: int64 + type: integer + fsGroupChangePolicy: + type: string + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxChangePolicy: + type: string + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + supplementalGroups: + items: + format: int64 + type: integer + type: array + x-kubernetes-list-type: atomic + supplementalGroupsPolicy: + type: string + sysctls: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + serviceAccount: + type: string + serviceAccountName: + type: string + setHostnameAsFQDN: + type: boolean + shareProcessNamespace: + type: boolean + subdomain: + type: string + terminationGracePeriodSeconds: + format: int64 + type: integer + tolerations: + items: + properties: + effect: + type: string + key: + type: string + operator: + type: string + tolerationSeconds: + format: int64 + type: integer + value: + type: string + type: object + type: array + x-kubernetes-list-type: atomic + topologySpreadConstraints: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + maxSkew: + format: int32 + type: integer + minDomains: + format: int32 + type: integer + nodeAffinityPolicy: + type: string + nodeTaintsPolicy: + type: string + topologyKey: + type: string + whenUnsatisfiable: + type: string + required: + - maxSkew + - topologyKey + - whenUnsatisfiable + type: object + type: array + x-kubernetes-list-map-keys: + - topologyKey + - whenUnsatisfiable + x-kubernetes-list-type: map + volumes: + items: + properties: + awsElasticBlockStore: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + azureDisk: + properties: + cachingMode: + type: string + diskName: + type: string + diskURI: + type: string + fsType: + default: ext4 + type: string + kind: + type: string + readOnly: + default: false + type: boolean + required: + - diskName + - diskURI + type: object + azureFile: + properties: + readOnly: + type: boolean + secretName: + type: string + shareName: + type: string + required: + - secretName + - shareName + type: object + cephfs: + properties: + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + path: + type: string + readOnly: + type: boolean + secretFile: + type: string + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + type: string + required: + - monitors + type: object + cinder: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeID: + type: string + required: + - volumeID + type: object + configMap: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + csi: + properties: + driver: + type: string + fsType: + type: string + nodePublishSecretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + readOnly: + type: boolean + volumeAttributes: + additionalProperties: + type: string + type: object + required: + - driver + type: object + downwardAPI: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + emptyDir: + properties: + medium: + type: string + sizeLimit: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + ephemeral: + properties: + volumeClaimTemplate: + properties: + metadata: + type: object + spec: + properties: + accessModes: + items: + type: string + type: array + x-kubernetes-list-type: atomic + dataSource: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + required: + - kind + - name + type: object + x-kubernetes-map-type: atomic + dataSourceRef: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + namespace: + type: string + required: + - kind + - name + type: object + resources: + properties: + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + selector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + storageClassName: + type: string + volumeAttributesClassName: + type: string + volumeMode: + type: string + volumeName: + type: string + type: object + required: + - spec + type: object + type: object + fc: + properties: + fsType: + type: string + lun: + format: int32 + type: integer + readOnly: + type: boolean + targetWWNs: + items: + type: string + type: array + x-kubernetes-list-type: atomic + wwids: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + flexVolume: + properties: + driver: + type: string + fsType: + type: string + options: + additionalProperties: + type: string + type: object + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + required: + - driver + type: object + flocker: + properties: + datasetName: + type: string + datasetUUID: + type: string + type: object + gcePersistentDisk: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + pdName: + type: string + readOnly: + type: boolean + required: + - pdName + type: object + gitRepo: + properties: + directory: + type: string + repository: + type: string + revision: + type: string + required: + - repository + type: object + glusterfs: + properties: + endpoints: + type: string + path: + type: string + readOnly: + type: boolean + required: + - endpoints + - path + type: object + hostPath: + properties: + path: + type: string + type: + type: string + required: + - path + type: object + image: + properties: + pullPolicy: + type: string + reference: + type: string + type: object + iscsi: + properties: + chapAuthDiscovery: + type: boolean + chapAuthSession: + type: boolean + fsType: + type: string + initiatorName: + type: string + iqn: + type: string + iscsiInterface: + default: default + type: string + lun: + format: int32 + type: integer + portals: + items: + type: string + type: array + x-kubernetes-list-type: atomic + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + targetPortal: + type: string + required: + - iqn + - lun + - targetPortal + type: object + name: + type: string + nfs: + properties: + path: + type: string + readOnly: + type: boolean + server: + type: string + required: + - path + - server + type: object + persistentVolumeClaim: + properties: + claimName: + type: string + readOnly: + type: boolean + required: + - claimName + type: object + photonPersistentDisk: + properties: + fsType: + type: string + pdID: + type: string + required: + - pdID + type: object + portworxVolume: + properties: + fsType: + type: string + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + projected: + properties: + defaultMode: + format: int32 + type: integer + sources: + items: + properties: + clusterTrustBundle: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + name: + type: string + optional: + type: boolean + path: + type: string + signerName: + type: string + required: + - path + type: object + configMap: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + downwardAPI: + properties: + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + secret: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + serviceAccountToken: + properties: + audience: + type: string + expirationSeconds: + format: int64 + type: integer + path: + type: string + required: + - path + type: object + type: object + type: array + x-kubernetes-list-type: atomic + type: object + quobyte: + properties: + group: + type: string + readOnly: + type: boolean + registry: + type: string + tenant: + type: string + user: + type: string + volume: + type: string + required: + - registry + - volume + type: object + rbd: + properties: + fsType: + type: string + image: + type: string + keyring: + default: /etc/ceph/keyring + type: string + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + pool: + default: rbd + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + default: admin + type: string + required: + - image + - monitors + type: object + scaleIO: + properties: + fsType: + default: xfs + type: string + gateway: + type: string + protectionDomain: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + sslEnabled: + type: boolean + storageMode: + default: ThinProvisioned + type: string + storagePool: + type: string + system: + type: string + volumeName: + type: string + required: + - gateway + - secretRef + - system + type: object + secret: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + optional: + type: boolean + secretName: + type: string + type: object + storageos: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeName: + type: string + volumeNamespace: + type: string + type: object + vsphereVolume: + properties: + fsType: + type: string + storagePolicyID: + type: string + storagePolicyName: + type: string + volumePath: + type: string + required: + - volumePath + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + required: + - containers + type: object + required: + - model + type: object + type: object + served: true + storage: true diff --git a/charts/llmisvc-crd/templates/serving.kserve.io_llminferenceservices.yaml b/charts/llmisvc-crd/templates/serving.kserve.io_llminferenceservices.yaml new file mode 100644 index 00000000000..9e7e4d68a74 --- /dev/null +++ b/charts/llmisvc-crd/templates/serving.kserve.io_llminferenceservices.yaml @@ -0,0 +1,19623 @@ +--- +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + annotations: + controller-gen.kubebuilder.io/version: v0.16.2 + name: llminferenceservices.serving.kserve.io +spec: + group: serving.kserve.io + names: + kind: LLMInferenceService + listKind: LLMInferenceServiceList + plural: llminferenceservices + shortNames: + - llmisvc + singular: llminferenceservice + scope: Namespaced + versions: + - additionalPrinterColumns: + - jsonPath: .status.url + name: URL + type: string + - jsonPath: .status.conditions[?(@.type=='Ready')].status + name: Ready + type: string + - jsonPath: .status.conditions[?(@.type=='Ready')].reason + name: Reason + type: string + - jsonPath: .metadata.creationTimestamp + name: Age + type: date + - jsonPath: .status.addresses[*].url + name: URLs + priority: 1 + type: string + name: v1alpha1 + schema: + openAPIV3Schema: + properties: + apiVersion: + type: string + kind: + type: string + metadata: + type: object + spec: + properties: + baseRefs: + items: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + type: array + model: + properties: + criticality: + enum: + - Critical + - Standard + - Sheddable + type: string + lora: + properties: + adapters: + items: + properties: + framework: + type: string + memory: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + storageUri: + type: string + required: + - framework + - memory + - storageUri + type: object + type: array + type: object + name: + type: string + storage: + properties: + key: + type: string + parameters: + additionalProperties: + type: string + type: object + path: + type: string + type: object + uri: + type: string + required: + - uri + type: object + parallelism: + properties: + pipeline: + format: int64 + type: integer + tensor: + format: int64 + type: integer + type: object + prefill: + properties: + parallelism: + properties: + pipeline: + format: int64 + type: integer + tensor: + format: int64 + type: integer + type: object + replicas: + format: int32 + type: integer + template: + properties: + activeDeadlineSeconds: + format: int64 + type: integer + affinity: + properties: + nodeAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + preference: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + weight: + format: int32 + type: integer + required: + - preference + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + properties: + nodeSelectorTerms: + items: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + type: array + x-kubernetes-list-type: atomic + required: + - nodeSelectorTerms + type: object + x-kubernetes-map-type: atomic + type: object + podAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + podAntiAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + type: object + automountServiceAccountToken: + type: boolean + containers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + dnsConfig: + properties: + nameservers: + items: + type: string + type: array + x-kubernetes-list-type: atomic + options: + items: + properties: + name: + type: string + value: + type: string + type: object + type: array + x-kubernetes-list-type: atomic + searches: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + dnsPolicy: + type: string + enableServiceLinks: + type: boolean + ephemeralContainers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + targetContainerName: + type: string + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + hostAliases: + items: + properties: + hostnames: + items: + type: string + type: array + x-kubernetes-list-type: atomic + ip: + type: string + required: + - ip + type: object + type: array + x-kubernetes-list-map-keys: + - ip + x-kubernetes-list-type: map + hostIPC: + type: boolean + hostNetwork: + type: boolean + hostPID: + type: boolean + hostUsers: + type: boolean + hostname: + type: string + imagePullSecrets: + items: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + initContainers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + nodeName: + type: string + nodeSelector: + additionalProperties: + type: string + type: object + x-kubernetes-map-type: atomic + os: + properties: + name: + type: string + required: + - name + type: object + overhead: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + preemptionPolicy: + type: string + priority: + format: int32 + type: integer + priorityClassName: + type: string + readinessGates: + items: + properties: + conditionType: + type: string + required: + - conditionType + type: object + type: array + x-kubernetes-list-type: atomic + resourceClaims: + items: + properties: + name: + type: string + resourceClaimName: + type: string + resourceClaimTemplateName: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + runtimeClassName: + type: string + schedulerName: + type: string + schedulingGates: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + securityContext: + properties: + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + fsGroup: + format: int64 + type: integer + fsGroupChangePolicy: + type: string + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxChangePolicy: + type: string + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + supplementalGroups: + items: + format: int64 + type: integer + type: array + x-kubernetes-list-type: atomic + supplementalGroupsPolicy: + type: string + sysctls: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + serviceAccount: + type: string + serviceAccountName: + type: string + setHostnameAsFQDN: + type: boolean + shareProcessNamespace: + type: boolean + subdomain: + type: string + terminationGracePeriodSeconds: + format: int64 + type: integer + tolerations: + items: + properties: + effect: + type: string + key: + type: string + operator: + type: string + tolerationSeconds: + format: int64 + type: integer + value: + type: string + type: object + type: array + x-kubernetes-list-type: atomic + topologySpreadConstraints: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + maxSkew: + format: int32 + type: integer + minDomains: + format: int32 + type: integer + nodeAffinityPolicy: + type: string + nodeTaintsPolicy: + type: string + topologyKey: + type: string + whenUnsatisfiable: + type: string + required: + - maxSkew + - topologyKey + - whenUnsatisfiable + type: object + type: array + x-kubernetes-list-map-keys: + - topologyKey + - whenUnsatisfiable + x-kubernetes-list-type: map + volumes: + items: + properties: + awsElasticBlockStore: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + azureDisk: + properties: + cachingMode: + type: string + diskName: + type: string + diskURI: + type: string + fsType: + default: ext4 + type: string + kind: + type: string + readOnly: + default: false + type: boolean + required: + - diskName + - diskURI + type: object + azureFile: + properties: + readOnly: + type: boolean + secretName: + type: string + shareName: + type: string + required: + - secretName + - shareName + type: object + cephfs: + properties: + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + path: + type: string + readOnly: + type: boolean + secretFile: + type: string + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + type: string + required: + - monitors + type: object + cinder: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeID: + type: string + required: + - volumeID + type: object + configMap: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + csi: + properties: + driver: + type: string + fsType: + type: string + nodePublishSecretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + readOnly: + type: boolean + volumeAttributes: + additionalProperties: + type: string + type: object + required: + - driver + type: object + downwardAPI: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + emptyDir: + properties: + medium: + type: string + sizeLimit: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + ephemeral: + properties: + volumeClaimTemplate: + properties: + metadata: + type: object + spec: + properties: + accessModes: + items: + type: string + type: array + x-kubernetes-list-type: atomic + dataSource: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + required: + - kind + - name + type: object + x-kubernetes-map-type: atomic + dataSourceRef: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + namespace: + type: string + required: + - kind + - name + type: object + resources: + properties: + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + selector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + storageClassName: + type: string + volumeAttributesClassName: + type: string + volumeMode: + type: string + volumeName: + type: string + type: object + required: + - spec + type: object + type: object + fc: + properties: + fsType: + type: string + lun: + format: int32 + type: integer + readOnly: + type: boolean + targetWWNs: + items: + type: string + type: array + x-kubernetes-list-type: atomic + wwids: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + flexVolume: + properties: + driver: + type: string + fsType: + type: string + options: + additionalProperties: + type: string + type: object + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + required: + - driver + type: object + flocker: + properties: + datasetName: + type: string + datasetUUID: + type: string + type: object + gcePersistentDisk: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + pdName: + type: string + readOnly: + type: boolean + required: + - pdName + type: object + gitRepo: + properties: + directory: + type: string + repository: + type: string + revision: + type: string + required: + - repository + type: object + glusterfs: + properties: + endpoints: + type: string + path: + type: string + readOnly: + type: boolean + required: + - endpoints + - path + type: object + hostPath: + properties: + path: + type: string + type: + type: string + required: + - path + type: object + image: + properties: + pullPolicy: + type: string + reference: + type: string + type: object + iscsi: + properties: + chapAuthDiscovery: + type: boolean + chapAuthSession: + type: boolean + fsType: + type: string + initiatorName: + type: string + iqn: + type: string + iscsiInterface: + default: default + type: string + lun: + format: int32 + type: integer + portals: + items: + type: string + type: array + x-kubernetes-list-type: atomic + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + targetPortal: + type: string + required: + - iqn + - lun + - targetPortal + type: object + name: + type: string + nfs: + properties: + path: + type: string + readOnly: + type: boolean + server: + type: string + required: + - path + - server + type: object + persistentVolumeClaim: + properties: + claimName: + type: string + readOnly: + type: boolean + required: + - claimName + type: object + photonPersistentDisk: + properties: + fsType: + type: string + pdID: + type: string + required: + - pdID + type: object + portworxVolume: + properties: + fsType: + type: string + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + projected: + properties: + defaultMode: + format: int32 + type: integer + sources: + items: + properties: + clusterTrustBundle: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + name: + type: string + optional: + type: boolean + path: + type: string + signerName: + type: string + required: + - path + type: object + configMap: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + downwardAPI: + properties: + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + secret: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + serviceAccountToken: + properties: + audience: + type: string + expirationSeconds: + format: int64 + type: integer + path: + type: string + required: + - path + type: object + type: object + type: array + x-kubernetes-list-type: atomic + type: object + quobyte: + properties: + group: + type: string + readOnly: + type: boolean + registry: + type: string + tenant: + type: string + user: + type: string + volume: + type: string + required: + - registry + - volume + type: object + rbd: + properties: + fsType: + type: string + image: + type: string + keyring: + default: /etc/ceph/keyring + type: string + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + pool: + default: rbd + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + default: admin + type: string + required: + - image + - monitors + type: object + scaleIO: + properties: + fsType: + default: xfs + type: string + gateway: + type: string + protectionDomain: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + sslEnabled: + type: boolean + storageMode: + default: ThinProvisioned + type: string + storagePool: + type: string + system: + type: string + volumeName: + type: string + required: + - gateway + - secretRef + - system + type: object + secret: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + optional: + type: boolean + secretName: + type: string + type: object + storageos: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeName: + type: string + volumeNamespace: + type: string + type: object + vsphereVolume: + properties: + fsType: + type: string + storagePolicyID: + type: string + storagePolicyName: + type: string + volumePath: + type: string + required: + - volumePath + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + required: + - containers + type: object + worker: + properties: + activeDeadlineSeconds: + format: int64 + type: integer + affinity: + properties: + nodeAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + preference: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + weight: + format: int32 + type: integer + required: + - preference + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + properties: + nodeSelectorTerms: + items: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + type: array + x-kubernetes-list-type: atomic + required: + - nodeSelectorTerms + type: object + x-kubernetes-map-type: atomic + type: object + podAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + podAntiAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + type: object + automountServiceAccountToken: + type: boolean + containers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + dnsConfig: + properties: + nameservers: + items: + type: string + type: array + x-kubernetes-list-type: atomic + options: + items: + properties: + name: + type: string + value: + type: string + type: object + type: array + x-kubernetes-list-type: atomic + searches: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + dnsPolicy: + type: string + enableServiceLinks: + type: boolean + ephemeralContainers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + targetContainerName: + type: string + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + hostAliases: + items: + properties: + hostnames: + items: + type: string + type: array + x-kubernetes-list-type: atomic + ip: + type: string + required: + - ip + type: object + type: array + x-kubernetes-list-map-keys: + - ip + x-kubernetes-list-type: map + hostIPC: + type: boolean + hostNetwork: + type: boolean + hostPID: + type: boolean + hostUsers: + type: boolean + hostname: + type: string + imagePullSecrets: + items: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + initContainers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + nodeName: + type: string + nodeSelector: + additionalProperties: + type: string + type: object + x-kubernetes-map-type: atomic + os: + properties: + name: + type: string + required: + - name + type: object + overhead: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + preemptionPolicy: + type: string + priority: + format: int32 + type: integer + priorityClassName: + type: string + readinessGates: + items: + properties: + conditionType: + type: string + required: + - conditionType + type: object + type: array + x-kubernetes-list-type: atomic + resourceClaims: + items: + properties: + name: + type: string + resourceClaimName: + type: string + resourceClaimTemplateName: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + runtimeClassName: + type: string + schedulerName: + type: string + schedulingGates: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + securityContext: + properties: + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + fsGroup: + format: int64 + type: integer + fsGroupChangePolicy: + type: string + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxChangePolicy: + type: string + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + supplementalGroups: + items: + format: int64 + type: integer + type: array + x-kubernetes-list-type: atomic + supplementalGroupsPolicy: + type: string + sysctls: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + serviceAccount: + type: string + serviceAccountName: + type: string + setHostnameAsFQDN: + type: boolean + shareProcessNamespace: + type: boolean + subdomain: + type: string + terminationGracePeriodSeconds: + format: int64 + type: integer + tolerations: + items: + properties: + effect: + type: string + key: + type: string + operator: + type: string + tolerationSeconds: + format: int64 + type: integer + value: + type: string + type: object + type: array + x-kubernetes-list-type: atomic + topologySpreadConstraints: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + maxSkew: + format: int32 + type: integer + minDomains: + format: int32 + type: integer + nodeAffinityPolicy: + type: string + nodeTaintsPolicy: + type: string + topologyKey: + type: string + whenUnsatisfiable: + type: string + required: + - maxSkew + - topologyKey + - whenUnsatisfiable + type: object + type: array + x-kubernetes-list-map-keys: + - topologyKey + - whenUnsatisfiable + x-kubernetes-list-type: map + volumes: + items: + properties: + awsElasticBlockStore: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + azureDisk: + properties: + cachingMode: + type: string + diskName: + type: string + diskURI: + type: string + fsType: + default: ext4 + type: string + kind: + type: string + readOnly: + default: false + type: boolean + required: + - diskName + - diskURI + type: object + azureFile: + properties: + readOnly: + type: boolean + secretName: + type: string + shareName: + type: string + required: + - secretName + - shareName + type: object + cephfs: + properties: + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + path: + type: string + readOnly: + type: boolean + secretFile: + type: string + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + type: string + required: + - monitors + type: object + cinder: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeID: + type: string + required: + - volumeID + type: object + configMap: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + csi: + properties: + driver: + type: string + fsType: + type: string + nodePublishSecretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + readOnly: + type: boolean + volumeAttributes: + additionalProperties: + type: string + type: object + required: + - driver + type: object + downwardAPI: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + emptyDir: + properties: + medium: + type: string + sizeLimit: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + ephemeral: + properties: + volumeClaimTemplate: + properties: + metadata: + type: object + spec: + properties: + accessModes: + items: + type: string + type: array + x-kubernetes-list-type: atomic + dataSource: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + required: + - kind + - name + type: object + x-kubernetes-map-type: atomic + dataSourceRef: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + namespace: + type: string + required: + - kind + - name + type: object + resources: + properties: + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + selector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + storageClassName: + type: string + volumeAttributesClassName: + type: string + volumeMode: + type: string + volumeName: + type: string + type: object + required: + - spec + type: object + type: object + fc: + properties: + fsType: + type: string + lun: + format: int32 + type: integer + readOnly: + type: boolean + targetWWNs: + items: + type: string + type: array + x-kubernetes-list-type: atomic + wwids: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + flexVolume: + properties: + driver: + type: string + fsType: + type: string + options: + additionalProperties: + type: string + type: object + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + required: + - driver + type: object + flocker: + properties: + datasetName: + type: string + datasetUUID: + type: string + type: object + gcePersistentDisk: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + pdName: + type: string + readOnly: + type: boolean + required: + - pdName + type: object + gitRepo: + properties: + directory: + type: string + repository: + type: string + revision: + type: string + required: + - repository + type: object + glusterfs: + properties: + endpoints: + type: string + path: + type: string + readOnly: + type: boolean + required: + - endpoints + - path + type: object + hostPath: + properties: + path: + type: string + type: + type: string + required: + - path + type: object + image: + properties: + pullPolicy: + type: string + reference: + type: string + type: object + iscsi: + properties: + chapAuthDiscovery: + type: boolean + chapAuthSession: + type: boolean + fsType: + type: string + initiatorName: + type: string + iqn: + type: string + iscsiInterface: + default: default + type: string + lun: + format: int32 + type: integer + portals: + items: + type: string + type: array + x-kubernetes-list-type: atomic + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + targetPortal: + type: string + required: + - iqn + - lun + - targetPortal + type: object + name: + type: string + nfs: + properties: + path: + type: string + readOnly: + type: boolean + server: + type: string + required: + - path + - server + type: object + persistentVolumeClaim: + properties: + claimName: + type: string + readOnly: + type: boolean + required: + - claimName + type: object + photonPersistentDisk: + properties: + fsType: + type: string + pdID: + type: string + required: + - pdID + type: object + portworxVolume: + properties: + fsType: + type: string + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + projected: + properties: + defaultMode: + format: int32 + type: integer + sources: + items: + properties: + clusterTrustBundle: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + name: + type: string + optional: + type: boolean + path: + type: string + signerName: + type: string + required: + - path + type: object + configMap: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + downwardAPI: + properties: + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + secret: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + serviceAccountToken: + properties: + audience: + type: string + expirationSeconds: + format: int64 + type: integer + path: + type: string + required: + - path + type: object + type: object + type: array + x-kubernetes-list-type: atomic + type: object + quobyte: + properties: + group: + type: string + readOnly: + type: boolean + registry: + type: string + tenant: + type: string + user: + type: string + volume: + type: string + required: + - registry + - volume + type: object + rbd: + properties: + fsType: + type: string + image: + type: string + keyring: + default: /etc/ceph/keyring + type: string + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + pool: + default: rbd + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + default: admin + type: string + required: + - image + - monitors + type: object + scaleIO: + properties: + fsType: + default: xfs + type: string + gateway: + type: string + protectionDomain: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + sslEnabled: + type: boolean + storageMode: + default: ThinProvisioned + type: string + storagePool: + type: string + system: + type: string + volumeName: + type: string + required: + - gateway + - secretRef + - system + type: object + secret: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + optional: + type: boolean + secretName: + type: string + type: object + storageos: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeName: + type: string + volumeNamespace: + type: string + type: object + vsphereVolume: + properties: + fsType: + type: string + storagePolicyID: + type: string + storagePolicyName: + type: string + volumePath: + type: string + required: + - volumePath + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + required: + - containers + type: object + type: object + replicas: + format: int32 + type: integer + router: + properties: + gateway: + properties: + refs: + items: + properties: + name: + maxLength: 253 + minLength: 1 + type: string + namespace: + maxLength: 63 + minLength: 1 + pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$ + type: string + type: object + type: array + type: object + ingress: + properties: + refs: + items: + properties: + name: + maxLength: 253 + minLength: 1 + type: string + namespace: + maxLength: 63 + minLength: 1 + pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$ + type: string + type: object + type: array + type: object + route: + properties: + http: + properties: + refs: + items: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + type: array + spec: + properties: + hostnames: + items: + maxLength: 253 + minLength: 1 + pattern: ^(\*\.)?[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + maxItems: 16 + type: array + parentRefs: + items: + properties: + group: + default: gateway.networking.k8s.io + maxLength: 253 + pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + kind: + default: Gateway + maxLength: 63 + minLength: 1 + pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$ + type: string + name: + maxLength: 253 + minLength: 1 + type: string + namespace: + maxLength: 63 + minLength: 1 + pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$ + type: string + port: + format: int32 + maximum: 65535 + minimum: 1 + type: integer + sectionName: + maxLength: 253 + minLength: 1 + pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + required: + - name + type: object + maxItems: 32 + type: array + rules: + default: + - matches: + - path: + type: PathPrefix + value: / + items: + properties: + backendRefs: + items: + properties: + filters: + items: + properties: + extensionRef: + properties: + group: + maxLength: 253 + pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + kind: + maxLength: 63 + minLength: 1 + pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$ + type: string + name: + maxLength: 253 + minLength: 1 + type: string + required: + - group + - kind + - name + type: object + requestHeaderModifier: + properties: + add: + items: + properties: + name: + maxLength: 256 + minLength: 1 + pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$ + type: string + value: + maxLength: 4096 + minLength: 1 + type: string + required: + - name + - value + type: object + maxItems: 16 + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + remove: + items: + type: string + maxItems: 16 + type: array + x-kubernetes-list-type: set + set: + items: + properties: + name: + maxLength: 256 + minLength: 1 + pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$ + type: string + value: + maxLength: 4096 + minLength: 1 + type: string + required: + - name + - value + type: object + maxItems: 16 + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + type: object + requestMirror: + properties: + backendRef: + properties: + group: + default: "" + maxLength: 253 + pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + kind: + default: Service + maxLength: 63 + minLength: 1 + pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$ + type: string + name: + maxLength: 253 + minLength: 1 + type: string + namespace: + maxLength: 63 + minLength: 1 + pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$ + type: string + port: + format: int32 + maximum: 65535 + minimum: 1 + type: integer + required: + - name + type: object + x-kubernetes-validations: + - message: Must have port for + Service reference + rule: '(size(self.group) == + 0 && self.kind == ''Service'') + ? has(self.port) : true' + fraction: + properties: + denominator: + default: 100 + format: int32 + minimum: 1 + type: integer + numerator: + format: int32 + minimum: 0 + type: integer + required: + - numerator + type: object + x-kubernetes-validations: + - message: numerator must be + less than or equal to denominator + rule: self.numerator <= self.denominator + percent: + format: int32 + maximum: 100 + minimum: 0 + type: integer + required: + - backendRef + type: object + requestRedirect: + properties: + hostname: + maxLength: 253 + minLength: 1 + pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + path: + properties: + replaceFullPath: + maxLength: 1024 + type: string + replacePrefixMatch: + maxLength: 1024 + type: string + type: + enum: + - ReplaceFullPath + - ReplacePrefixMatch + type: string + required: + - type + type: object + x-kubernetes-validations: + - message: replaceFullPath must + be specified when type is + set to 'ReplaceFullPath' + rule: 'self.type == ''ReplaceFullPath'' + ? has(self.replaceFullPath) + : true' + - message: type must be 'ReplaceFullPath' + when replaceFullPath is + set + rule: 'has(self.replaceFullPath) + ? self.type == ''ReplaceFullPath'' + : true' + - message: replacePrefixMatch + must be specified when type + is set to 'ReplacePrefixMatch' + rule: 'self.type == ''ReplacePrefixMatch'' + ? has(self.replacePrefixMatch) + : true' + - message: type must be 'ReplacePrefixMatch' + when replacePrefixMatch + is set + rule: 'has(self.replacePrefixMatch) + ? self.type == ''ReplacePrefixMatch'' + : true' + port: + format: int32 + maximum: 65535 + minimum: 1 + type: integer + scheme: + enum: + - http + - https + type: string + statusCode: + default: 302 + enum: + - 301 + - 302 + type: integer + type: object + responseHeaderModifier: + properties: + add: + items: + properties: + name: + maxLength: 256 + minLength: 1 + pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$ + type: string + value: + maxLength: 4096 + minLength: 1 + type: string + required: + - name + - value + type: object + maxItems: 16 + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + remove: + items: + type: string + maxItems: 16 + type: array + x-kubernetes-list-type: set + set: + items: + properties: + name: + maxLength: 256 + minLength: 1 + pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$ + type: string + value: + maxLength: 4096 + minLength: 1 + type: string + required: + - name + - value + type: object + maxItems: 16 + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + type: object + type: + enum: + - RequestHeaderModifier + - ResponseHeaderModifier + - RequestMirror + - RequestRedirect + - URLRewrite + - ExtensionRef + type: string + urlRewrite: + properties: + hostname: + maxLength: 253 + minLength: 1 + pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + path: + properties: + replaceFullPath: + maxLength: 1024 + type: string + replacePrefixMatch: + maxLength: 1024 + type: string + type: + enum: + - ReplaceFullPath + - ReplacePrefixMatch + type: string + required: + - type + type: object + x-kubernetes-validations: + - message: replaceFullPath must + be specified when type is + set to 'ReplaceFullPath' + rule: 'self.type == ''ReplaceFullPath'' + ? has(self.replaceFullPath) + : true' + - message: type must be 'ReplaceFullPath' + when replaceFullPath is + set + rule: 'has(self.replaceFullPath) + ? self.type == ''ReplaceFullPath'' + : true' + - message: replacePrefixMatch + must be specified when type + is set to 'ReplacePrefixMatch' + rule: 'self.type == ''ReplacePrefixMatch'' + ? has(self.replacePrefixMatch) + : true' + - message: type must be 'ReplacePrefixMatch' + when replacePrefixMatch + is set + rule: 'has(self.replacePrefixMatch) + ? self.type == ''ReplacePrefixMatch'' + : true' + type: object + required: + - type + type: object + x-kubernetes-validations: + - message: filter.requestHeaderModifier + must be nil if the filter.type is + not RequestHeaderModifier + rule: '!(has(self.requestHeaderModifier) + && self.type != ''RequestHeaderModifier'')' + - message: filter.requestHeaderModifier + must be specified for RequestHeaderModifier + filter.type + rule: '!(!has(self.requestHeaderModifier) + && self.type == ''RequestHeaderModifier'')' + - message: filter.responseHeaderModifier + must be nil if the filter.type is + not ResponseHeaderModifier + rule: '!(has(self.responseHeaderModifier) + && self.type != ''ResponseHeaderModifier'')' + - message: filter.responseHeaderModifier + must be specified for ResponseHeaderModifier + filter.type + rule: '!(!has(self.responseHeaderModifier) + && self.type == ''ResponseHeaderModifier'')' + - message: filter.requestMirror must + be nil if the filter.type is not + RequestMirror + rule: '!(has(self.requestMirror) && + self.type != ''RequestMirror'')' + - message: filter.requestMirror must + be specified for RequestMirror filter.type + rule: '!(!has(self.requestMirror) + && self.type == ''RequestMirror'')' + - message: filter.requestRedirect must + be nil if the filter.type is not + RequestRedirect + rule: '!(has(self.requestRedirect) + && self.type != ''RequestRedirect'')' + - message: filter.requestRedirect must + be specified for RequestRedirect + filter.type + rule: '!(!has(self.requestRedirect) + && self.type == ''RequestRedirect'')' + - message: filter.urlRewrite must be + nil if the filter.type is not URLRewrite + rule: '!(has(self.urlRewrite) && self.type + != ''URLRewrite'')' + - message: filter.urlRewrite must be + specified for URLRewrite filter.type + rule: '!(!has(self.urlRewrite) && + self.type == ''URLRewrite'')' + - message: filter.extensionRef must + be nil if the filter.type is not + ExtensionRef + rule: '!(has(self.extensionRef) && + self.type != ''ExtensionRef'')' + - message: filter.extensionRef must + be specified for ExtensionRef filter.type + rule: '!(!has(self.extensionRef) && + self.type == ''ExtensionRef'')' + maxItems: 16 + type: array + x-kubernetes-validations: + - message: May specify either httpRouteFilterRequestRedirect + or httpRouteFilterRequestRewrite, + but not both + rule: '!(self.exists(f, f.type == ''RequestRedirect'') + && self.exists(f, f.type == ''URLRewrite''))' + - message: May specify either httpRouteFilterRequestRedirect + or httpRouteFilterRequestRewrite, + but not both + rule: '!(self.exists(f, f.type == ''RequestRedirect'') + && self.exists(f, f.type == ''URLRewrite''))' + - message: RequestHeaderModifier filter + cannot be repeated + rule: self.filter(f, f.type == 'RequestHeaderModifier').size() + <= 1 + - message: ResponseHeaderModifier filter + cannot be repeated + rule: self.filter(f, f.type == 'ResponseHeaderModifier').size() + <= 1 + - message: RequestRedirect filter cannot + be repeated + rule: self.filter(f, f.type == 'RequestRedirect').size() + <= 1 + - message: URLRewrite filter cannot be + repeated + rule: self.filter(f, f.type == 'URLRewrite').size() + <= 1 + group: + default: "" + maxLength: 253 + pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + kind: + default: Service + maxLength: 63 + minLength: 1 + pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$ + type: string + name: + maxLength: 253 + minLength: 1 + type: string + namespace: + maxLength: 63 + minLength: 1 + pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$ + type: string + port: + format: int32 + maximum: 65535 + minimum: 1 + type: integer + weight: + default: 1 + format: int32 + maximum: 1000000 + minimum: 0 + type: integer + required: + - name + type: object + x-kubernetes-validations: + - message: Must have port for Service reference + rule: '(size(self.group) == 0 && self.kind + == ''Service'') ? has(self.port) : true' + maxItems: 16 + type: array + filters: + items: + properties: + extensionRef: + properties: + group: + maxLength: 253 + pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + kind: + maxLength: 63 + minLength: 1 + pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$ + type: string + name: + maxLength: 253 + minLength: 1 + type: string + required: + - group + - kind + - name + type: object + requestHeaderModifier: + properties: + add: + items: + properties: + name: + maxLength: 256 + minLength: 1 + pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$ + type: string + value: + maxLength: 4096 + minLength: 1 + type: string + required: + - name + - value + type: object + maxItems: 16 + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + remove: + items: + type: string + maxItems: 16 + type: array + x-kubernetes-list-type: set + set: + items: + properties: + name: + maxLength: 256 + minLength: 1 + pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$ + type: string + value: + maxLength: 4096 + minLength: 1 + type: string + required: + - name + - value + type: object + maxItems: 16 + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + type: object + requestMirror: + properties: + backendRef: + properties: + group: + default: "" + maxLength: 253 + pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + kind: + default: Service + maxLength: 63 + minLength: 1 + pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$ + type: string + name: + maxLength: 253 + minLength: 1 + type: string + namespace: + maxLength: 63 + minLength: 1 + pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$ + type: string + port: + format: int32 + maximum: 65535 + minimum: 1 + type: integer + required: + - name + type: object + x-kubernetes-validations: + - message: Must have port for Service + reference + rule: '(size(self.group) == 0 && + self.kind == ''Service'') ? has(self.port) + : true' + fraction: + properties: + denominator: + default: 100 + format: int32 + minimum: 1 + type: integer + numerator: + format: int32 + minimum: 0 + type: integer + required: + - numerator + type: object + x-kubernetes-validations: + - message: numerator must be less + than or equal to denominator + rule: self.numerator <= self.denominator + percent: + format: int32 + maximum: 100 + minimum: 0 + type: integer + required: + - backendRef + type: object + requestRedirect: + properties: + hostname: + maxLength: 253 + minLength: 1 + pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + path: + properties: + replaceFullPath: + maxLength: 1024 + type: string + replacePrefixMatch: + maxLength: 1024 + type: string + type: + enum: + - ReplaceFullPath + - ReplacePrefixMatch + type: string + required: + - type + type: object + x-kubernetes-validations: + - message: replaceFullPath must be + specified when type is set to + 'ReplaceFullPath' + rule: 'self.type == ''ReplaceFullPath'' + ? has(self.replaceFullPath) : + true' + - message: type must be 'ReplaceFullPath' + when replaceFullPath is set + rule: 'has(self.replaceFullPath) + ? self.type == ''ReplaceFullPath'' + : true' + - message: replacePrefixMatch must + be specified when type is set + to 'ReplacePrefixMatch' + rule: 'self.type == ''ReplacePrefixMatch'' + ? has(self.replacePrefixMatch) + : true' + - message: type must be 'ReplacePrefixMatch' + when replacePrefixMatch is set + rule: 'has(self.replacePrefixMatch) + ? self.type == ''ReplacePrefixMatch'' + : true' + port: + format: int32 + maximum: 65535 + minimum: 1 + type: integer + scheme: + enum: + - http + - https + type: string + statusCode: + default: 302 + enum: + - 301 + - 302 + type: integer + type: object + responseHeaderModifier: + properties: + add: + items: + properties: + name: + maxLength: 256 + minLength: 1 + pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$ + type: string + value: + maxLength: 4096 + minLength: 1 + type: string + required: + - name + - value + type: object + maxItems: 16 + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + remove: + items: + type: string + maxItems: 16 + type: array + x-kubernetes-list-type: set + set: + items: + properties: + name: + maxLength: 256 + minLength: 1 + pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$ + type: string + value: + maxLength: 4096 + minLength: 1 + type: string + required: + - name + - value + type: object + maxItems: 16 + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + type: object + type: + enum: + - RequestHeaderModifier + - ResponseHeaderModifier + - RequestMirror + - RequestRedirect + - URLRewrite + - ExtensionRef + type: string + urlRewrite: + properties: + hostname: + maxLength: 253 + minLength: 1 + pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + path: + properties: + replaceFullPath: + maxLength: 1024 + type: string + replacePrefixMatch: + maxLength: 1024 + type: string + type: + enum: + - ReplaceFullPath + - ReplacePrefixMatch + type: string + required: + - type + type: object + x-kubernetes-validations: + - message: replaceFullPath must be + specified when type is set to + 'ReplaceFullPath' + rule: 'self.type == ''ReplaceFullPath'' + ? has(self.replaceFullPath) : + true' + - message: type must be 'ReplaceFullPath' + when replaceFullPath is set + rule: 'has(self.replaceFullPath) + ? self.type == ''ReplaceFullPath'' + : true' + - message: replacePrefixMatch must + be specified when type is set + to 'ReplacePrefixMatch' + rule: 'self.type == ''ReplacePrefixMatch'' + ? has(self.replacePrefixMatch) + : true' + - message: type must be 'ReplacePrefixMatch' + when replacePrefixMatch is set + rule: 'has(self.replacePrefixMatch) + ? self.type == ''ReplacePrefixMatch'' + : true' + type: object + required: + - type + type: object + x-kubernetes-validations: + - message: filter.requestHeaderModifier must + be nil if the filter.type is not RequestHeaderModifier + rule: '!(has(self.requestHeaderModifier) + && self.type != ''RequestHeaderModifier'')' + - message: filter.requestHeaderModifier must + be specified for RequestHeaderModifier + filter.type + rule: '!(!has(self.requestHeaderModifier) + && self.type == ''RequestHeaderModifier'')' + - message: filter.responseHeaderModifier must + be nil if the filter.type is not ResponseHeaderModifier + rule: '!(has(self.responseHeaderModifier) + && self.type != ''ResponseHeaderModifier'')' + - message: filter.responseHeaderModifier must + be specified for ResponseHeaderModifier + filter.type + rule: '!(!has(self.responseHeaderModifier) + && self.type == ''ResponseHeaderModifier'')' + - message: filter.requestMirror must be nil + if the filter.type is not RequestMirror + rule: '!(has(self.requestMirror) && self.type + != ''RequestMirror'')' + - message: filter.requestMirror must be specified + for RequestMirror filter.type + rule: '!(!has(self.requestMirror) && self.type + == ''RequestMirror'')' + - message: filter.requestRedirect must be + nil if the filter.type is not RequestRedirect + rule: '!(has(self.requestRedirect) && self.type + != ''RequestRedirect'')' + - message: filter.requestRedirect must be + specified for RequestRedirect filter.type + rule: '!(!has(self.requestRedirect) && self.type + == ''RequestRedirect'')' + - message: filter.urlRewrite must be nil if + the filter.type is not URLRewrite + rule: '!(has(self.urlRewrite) && self.type + != ''URLRewrite'')' + - message: filter.urlRewrite must be specified + for URLRewrite filter.type + rule: '!(!has(self.urlRewrite) && self.type + == ''URLRewrite'')' + - message: filter.extensionRef must be nil + if the filter.type is not ExtensionRef + rule: '!(has(self.extensionRef) && self.type + != ''ExtensionRef'')' + - message: filter.extensionRef must be specified + for ExtensionRef filter.type + rule: '!(!has(self.extensionRef) && self.type + == ''ExtensionRef'')' + maxItems: 16 + type: array + x-kubernetes-validations: + - message: May specify either httpRouteFilterRequestRedirect + or httpRouteFilterRequestRewrite, but not + both + rule: '!(self.exists(f, f.type == ''RequestRedirect'') + && self.exists(f, f.type == ''URLRewrite''))' + - message: RequestHeaderModifier filter cannot + be repeated + rule: self.filter(f, f.type == 'RequestHeaderModifier').size() + <= 1 + - message: ResponseHeaderModifier filter cannot + be repeated + rule: self.filter(f, f.type == 'ResponseHeaderModifier').size() + <= 1 + - message: RequestRedirect filter cannot be + repeated + rule: self.filter(f, f.type == 'RequestRedirect').size() + <= 1 + - message: URLRewrite filter cannot be repeated + rule: self.filter(f, f.type == 'URLRewrite').size() + <= 1 + matches: + default: + - path: + type: PathPrefix + value: / + items: + properties: + headers: + items: + properties: + name: + maxLength: 256 + minLength: 1 + pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$ + type: string + type: + default: Exact + enum: + - Exact + - RegularExpression + type: string + value: + maxLength: 4096 + minLength: 1 + type: string + required: + - name + - value + type: object + maxItems: 16 + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + method: + enum: + - GET + - HEAD + - POST + - PUT + - DELETE + - CONNECT + - OPTIONS + - TRACE + - PATCH + type: string + path: + default: + type: PathPrefix + value: / + properties: + type: + default: PathPrefix + enum: + - Exact + - PathPrefix + - RegularExpression + type: string + value: + default: / + maxLength: 1024 + type: string + type: object + x-kubernetes-validations: + - message: value must be an absolute path + and start with '/' when type one of + ['Exact', 'PathPrefix'] + rule: '(self.type in [''Exact'',''PathPrefix'']) + ? self.value.startsWith(''/'') : true' + - message: must not contain '//' when + type one of ['Exact', 'PathPrefix'] + rule: '(self.type in [''Exact'',''PathPrefix'']) + ? !self.value.contains(''//'') : true' + - message: must not contain '/./' when + type one of ['Exact', 'PathPrefix'] + rule: '(self.type in [''Exact'',''PathPrefix'']) + ? !self.value.contains(''/./'') : + true' + - message: must not contain '/../' when + type one of ['Exact', 'PathPrefix'] + rule: '(self.type in [''Exact'',''PathPrefix'']) + ? !self.value.contains(''/../'') : + true' + - message: must not contain '%2f' when + type one of ['Exact', 'PathPrefix'] + rule: '(self.type in [''Exact'',''PathPrefix'']) + ? !self.value.contains(''%2f'') : + true' + - message: must not contain '%2F' when + type one of ['Exact', 'PathPrefix'] + rule: '(self.type in [''Exact'',''PathPrefix'']) + ? !self.value.contains(''%2F'') : + true' + - message: must not contain '#' when type + one of ['Exact', 'PathPrefix'] + rule: '(self.type in [''Exact'',''PathPrefix'']) + ? !self.value.contains(''#'') : true' + - message: must not end with '/..' when + type one of ['Exact', 'PathPrefix'] + rule: '(self.type in [''Exact'',''PathPrefix'']) + ? !self.value.endsWith(''/..'') : + true' + - message: must not end with '/.' when + type one of ['Exact', 'PathPrefix'] + rule: '(self.type in [''Exact'',''PathPrefix'']) + ? !self.value.endsWith(''/.'') : true' + - message: type must be one of ['Exact', + 'PathPrefix', 'RegularExpression'] + rule: self.type in ['Exact','PathPrefix'] + || self.type == 'RegularExpression' + - message: must only contain valid characters + (matching ^(?:[-A-Za-z0-9/._~!$&'()*+,;=:@]|[%][0-9a-fA-F]{2})+$) + for types ['Exact', 'PathPrefix'] + rule: '(self.type in [''Exact'',''PathPrefix'']) + ? self.value.matches(r"""^(?:[-A-Za-z0-9/._~!$&''()*+,;=:@]|[%][0-9a-fA-F]{2})+$""") + : true' + queryParams: + items: + properties: + name: + maxLength: 256 + minLength: 1 + pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$ + type: string + type: + default: Exact + enum: + - Exact + - RegularExpression + type: string + value: + maxLength: 1024 + minLength: 1 + type: string + required: + - name + - value + type: object + maxItems: 16 + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + type: object + maxItems: 64 + type: array + name: + maxLength: 253 + minLength: 1 + pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + retry: + properties: + attempts: + type: integer + backoff: + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + codes: + items: + maximum: 599 + minimum: 400 + type: integer + type: array + type: object + sessionPersistence: + properties: + absoluteTimeout: + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + cookieConfig: + properties: + lifetimeType: + default: Session + enum: + - Permanent + - Session + type: string + type: object + idleTimeout: + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + sessionName: + maxLength: 128 + type: string + type: + default: Cookie + enum: + - Cookie + - Header + type: string + type: object + x-kubernetes-validations: + - message: AbsoluteTimeout must be specified + when cookie lifetimeType is Permanent + rule: '!has(self.cookieConfig) || !has(self.cookieConfig.lifetimeType) + || self.cookieConfig.lifetimeType != ''Permanent'' + || has(self.absoluteTimeout)' + timeouts: + properties: + backendRequest: + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + request: + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object + x-kubernetes-validations: + - message: backendRequest timeout cannot be + longer than request timeout + rule: '!(has(self.request) && has(self.backendRequest) + && duration(self.request) != duration(''0s'') + && duration(self.backendRequest) > duration(self.request))' + type: object + x-kubernetes-validations: + - message: RequestRedirect filter must not be used + together with backendRefs + rule: '(has(self.backendRefs) && size(self.backendRefs) + > 0) ? (!has(self.filters) || self.filters.all(f, + !has(f.requestRedirect))): true' + - message: When using RequestRedirect filter with + path.replacePrefixMatch, exactly one PathPrefix + match must be specified + rule: '(has(self.filters) && self.filters.exists_one(f, + has(f.requestRedirect) && has(f.requestRedirect.path) + && f.requestRedirect.path.type == ''ReplacePrefixMatch'' + && has(f.requestRedirect.path.replacePrefixMatch))) + ? ((size(self.matches) != 1 || !has(self.matches[0].path) + || self.matches[0].path.type != ''PathPrefix'') + ? false : true) : true' + - message: When using URLRewrite filter with path.replacePrefixMatch, + exactly one PathPrefix match must be specified + rule: '(has(self.filters) && self.filters.exists_one(f, + has(f.urlRewrite) && has(f.urlRewrite.path) + && f.urlRewrite.path.type == ''ReplacePrefixMatch'' + && has(f.urlRewrite.path.replacePrefixMatch))) + ? ((size(self.matches) != 1 || !has(self.matches[0].path) + || self.matches[0].path.type != ''PathPrefix'') + ? false : true) : true' + - message: Within backendRefs, when using RequestRedirect + filter with path.replacePrefixMatch, exactly + one PathPrefix match must be specified + rule: '(has(self.backendRefs) && self.backendRefs.exists_one(b, + (has(b.filters) && b.filters.exists_one(f, has(f.requestRedirect) + && has(f.requestRedirect.path) && f.requestRedirect.path.type + == ''ReplacePrefixMatch'' && has(f.requestRedirect.path.replacePrefixMatch))) + )) ? ((size(self.matches) != 1 || !has(self.matches[0].path) + || self.matches[0].path.type != ''PathPrefix'') + ? false : true) : true' + - message: Within backendRefs, When using URLRewrite + filter with path.replacePrefixMatch, exactly + one PathPrefix match must be specified + rule: '(has(self.backendRefs) && self.backendRefs.exists_one(b, + (has(b.filters) && b.filters.exists_one(f, has(f.urlRewrite) + && has(f.urlRewrite.path) && f.urlRewrite.path.type + == ''ReplacePrefixMatch'' && has(f.urlRewrite.path.replacePrefixMatch))) + )) ? ((size(self.matches) != 1 || !has(self.matches[0].path) + || self.matches[0].path.type != ''PathPrefix'') + ? false : true) : true' + maxItems: 16 + type: array + x-kubernetes-validations: + - message: While 16 rules and 64 matches per rule + are allowed, the total number of matches across + all rules in a route must be less than 128 + rule: '(self.size() > 0 ? self[0].matches.size() + : 0) + (self.size() > 1 ? self[1].matches.size() + : 0) + (self.size() > 2 ? self[2].matches.size() + : 0) + (self.size() > 3 ? self[3].matches.size() + : 0) + (self.size() > 4 ? self[4].matches.size() + : 0) + (self.size() > 5 ? self[5].matches.size() + : 0) + (self.size() > 6 ? self[6].matches.size() + : 0) + (self.size() > 7 ? self[7].matches.size() + : 0) + (self.size() > 8 ? self[8].matches.size() + : 0) + (self.size() > 9 ? self[9].matches.size() + : 0) + (self.size() > 10 ? self[10].matches.size() + : 0) + (self.size() > 11 ? self[11].matches.size() + : 0) + (self.size() > 12 ? self[12].matches.size() + : 0) + (self.size() > 13 ? self[13].matches.size() + : 0) + (self.size() > 14 ? self[14].matches.size() + : 0) + (self.size() > 15 ? self[15].matches.size() + : 0) <= 128' + type: object + type: object + type: object + scheduler: + properties: + pool: + properties: + ref: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + spec: + properties: + extensionRef: + properties: + failureMode: + default: FailClose + enum: + - FailOpen + - FailClose + type: string + group: + default: "" + maxLength: 253 + pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$ + type: string + kind: + default: Service + maxLength: 63 + minLength: 1 + pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$ + type: string + name: + maxLength: 253 + minLength: 1 + type: string + portNumber: + format: int32 + maximum: 65535 + minimum: 1 + type: integer + required: + - name + type: object + selector: + additionalProperties: + maxLength: 63 + minLength: 0 + pattern: ^(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])?$ + type: string + type: object + targetPortNumber: + format: int32 + maximum: 65535 + minimum: 1 + type: integer + required: + - extensionRef + - selector + - targetPortNumber + type: object + type: object + template: + properties: + activeDeadlineSeconds: + format: int64 + type: integer + affinity: + properties: + nodeAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + preference: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + weight: + format: int32 + type: integer + required: + - preference + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + properties: + nodeSelectorTerms: + items: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + type: array + x-kubernetes-list-type: atomic + required: + - nodeSelectorTerms + type: object + x-kubernetes-map-type: atomic + type: object + podAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + podAntiAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + type: object + automountServiceAccountToken: + type: boolean + containers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + dnsConfig: + properties: + nameservers: + items: + type: string + type: array + x-kubernetes-list-type: atomic + options: + items: + properties: + name: + type: string + value: + type: string + type: object + type: array + x-kubernetes-list-type: atomic + searches: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + dnsPolicy: + type: string + enableServiceLinks: + type: boolean + ephemeralContainers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + targetContainerName: + type: string + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + hostAliases: + items: + properties: + hostnames: + items: + type: string + type: array + x-kubernetes-list-type: atomic + ip: + type: string + required: + - ip + type: object + type: array + x-kubernetes-list-map-keys: + - ip + x-kubernetes-list-type: map + hostIPC: + type: boolean + hostNetwork: + type: boolean + hostPID: + type: boolean + hostUsers: + type: boolean + hostname: + type: string + imagePullSecrets: + items: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + initContainers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + nodeName: + type: string + nodeSelector: + additionalProperties: + type: string + type: object + x-kubernetes-map-type: atomic + os: + properties: + name: + type: string + required: + - name + type: object + overhead: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + preemptionPolicy: + type: string + priority: + format: int32 + type: integer + priorityClassName: + type: string + readinessGates: + items: + properties: + conditionType: + type: string + required: + - conditionType + type: object + type: array + x-kubernetes-list-type: atomic + resourceClaims: + items: + properties: + name: + type: string + resourceClaimName: + type: string + resourceClaimTemplateName: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + runtimeClassName: + type: string + schedulerName: + type: string + schedulingGates: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + securityContext: + properties: + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + fsGroup: + format: int64 + type: integer + fsGroupChangePolicy: + type: string + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxChangePolicy: + type: string + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + supplementalGroups: + items: + format: int64 + type: integer + type: array + x-kubernetes-list-type: atomic + supplementalGroupsPolicy: + type: string + sysctls: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + serviceAccount: + type: string + serviceAccountName: + type: string + setHostnameAsFQDN: + type: boolean + shareProcessNamespace: + type: boolean + subdomain: + type: string + terminationGracePeriodSeconds: + format: int64 + type: integer + tolerations: + items: + properties: + effect: + type: string + key: + type: string + operator: + type: string + tolerationSeconds: + format: int64 + type: integer + value: + type: string + type: object + type: array + x-kubernetes-list-type: atomic + topologySpreadConstraints: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + maxSkew: + format: int32 + type: integer + minDomains: + format: int32 + type: integer + nodeAffinityPolicy: + type: string + nodeTaintsPolicy: + type: string + topologyKey: + type: string + whenUnsatisfiable: + type: string + required: + - maxSkew + - topologyKey + - whenUnsatisfiable + type: object + type: array + x-kubernetes-list-map-keys: + - topologyKey + - whenUnsatisfiable + x-kubernetes-list-type: map + volumes: + items: + properties: + awsElasticBlockStore: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + azureDisk: + properties: + cachingMode: + type: string + diskName: + type: string + diskURI: + type: string + fsType: + default: ext4 + type: string + kind: + type: string + readOnly: + default: false + type: boolean + required: + - diskName + - diskURI + type: object + azureFile: + properties: + readOnly: + type: boolean + secretName: + type: string + shareName: + type: string + required: + - secretName + - shareName + type: object + cephfs: + properties: + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + path: + type: string + readOnly: + type: boolean + secretFile: + type: string + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + type: string + required: + - monitors + type: object + cinder: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeID: + type: string + required: + - volumeID + type: object + configMap: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + csi: + properties: + driver: + type: string + fsType: + type: string + nodePublishSecretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + readOnly: + type: boolean + volumeAttributes: + additionalProperties: + type: string + type: object + required: + - driver + type: object + downwardAPI: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + emptyDir: + properties: + medium: + type: string + sizeLimit: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + ephemeral: + properties: + volumeClaimTemplate: + properties: + metadata: + type: object + spec: + properties: + accessModes: + items: + type: string + type: array + x-kubernetes-list-type: atomic + dataSource: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + required: + - kind + - name + type: object + x-kubernetes-map-type: atomic + dataSourceRef: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + namespace: + type: string + required: + - kind + - name + type: object + resources: + properties: + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + selector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + storageClassName: + type: string + volumeAttributesClassName: + type: string + volumeMode: + type: string + volumeName: + type: string + type: object + required: + - spec + type: object + type: object + fc: + properties: + fsType: + type: string + lun: + format: int32 + type: integer + readOnly: + type: boolean + targetWWNs: + items: + type: string + type: array + x-kubernetes-list-type: atomic + wwids: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + flexVolume: + properties: + driver: + type: string + fsType: + type: string + options: + additionalProperties: + type: string + type: object + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + required: + - driver + type: object + flocker: + properties: + datasetName: + type: string + datasetUUID: + type: string + type: object + gcePersistentDisk: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + pdName: + type: string + readOnly: + type: boolean + required: + - pdName + type: object + gitRepo: + properties: + directory: + type: string + repository: + type: string + revision: + type: string + required: + - repository + type: object + glusterfs: + properties: + endpoints: + type: string + path: + type: string + readOnly: + type: boolean + required: + - endpoints + - path + type: object + hostPath: + properties: + path: + type: string + type: + type: string + required: + - path + type: object + image: + properties: + pullPolicy: + type: string + reference: + type: string + type: object + iscsi: + properties: + chapAuthDiscovery: + type: boolean + chapAuthSession: + type: boolean + fsType: + type: string + initiatorName: + type: string + iqn: + type: string + iscsiInterface: + default: default + type: string + lun: + format: int32 + type: integer + portals: + items: + type: string + type: array + x-kubernetes-list-type: atomic + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + targetPortal: + type: string + required: + - iqn + - lun + - targetPortal + type: object + name: + type: string + nfs: + properties: + path: + type: string + readOnly: + type: boolean + server: + type: string + required: + - path + - server + type: object + persistentVolumeClaim: + properties: + claimName: + type: string + readOnly: + type: boolean + required: + - claimName + type: object + photonPersistentDisk: + properties: + fsType: + type: string + pdID: + type: string + required: + - pdID + type: object + portworxVolume: + properties: + fsType: + type: string + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + projected: + properties: + defaultMode: + format: int32 + type: integer + sources: + items: + properties: + clusterTrustBundle: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + name: + type: string + optional: + type: boolean + path: + type: string + signerName: + type: string + required: + - path + type: object + configMap: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + downwardAPI: + properties: + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + secret: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + serviceAccountToken: + properties: + audience: + type: string + expirationSeconds: + format: int64 + type: integer + path: + type: string + required: + - path + type: object + type: object + type: array + x-kubernetes-list-type: atomic + type: object + quobyte: + properties: + group: + type: string + readOnly: + type: boolean + registry: + type: string + tenant: + type: string + user: + type: string + volume: + type: string + required: + - registry + - volume + type: object + rbd: + properties: + fsType: + type: string + image: + type: string + keyring: + default: /etc/ceph/keyring + type: string + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + pool: + default: rbd + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + default: admin + type: string + required: + - image + - monitors + type: object + scaleIO: + properties: + fsType: + default: xfs + type: string + gateway: + type: string + protectionDomain: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + sslEnabled: + type: boolean + storageMode: + default: ThinProvisioned + type: string + storagePool: + type: string + system: + type: string + volumeName: + type: string + required: + - gateway + - secretRef + - system + type: object + secret: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + optional: + type: boolean + secretName: + type: string + type: object + storageos: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeName: + type: string + volumeNamespace: + type: string + type: object + vsphereVolume: + properties: + fsType: + type: string + storagePolicyID: + type: string + storagePolicyName: + type: string + volumePath: + type: string + required: + - volumePath + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + required: + - containers + type: object + type: object + type: object + template: + properties: + activeDeadlineSeconds: + format: int64 + type: integer + affinity: + properties: + nodeAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + preference: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + weight: + format: int32 + type: integer + required: + - preference + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + properties: + nodeSelectorTerms: + items: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + type: array + x-kubernetes-list-type: atomic + required: + - nodeSelectorTerms + type: object + x-kubernetes-map-type: atomic + type: object + podAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + podAntiAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + type: object + automountServiceAccountToken: + type: boolean + containers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + dnsConfig: + properties: + nameservers: + items: + type: string + type: array + x-kubernetes-list-type: atomic + options: + items: + properties: + name: + type: string + value: + type: string + type: object + type: array + x-kubernetes-list-type: atomic + searches: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + dnsPolicy: + type: string + enableServiceLinks: + type: boolean + ephemeralContainers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + targetContainerName: + type: string + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + hostAliases: + items: + properties: + hostnames: + items: + type: string + type: array + x-kubernetes-list-type: atomic + ip: + type: string + required: + - ip + type: object + type: array + x-kubernetes-list-map-keys: + - ip + x-kubernetes-list-type: map + hostIPC: + type: boolean + hostNetwork: + type: boolean + hostPID: + type: boolean + hostUsers: + type: boolean + hostname: + type: string + imagePullSecrets: + items: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + initContainers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + nodeName: + type: string + nodeSelector: + additionalProperties: + type: string + type: object + x-kubernetes-map-type: atomic + os: + properties: + name: + type: string + required: + - name + type: object + overhead: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + preemptionPolicy: + type: string + priority: + format: int32 + type: integer + priorityClassName: + type: string + readinessGates: + items: + properties: + conditionType: + type: string + required: + - conditionType + type: object + type: array + x-kubernetes-list-type: atomic + resourceClaims: + items: + properties: + name: + type: string + resourceClaimName: + type: string + resourceClaimTemplateName: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + runtimeClassName: + type: string + schedulerName: + type: string + schedulingGates: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + securityContext: + properties: + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + fsGroup: + format: int64 + type: integer + fsGroupChangePolicy: + type: string + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxChangePolicy: + type: string + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + supplementalGroups: + items: + format: int64 + type: integer + type: array + x-kubernetes-list-type: atomic + supplementalGroupsPolicy: + type: string + sysctls: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + serviceAccount: + type: string + serviceAccountName: + type: string + setHostnameAsFQDN: + type: boolean + shareProcessNamespace: + type: boolean + subdomain: + type: string + terminationGracePeriodSeconds: + format: int64 + type: integer + tolerations: + items: + properties: + effect: + type: string + key: + type: string + operator: + type: string + tolerationSeconds: + format: int64 + type: integer + value: + type: string + type: object + type: array + x-kubernetes-list-type: atomic + topologySpreadConstraints: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + maxSkew: + format: int32 + type: integer + minDomains: + format: int32 + type: integer + nodeAffinityPolicy: + type: string + nodeTaintsPolicy: + type: string + topologyKey: + type: string + whenUnsatisfiable: + type: string + required: + - maxSkew + - topologyKey + - whenUnsatisfiable + type: object + type: array + x-kubernetes-list-map-keys: + - topologyKey + - whenUnsatisfiable + x-kubernetes-list-type: map + volumes: + items: + properties: + awsElasticBlockStore: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + azureDisk: + properties: + cachingMode: + type: string + diskName: + type: string + diskURI: + type: string + fsType: + default: ext4 + type: string + kind: + type: string + readOnly: + default: false + type: boolean + required: + - diskName + - diskURI + type: object + azureFile: + properties: + readOnly: + type: boolean + secretName: + type: string + shareName: + type: string + required: + - secretName + - shareName + type: object + cephfs: + properties: + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + path: + type: string + readOnly: + type: boolean + secretFile: + type: string + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + type: string + required: + - monitors + type: object + cinder: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeID: + type: string + required: + - volumeID + type: object + configMap: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + csi: + properties: + driver: + type: string + fsType: + type: string + nodePublishSecretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + readOnly: + type: boolean + volumeAttributes: + additionalProperties: + type: string + type: object + required: + - driver + type: object + downwardAPI: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + emptyDir: + properties: + medium: + type: string + sizeLimit: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + ephemeral: + properties: + volumeClaimTemplate: + properties: + metadata: + type: object + spec: + properties: + accessModes: + items: + type: string + type: array + x-kubernetes-list-type: atomic + dataSource: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + required: + - kind + - name + type: object + x-kubernetes-map-type: atomic + dataSourceRef: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + namespace: + type: string + required: + - kind + - name + type: object + resources: + properties: + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + selector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + storageClassName: + type: string + volumeAttributesClassName: + type: string + volumeMode: + type: string + volumeName: + type: string + type: object + required: + - spec + type: object + type: object + fc: + properties: + fsType: + type: string + lun: + format: int32 + type: integer + readOnly: + type: boolean + targetWWNs: + items: + type: string + type: array + x-kubernetes-list-type: atomic + wwids: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + flexVolume: + properties: + driver: + type: string + fsType: + type: string + options: + additionalProperties: + type: string + type: object + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + required: + - driver + type: object + flocker: + properties: + datasetName: + type: string + datasetUUID: + type: string + type: object + gcePersistentDisk: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + pdName: + type: string + readOnly: + type: boolean + required: + - pdName + type: object + gitRepo: + properties: + directory: + type: string + repository: + type: string + revision: + type: string + required: + - repository + type: object + glusterfs: + properties: + endpoints: + type: string + path: + type: string + readOnly: + type: boolean + required: + - endpoints + - path + type: object + hostPath: + properties: + path: + type: string + type: + type: string + required: + - path + type: object + image: + properties: + pullPolicy: + type: string + reference: + type: string + type: object + iscsi: + properties: + chapAuthDiscovery: + type: boolean + chapAuthSession: + type: boolean + fsType: + type: string + initiatorName: + type: string + iqn: + type: string + iscsiInterface: + default: default + type: string + lun: + format: int32 + type: integer + portals: + items: + type: string + type: array + x-kubernetes-list-type: atomic + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + targetPortal: + type: string + required: + - iqn + - lun + - targetPortal + type: object + name: + type: string + nfs: + properties: + path: + type: string + readOnly: + type: boolean + server: + type: string + required: + - path + - server + type: object + persistentVolumeClaim: + properties: + claimName: + type: string + readOnly: + type: boolean + required: + - claimName + type: object + photonPersistentDisk: + properties: + fsType: + type: string + pdID: + type: string + required: + - pdID + type: object + portworxVolume: + properties: + fsType: + type: string + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + projected: + properties: + defaultMode: + format: int32 + type: integer + sources: + items: + properties: + clusterTrustBundle: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + name: + type: string + optional: + type: boolean + path: + type: string + signerName: + type: string + required: + - path + type: object + configMap: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + downwardAPI: + properties: + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + secret: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + serviceAccountToken: + properties: + audience: + type: string + expirationSeconds: + format: int64 + type: integer + path: + type: string + required: + - path + type: object + type: object + type: array + x-kubernetes-list-type: atomic + type: object + quobyte: + properties: + group: + type: string + readOnly: + type: boolean + registry: + type: string + tenant: + type: string + user: + type: string + volume: + type: string + required: + - registry + - volume + type: object + rbd: + properties: + fsType: + type: string + image: + type: string + keyring: + default: /etc/ceph/keyring + type: string + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + pool: + default: rbd + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + default: admin + type: string + required: + - image + - monitors + type: object + scaleIO: + properties: + fsType: + default: xfs + type: string + gateway: + type: string + protectionDomain: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + sslEnabled: + type: boolean + storageMode: + default: ThinProvisioned + type: string + storagePool: + type: string + system: + type: string + volumeName: + type: string + required: + - gateway + - secretRef + - system + type: object + secret: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + optional: + type: boolean + secretName: + type: string + type: object + storageos: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeName: + type: string + volumeNamespace: + type: string + type: object + vsphereVolume: + properties: + fsType: + type: string + storagePolicyID: + type: string + storagePolicyName: + type: string + volumePath: + type: string + required: + - volumePath + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + required: + - containers + type: object + worker: + properties: + activeDeadlineSeconds: + format: int64 + type: integer + affinity: + properties: + nodeAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + preference: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + weight: + format: int32 + type: integer + required: + - preference + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + properties: + nodeSelectorTerms: + items: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + type: array + x-kubernetes-list-type: atomic + required: + - nodeSelectorTerms + type: object + x-kubernetes-map-type: atomic + type: object + podAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + podAntiAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + type: object + automountServiceAccountToken: + type: boolean + containers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + dnsConfig: + properties: + nameservers: + items: + type: string + type: array + x-kubernetes-list-type: atomic + options: + items: + properties: + name: + type: string + value: + type: string + type: object + type: array + x-kubernetes-list-type: atomic + searches: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + dnsPolicy: + type: string + enableServiceLinks: + type: boolean + ephemeralContainers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + targetContainerName: + type: string + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + hostAliases: + items: + properties: + hostnames: + items: + type: string + type: array + x-kubernetes-list-type: atomic + ip: + type: string + required: + - ip + type: object + type: array + x-kubernetes-list-map-keys: + - ip + x-kubernetes-list-type: map + hostIPC: + type: boolean + hostNetwork: + type: boolean + hostPID: + type: boolean + hostUsers: + type: boolean + hostname: + type: string + imagePullSecrets: + items: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + initContainers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + stopSignal: + type: string + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + default: "" + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + nodeName: + type: string + nodeSelector: + additionalProperties: + type: string + type: object + x-kubernetes-map-type: atomic + os: + properties: + name: + type: string + required: + - name + type: object + overhead: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + preemptionPolicy: + type: string + priority: + format: int32 + type: integer + priorityClassName: + type: string + readinessGates: + items: + properties: + conditionType: + type: string + required: + - conditionType + type: object + type: array + x-kubernetes-list-type: atomic + resourceClaims: + items: + properties: + name: + type: string + resourceClaimName: + type: string + resourceClaimTemplateName: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + resources: + properties: + claims: + items: + properties: + name: + type: string + request: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + runtimeClassName: + type: string + schedulerName: + type: string + schedulingGates: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + securityContext: + properties: + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + fsGroup: + format: int64 + type: integer + fsGroupChangePolicy: + type: string + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxChangePolicy: + type: string + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + supplementalGroups: + items: + format: int64 + type: integer + type: array + x-kubernetes-list-type: atomic + supplementalGroupsPolicy: + type: string + sysctls: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + serviceAccount: + type: string + serviceAccountName: + type: string + setHostnameAsFQDN: + type: boolean + shareProcessNamespace: + type: boolean + subdomain: + type: string + terminationGracePeriodSeconds: + format: int64 + type: integer + tolerations: + items: + properties: + effect: + type: string + key: + type: string + operator: + type: string + tolerationSeconds: + format: int64 + type: integer + value: + type: string + type: object + type: array + x-kubernetes-list-type: atomic + topologySpreadConstraints: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + maxSkew: + format: int32 + type: integer + minDomains: + format: int32 + type: integer + nodeAffinityPolicy: + type: string + nodeTaintsPolicy: + type: string + topologyKey: + type: string + whenUnsatisfiable: + type: string + required: + - maxSkew + - topologyKey + - whenUnsatisfiable + type: object + type: array + x-kubernetes-list-map-keys: + - topologyKey + - whenUnsatisfiable + x-kubernetes-list-type: map + volumes: + items: + properties: + awsElasticBlockStore: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + azureDisk: + properties: + cachingMode: + type: string + diskName: + type: string + diskURI: + type: string + fsType: + default: ext4 + type: string + kind: + type: string + readOnly: + default: false + type: boolean + required: + - diskName + - diskURI + type: object + azureFile: + properties: + readOnly: + type: boolean + secretName: + type: string + shareName: + type: string + required: + - secretName + - shareName + type: object + cephfs: + properties: + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + path: + type: string + readOnly: + type: boolean + secretFile: + type: string + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + type: string + required: + - monitors + type: object + cinder: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeID: + type: string + required: + - volumeID + type: object + configMap: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + csi: + properties: + driver: + type: string + fsType: + type: string + nodePublishSecretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + readOnly: + type: boolean + volumeAttributes: + additionalProperties: + type: string + type: object + required: + - driver + type: object + downwardAPI: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + emptyDir: + properties: + medium: + type: string + sizeLimit: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + ephemeral: + properties: + volumeClaimTemplate: + properties: + metadata: + type: object + spec: + properties: + accessModes: + items: + type: string + type: array + x-kubernetes-list-type: atomic + dataSource: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + required: + - kind + - name + type: object + x-kubernetes-map-type: atomic + dataSourceRef: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + namespace: + type: string + required: + - kind + - name + type: object + resources: + properties: + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + selector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + storageClassName: + type: string + volumeAttributesClassName: + type: string + volumeMode: + type: string + volumeName: + type: string + type: object + required: + - spec + type: object + type: object + fc: + properties: + fsType: + type: string + lun: + format: int32 + type: integer + readOnly: + type: boolean + targetWWNs: + items: + type: string + type: array + x-kubernetes-list-type: atomic + wwids: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + flexVolume: + properties: + driver: + type: string + fsType: + type: string + options: + additionalProperties: + type: string + type: object + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + required: + - driver + type: object + flocker: + properties: + datasetName: + type: string + datasetUUID: + type: string + type: object + gcePersistentDisk: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + pdName: + type: string + readOnly: + type: boolean + required: + - pdName + type: object + gitRepo: + properties: + directory: + type: string + repository: + type: string + revision: + type: string + required: + - repository + type: object + glusterfs: + properties: + endpoints: + type: string + path: + type: string + readOnly: + type: boolean + required: + - endpoints + - path + type: object + hostPath: + properties: + path: + type: string + type: + type: string + required: + - path + type: object + image: + properties: + pullPolicy: + type: string + reference: + type: string + type: object + iscsi: + properties: + chapAuthDiscovery: + type: boolean + chapAuthSession: + type: boolean + fsType: + type: string + initiatorName: + type: string + iqn: + type: string + iscsiInterface: + default: default + type: string + lun: + format: int32 + type: integer + portals: + items: + type: string + type: array + x-kubernetes-list-type: atomic + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + targetPortal: + type: string + required: + - iqn + - lun + - targetPortal + type: object + name: + type: string + nfs: + properties: + path: + type: string + readOnly: + type: boolean + server: + type: string + required: + - path + - server + type: object + persistentVolumeClaim: + properties: + claimName: + type: string + readOnly: + type: boolean + required: + - claimName + type: object + photonPersistentDisk: + properties: + fsType: + type: string + pdID: + type: string + required: + - pdID + type: object + portworxVolume: + properties: + fsType: + type: string + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + projected: + properties: + defaultMode: + format: int32 + type: integer + sources: + items: + properties: + clusterTrustBundle: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + name: + type: string + optional: + type: boolean + path: + type: string + signerName: + type: string + required: + - path + type: object + configMap: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + downwardAPI: + properties: + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + secret: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + serviceAccountToken: + properties: + audience: + type: string + expirationSeconds: + format: int64 + type: integer + path: + type: string + required: + - path + type: object + type: object + type: array + x-kubernetes-list-type: atomic + type: object + quobyte: + properties: + group: + type: string + readOnly: + type: boolean + registry: + type: string + tenant: + type: string + user: + type: string + volume: + type: string + required: + - registry + - volume + type: object + rbd: + properties: + fsType: + type: string + image: + type: string + keyring: + default: /etc/ceph/keyring + type: string + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + pool: + default: rbd + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + default: admin + type: string + required: + - image + - monitors + type: object + scaleIO: + properties: + fsType: + default: xfs + type: string + gateway: + type: string + protectionDomain: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + sslEnabled: + type: boolean + storageMode: + default: ThinProvisioned + type: string + storagePool: + type: string + system: + type: string + volumeName: + type: string + required: + - gateway + - secretRef + - system + type: object + secret: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + optional: + type: boolean + secretName: + type: string + type: object + storageos: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeName: + type: string + volumeNamespace: + type: string + type: object + vsphereVolume: + properties: + fsType: + type: string + storagePolicyID: + type: string + storagePolicyName: + type: string + volumePath: + type: string + required: + - volumePath + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + required: + - containers + type: object + required: + - model + type: object + status: + properties: + address: + properties: + CACerts: + type: string + audience: + type: string + name: + type: string + url: + type: string + type: object + addresses: + items: + properties: + CACerts: + type: string + audience: + type: string + name: + type: string + url: + type: string + type: object + type: array + annotations: + additionalProperties: + type: string + type: object + conditions: + items: + properties: + lastTransitionTime: + type: string + message: + type: string + reason: + type: string + severity: + type: string + status: + type: string + type: + type: string + required: + - status + - type + type: object + type: array + observedGeneration: + format: int64 + type: integer + url: + type: string + type: object + type: object + served: true + storage: true + subresources: + status: {} diff --git a/charts/llmisvc-crd/values.yaml b/charts/llmisvc-crd/values.yaml new file mode 100644 index 00000000000..e69de29bb2d diff --git a/charts/llmisvc-resources/Chart.yaml b/charts/llmisvc-resources/Chart.yaml new file mode 100644 index 00000000000..ea8c338e11f --- /dev/null +++ b/charts/llmisvc-resources/Chart.yaml @@ -0,0 +1,23 @@ +apiVersion: v2 +name: llmisvc-resources +version: v0.15.2 +appVersion: v0.15.2 +description: Helm chart for deploying KServe LLMInferenceService resources +type: application +keywords: + - kserve + - llm + - llm-d + - inference + - generative-ai + - machine-learning + - model-serving +home: https://kserve.github.io/website/ +sources: + - https://github.com/kserve/kserve +maintainers: + - name: KServe Team + url: https://github.com/kserve/kserve +icon: https://raw.githubusercontent.com/kserve/website/main/docs/images/logo.png +annotations: + category: AI/Machine Learning diff --git a/charts/llmisvc-resources/README.md b/charts/llmisvc-resources/README.md new file mode 100644 index 00000000000..0cb613548c9 --- /dev/null +++ b/charts/llmisvc-resources/README.md @@ -0,0 +1,54 @@ +# llmisvc-resources + +Helm chart for deploying KServe LLMInferenceService resources + +![Version: v0.15.2](https://img.shields.io/badge/Version-v0.15.2-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: v0.15.2](https://img.shields.io/badge/AppVersion-v0.15.2-informational?style=flat-square) + +## Installing the Chart + +To install the chart, run the following: + +```console +$ helm install llmisvc oci://ghcr.io/kserve/charts/llmisvc --version v0.15.2 +``` + +## Values + +| Key | Type | Default | Description | +|-----|------|---------|-------------| +| commonAnnotations | object | `{}` | Common annotations to add to all resources | +| commonLabels | object | `{}` | Common labels to add to all resources | +| kserve.llmisvc.controller.affinity | object | `{}` | A Kubernetes Affinity, if required For more information, see [Affinity v1 core](https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.27/#affinity-v1-core) For example: affinity: nodeAffinity: requiredDuringSchedulingIgnoredDuringExecution: nodeSelectorTerms: - matchExpressions: - key: foo.bar.com/role operator: In values: - master | +| kserve.llmisvc.controller.annotations | object | `{}` | Optional additional annotations to add to the controller deployment | +| kserve.llmisvc.controller.containerSecurityContext | object | `{"allowPrivilegeEscalation":false,"capabilities":{"drop":["ALL"]},"privileged":false,"readOnlyRootFilesystem":true,"runAsNonRoot":true,"runAsUser":1000,"seccompProfile":{"type":"RuntimeDefault"}}` | Container Security Context to be set on the controller component container For more information, see [Configure a Security Context for a Pod or Container](https://kubernetes.io/docs/tasks/configure-pod-container/security-context/) | +| kserve.llmisvc.controller.env | list | `[]` | Environment variables to be set on the controller container | +| kserve.llmisvc.controller.extraArgs | list | `[]` | Additional command line arguments | +| kserve.llmisvc.controller.extraVolumeMounts | list | `[]` | Additional volume mounts | +| kserve.llmisvc.controller.extraVolumes | list | `[]` | Additional volumes to be mounted | +| kserve.llmisvc.controller.image | string | `"kserve/llmisvc-controller"` | KServe LLM ISVC controller manager container image | +| kserve.llmisvc.controller.imagePullPolicy | string | `"IfNotPresent"` | Specifies when to pull controller image from registry | +| kserve.llmisvc.controller.imagePullSecrets | list | `[]` | Reference to one or more secrets to be used when pulling images For more information, see [Pull an Image from a Private Registry](https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/) For example: imagePullSecrets: - name: "image-pull-secret" | +| kserve.llmisvc.controller.labels | object | `{}` | Optional additional labels to add to the controller deployment | +| kserve.llmisvc.controller.livenessProbe | object | `{"enabled":true,"failureThreshold":5,"httpGet":{"path":"/healthz","port":8081},"initialDelaySeconds":30,"periodSeconds":10,"timeoutSeconds":5}` | Liveness probe configuration | +| kserve.llmisvc.controller.metricsBindAddress | string | `"127.0.0.1"` | Metrics bind address | +| kserve.llmisvc.controller.metricsBindPort | string | `"8443"` | Metrics bind port | +| kserve.llmisvc.controller.nodeSelector | object | `{}` | The nodeSelector on Pods tells Kubernetes to schedule Pods on the nodes with matching labels For more information, see [Assigning Pods to Nodes](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/) For example: nodeSelector: kubernetes.io/arch: amd64 | +| kserve.llmisvc.controller.podAnnotations | object | `{}` | Optional additional annotations to add to the controller Pods | +| kserve.llmisvc.controller.podLabels | object | `{}` | Optional additional labels to add to the controller Pods | +| kserve.llmisvc.controller.readinessProbe | object | `{"enabled":true,"failureThreshold":5,"httpGet":{"path":"/readyz","port":8081},"initialDelaySeconds":30,"periodSeconds":5,"timeoutSeconds":5}` | Readiness probe configuration | +| kserve.llmisvc.controller.replicas | int | `1` | Number of replicas for the controller deployment | +| kserve.llmisvc.controller.resources | object | `{"limits":{"cpu":"100m","memory":"300Mi"},"requests":{"cpu":"100m","memory":"300Mi"}}` | Resources to provide to the llmisvc controller pod For example: resources: limits: cpu: 100m memory: 300Mi requests: cpu: 100m memory: 300Mi For more information, see [Resource Management for Pods and Containers](https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/) | +| kserve.llmisvc.controller.securityContext | object | `{"runAsNonRoot":true,"seccompProfile":{"type":"RuntimeDefault"}}` | Pod Security Context For more information, see [Configure a Security Context for a Pod or Container](https://kubernetes.io/docs/tasks/configure-pod-container/security-context/) | +| kserve.llmisvc.controller.service | object | `{"port":8443,"targetPort":"metrics","type":"ClusterIP"}` | Service configuration | +| kserve.llmisvc.controller.service.port | int | `8443` | Service port for metrics | +| kserve.llmisvc.controller.service.targetPort | string | `"metrics"` | Service target port | +| kserve.llmisvc.controller.service.type | string | `"ClusterIP"` | Service type | +| kserve.llmisvc.controller.serviceAccount | object | `{"name":""}` | Service account configuration | +| kserve.llmisvc.controller.serviceAccount.name | string | `""` | Name of the service account to use If not set, a name is generated using the deployment name | +| kserve.llmisvc.controller.serviceAnnotations | object | `{}` | Optional additional annotations to add to the controller service | +| kserve.llmisvc.controller.strategy | object | `{"rollingUpdate":{"maxSurge":1,"maxUnavailable":0},"type":"RollingUpdate"}` | Deployment strategy | +| kserve.llmisvc.controller.tag | string | `"v0.15.2"` | KServe LLM ISVC controller container image tag | +| kserve.llmisvc.controller.terminationGracePeriodSeconds | int | `10` | Termination grace period in seconds | +| kserve.llmisvc.controller.tolerations | list | `[]` | A list of Kubernetes Tolerations, if required For more information, see [Toleration v1 core](https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.27/#toleration-v1-core) For example: tolerations: - key: foo.bar.com/role operator: Equal value: master effect: NoSchedule | +| kserve.llmisvc.controller.topologySpreadConstraints | list | `[]` | A list of Kubernetes TopologySpreadConstraints, if required For more information, see [Topology spread constraint v1 core](https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.27/#topologyspreadconstraint-v1-core) For example: topologySpreadConstraints: - maxSkew: 2 topologyKey: topology.kubernetes.io/zone whenUnsatisfiable: ScheduleAnyway labelSelector: matchLabels: app.kubernetes.io/instance: llmisvc-controller-manager app.kubernetes.io/component: controller | +| kserve.version | string | `"v0.15.2"` | Version of KServe LLM ISVC components | diff --git a/charts/llmisvc-resources/README.md.gotmpl b/charts/llmisvc-resources/README.md.gotmpl new file mode 100644 index 00000000000..ead9d9d4ba1 --- /dev/null +++ b/charts/llmisvc-resources/README.md.gotmpl @@ -0,0 +1,16 @@ +{{ template "chart.header" . }} +{{ template "chart.description" . }} + +{{ template "chart.versionBadge" . }}{{ template "chart.typeBadge" . }}{{ template "chart.appVersionBadge" . }} + +## Installing the Chart + +To install the chart, run the following: + +```console +$ helm install llmisvc oci://ghcr.io/kserve/charts/llmisvc --version {{ template "chart.version" . }} +``` + +{{ template "chart.requirementsSection" . }} + +{{ template "chart.valuesSection" . }} diff --git a/charts/llmisvc-resources/templates/_helpers.tpl b/charts/llmisvc-resources/templates/_helpers.tpl new file mode 100644 index 00000000000..623a6ede3f5 --- /dev/null +++ b/charts/llmisvc-resources/templates/_helpers.tpl @@ -0,0 +1,88 @@ +{{/* +Expand the name of the chart. +*/}} +{{- define "llm-isvc-resources.name" -}} +{{- .Chart.Name | trunc 63 | trimSuffix "-" }} +{{- end }} + +{{/* +Create a default fully qualified app name. +We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec). +If release name contains chart name it will be used as a full name. +*/}} +{{- define "llm-isvc-resources.fullname" -}} +{{- if contains .Chart.Name .Release.Name }} +{{- .Release.Name | trunc 63 | trimSuffix "-" }} +{{- else }} +{{- printf "%s-%s" .Release.Name .Chart.Name | trunc 63 | trimSuffix "-" }} +{{- end }} +{{- end }} + +{{/* +Create chart name and version as used by the chart label. +*/}} +{{- define "llm-isvc-resources.chart" -}} +{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }} +{{- end }} + +{{/* +Common labels +*/}} +{{- define "llm-isvc-resources.labels" -}} +helm.sh/chart: {{ include "llm-isvc-resources.chart" . }} +{{ include "llm-isvc-resources.selectorLabels" . }} +{{- if .Chart.AppVersion }} +app.kubernetes.io/version: {{ .Chart.AppVersion | quote }} +{{- end }} +app.kubernetes.io/managed-by: {{ .Release.Service }} +{{- end }} + +{{/* +Selector labels +*/}} +{{- define "llm-isvc-resources.selectorLabels" -}} +app.kubernetes.io/name: {{ include "llm-isvc-resources.deploymentName" . }} +app.kubernetes.io/instance: {{ .Release.Name }} +{{- end }} + +{{/* +Create the deployment name +*/}} +{{- define "llm-isvc-resources.deploymentName" -}} +kserve-llmisvc-controller-manager +{{- end }} + +{{/* +Create the name of the service account to use +*/}} +{{- define "llm-isvc-resources.serviceAccountName" -}} +{{- default (include "llm-isvc-resources.deploymentName" .) .Values.kserve.llmisvc.controller.serviceAccount.name }} +{{- end }} + +{{/* +Return the proper image name +*/}} +{{- define "llm-isvc-resources.image" -}} +{{- $repositoryName := .Values.kserve.llmisvc.controller.image -}} +{{- $tag := .Values.kserve.llmisvc.controller.tag | toString -}} +{{- printf "%s:%s" $repositoryName $tag -}} +{{- end }} + +{{/* +Return the proper image pull policy +*/}} +{{- define "llm-isvc-resources.imagePullPolicy" -}} +{{- .Values.kserve.llmisvc.controller.imagePullPolicy | default "IfNotPresent" }} +{{- end }} + +{{/* +Return the proper image pull secrets +*/}} +{{- define "llm-isvc-resources.imagePullSecrets" -}} +{{- if .Values.kserve.llmisvc.controller.imagePullSecrets }} +imagePullSecrets: +{{- range .Values.kserve.llmisvc.controller.imagePullSecrets }} + - name: {{ . }} +{{- end }} +{{- end }} +{{- end }} diff --git a/charts/llmisvc-resources/templates/clusterrole.yaml b/charts/llmisvc-resources/templates/clusterrole.yaml new file mode 100644 index 00000000000..7bedb10becf --- /dev/null +++ b/charts/llmisvc-resources/templates/clusterrole.yaml @@ -0,0 +1,27 @@ +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRole +metadata: + name: llmisvc-manager-role +rules: +- apiGroups: + - serving.kserve.io + resources: + - llminferenceservices + - llminferenceservices/finalizers + verbs: + - create + - delete + - get + - list + - patch + - update + - watch +- apiGroups: + - serving.kserve.io + resources: + - llminferenceservices/status + verbs: + - get + - patch + - update diff --git a/charts/llmisvc-resources/templates/deployment.yaml b/charts/llmisvc-resources/templates/deployment.yaml new file mode 100644 index 00000000000..e5dde84ac24 --- /dev/null +++ b/charts/llmisvc-resources/templates/deployment.yaml @@ -0,0 +1,153 @@ +--- +apiVersion: apps/v1 +kind: Deployment +metadata: + name: {{ include "llm-isvc-resources.deploymentName" . }} + namespace: {{ .Release.Namespace }} + labels: + {{- include "llm-isvc-resources.labels" . | nindent 4 }} + app.kubernetes.io/component: controller + control-plane: {{ include "llm-isvc-resources.deploymentName" . }} + controller-tools.k8s.io: "1.0" + {{- with .Values.kserve.llmisvc.controller.labels }} + {{- toYaml . | nindent 4 }} + {{- end }} + {{- with .Values.commonLabels }} + {{- toYaml . | nindent 4 }} + {{- end }} + annotations: + prometheus.io/scrape: 'true' + {{- with .Values.kserve.llmisvc.controller.annotations }} + {{- toYaml . | nindent 4 }} + {{- end }} + {{- with .Values.commonAnnotations }} + {{- toYaml . | nindent 4 }} + {{- end }} +spec: + replicas: {{ .Values.kserve.llmisvc.controller.replicas }} + {{- with .Values.kserve.llmisvc.controller.strategy }} + strategy: + {{- toYaml . | nindent 4 }} + {{- end }} + selector: + matchLabels: + {{- include "llm-isvc-resources.selectorLabels" . | nindent 6 }} + control-plane: {{ include "llm-isvc-resources.deploymentName" . }} + controller-tools.k8s.io: "1.0" + template: + metadata: + labels: + {{- include "llm-isvc-resources.selectorLabels" . | nindent 8 }} + app.kubernetes.io/component: controller + control-plane: {{ include "llm-isvc-resources.deploymentName" . }} + controller-tools.k8s.io: "1.0" + {{- with .Values.kserve.llmisvc.controller.podLabels }} + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.commonLabels }} + {{- toYaml . | nindent 8 }} + {{- end }} + annotations: + kubectl.kubernetes.io/default-container: manager + {{- with .Values.kserve.llmisvc.controller.podAnnotations }} + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.commonAnnotations }} + {{- toYaml . | nindent 8 }} + {{- end }} + spec: + serviceAccountName: {{ include "llm-isvc-resources.serviceAccountName" . }} + {{- include "llm-isvc-resources.imagePullSecrets" . | nindent 6 }} + {{- with .Values.kserve.llmisvc.controller.nodeSelector }} + nodeSelector: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.kserve.llmisvc.controller.affinity }} + affinity: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.kserve.llmisvc.controller.tolerations }} + tolerations: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.kserve.llmisvc.controller.topologySpreadConstraints }} + topologySpreadConstraints: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.kserve.llmisvc.controller.securityContext }} + securityContext: + {{- toYaml . | nindent 8 }} + {{- end }} + terminationGracePeriodSeconds: {{ .Values.kserve.llmisvc.controller.terminationGracePeriodSeconds }} + containers: + - name: manager + image: {{ include "llm-isvc-resources.image" . }} + imagePullPolicy: {{ include "llm-isvc-resources.imagePullPolicy" . }} + command: + - /manager + {{- with .Values.kserve.llmisvc.controller.containerSecurityContext }} + securityContext: + {{- toYaml . | nindent 10 }} + {{- end }} + args: + - "--metrics-addr={{ .Values.kserve.llmisvc.controller.metricsBindAddress }}:{{ .Values.kserve.llmisvc.controller.metricsBindPort }}" + - "--leader-elect" + {{- with .Values.kserve.llmisvc.controller.extraArgs }} + {{- toYaml . | nindent 8 }} + {{- end }} + env: + - name: POD_NAMESPACE + valueFrom: + fieldRef: + fieldPath: metadata.namespace + {{- with .Values.kserve.llmisvc.controller.env }} + {{- toYaml . | nindent 10 }} + {{- end }} + {{- if .Values.kserve.llmisvc.controller.livenessProbe.enabled }} + livenessProbe: + {{- with .Values.kserve.llmisvc.controller.livenessProbe.httpGet }} + httpGet: + {{- toYaml . | nindent 12 }} + {{- end }} + initialDelaySeconds: {{ .Values.kserve.llmisvc.controller.livenessProbe.initialDelaySeconds }} + periodSeconds: {{ .Values.kserve.llmisvc.controller.livenessProbe.periodSeconds }} + timeoutSeconds: {{ .Values.kserve.llmisvc.controller.livenessProbe.timeoutSeconds }} + failureThreshold: {{ .Values.kserve.llmisvc.controller.livenessProbe.failureThreshold }} + {{- end }} + {{- if .Values.kserve.llmisvc.controller.readinessProbe.enabled }} + readinessProbe: + {{- with .Values.kserve.llmisvc.controller.readinessProbe.httpGet }} + httpGet: + {{- toYaml . | nindent 12 }} + {{- end }} + initialDelaySeconds: {{ .Values.kserve.llmisvc.controller.readinessProbe.initialDelaySeconds }} + periodSeconds: {{ .Values.kserve.llmisvc.controller.readinessProbe.periodSeconds }} + timeoutSeconds: {{ .Values.kserve.llmisvc.controller.readinessProbe.timeoutSeconds }} + failureThreshold: {{ .Values.kserve.llmisvc.controller.readinessProbe.failureThreshold }} + {{- end }} + {{- with .Values.kserve.llmisvc.controller.resources }} + resources: + {{- toYaml . | nindent 10 }} + {{- end }} + ports: + - containerPort: 9443 + name: webhook-server + protocol: TCP + - containerPort: 8443 + name: metrics + protocol: TCP + volumeMounts: + - mountPath: /tmp/k8s-webhook-server/serving-certs + name: cert + readOnly: true + {{- with .Values.kserve.llmisvc.controller.extraVolumeMounts }} + {{- toYaml . | nindent 8 }} + {{- end }} + volumes: + - name: cert + secret: + defaultMode: 420 + secretName: kserve-webhook-server-cert + {{- with .Values.kserve.llmisvc.controller.extraVolumes }} + {{- toYaml . | nindent 8 }} + {{- end }} diff --git a/charts/llmisvc-resources/templates/service.yaml b/charts/llmisvc-resources/templates/service.yaml new file mode 100644 index 00000000000..a96cf7f6d55 --- /dev/null +++ b/charts/llmisvc-resources/templates/service.yaml @@ -0,0 +1,32 @@ +--- +apiVersion: v1 +kind: Service +metadata: + name: {{ include "llm-isvc-resources.deploymentName" . }}-service + namespace: {{ .Release.Namespace }} + labels: + {{- include "llm-isvc-resources.labels" . | nindent 4 }} + app.kubernetes.io/component: controller + control-plane: {{ include "llm-isvc-resources.deploymentName" . }} + controller-tools.k8s.io: "1.0" + {{- with .Values.commonLabels }} + {{- toYaml . | nindent 4 }} + {{- end }} + annotations: + {{- with .Values.kserve.llmisvc.controller.serviceAnnotations }} + {{- toYaml . | nindent 4 }} + {{- end }} + {{- with .Values.commonAnnotations }} + {{- toYaml . | nindent 4 }} + {{- end }} +spec: + type: {{ .Values.kserve.llmisvc.controller.service.type }} + selector: + {{- include "llm-isvc-resources.selectorLabels" . | nindent 4 }} + control-plane: {{ include "llm-isvc-resources.deploymentName" . }} + controller-tools.k8s.io: "1.0" + ports: + - port: {{ .Values.kserve.llmisvc.controller.service.port }} + targetPort: {{ .Values.kserve.llmisvc.controller.service.targetPort }} + protocol: TCP + name: https diff --git a/charts/llmisvc-resources/templates/serviceaccount.yaml b/charts/llmisvc-resources/templates/serviceaccount.yaml new file mode 100644 index 00000000000..535334f1aaa --- /dev/null +++ b/charts/llmisvc-resources/templates/serviceaccount.yaml @@ -0,0 +1,17 @@ +--- +apiVersion: v1 +kind: ServiceAccount +metadata: + name: {{ include "llm-isvc-resources.serviceAccountName" . }} + namespace: {{ .Release.Namespace }} + labels: + {{- include "llm-isvc-resources.labels" . | nindent 4 }} + app.kubernetes.io/component: controller + {{- with .Values.commonLabels }} + {{- toYaml . | nindent 4 }} + {{- end }} + annotations: + {{- with .Values.commonAnnotations }} + {{- toYaml . | nindent 4 }} + {{- end }} +{{- include "llm-isvc-resources.imagePullSecrets" . }} diff --git a/charts/llmisvc-resources/values.schema.json b/charts/llmisvc-resources/values.schema.json new file mode 100644 index 00000000000..90b9f7d5b3f --- /dev/null +++ b/charts/llmisvc-resources/values.schema.json @@ -0,0 +1,99 @@ +{ + "$schema": "https://json-schema.org/draft-07/schema#", + "title": "LLM ISVC Resources Helm Chart Values", + "type": "object", + "properties": { + "commonLabels": { + "type": "object", + "description": "Common labels to add to all resources" + }, + "commonAnnotations": { + "type": "object", + "description": "Common annotations to add to all resources" + }, + "kserve": { + "type": "object", + "properties": { + "version": { + "type": "string", + "description": "Version of KServe LLM ISVC components" + }, + "llmisvc": { + "type": "object", + "properties": { + "controller": { + "type": "object", + "properties": { + "image": { + "type": "string", + "description": "KServe LLM ISVC controller manager container image" + }, + "tag": { + "type": "string", + "description": "KServe LLM ISVC controller container image tag" + }, + "imagePullPolicy": { + "type": "string", + "enum": [ + "Always", + "IfNotPresent", + "Never" + ], + "description": "Specifies when to pull controller image from registry" + }, + "replicas": { + "type": "integer", + "minimum": 1, + "description": "Number of replicas for the controller deployment" + }, + "resources": { + "type": "object", + "properties": { + "limits": { + "type": "object", + "properties": { + "cpu": { + "type": "string" + }, + "memory": { + "type": "string" + } + } + }, + "requests": { + "type": "object", + "properties": { + "cpu": { + "type": "string" + }, + "memory": { + "type": "string" + } + } + } + } + }, + "nodeSelector": { + "type": "object", + "description": "Node selector for pod assignment" + }, + "tolerations": { + "type": "array", + "description": "Tolerations for pod assignment" + }, + "affinity": { + "type": "object", + "description": "Affinity for pod assignment" + }, + "topologySpreadConstraints": { + "type": "array", + "description": "Topology spread constraints for pod assignment" + } + } + } + } + } + } + } + } +} diff --git a/charts/llmisvc-resources/values.yaml b/charts/llmisvc-resources/values.yaml new file mode 100644 index 00000000000..4bd33b25f2f --- /dev/null +++ b/charts/llmisvc-resources/values.yaml @@ -0,0 +1,200 @@ +# -- Common labels to add to all resources +commonLabels: {} + +# -- Common annotations to add to all resources +commonAnnotations: {} + +kserve: + # -- Version of KServe LLM ISVC components + version: &defaultVersion v0.15.2 + + llmisvc: + controller: + # -- KServe LLM ISVC controller manager container image + image: kserve/llmisvc-controller + + # -- KServe LLM ISVC controller container image tag + tag: *defaultVersion + + # -- Specifies when to pull controller image from registry + imagePullPolicy: "IfNotPresent" + + # -- Reference to one or more secrets to be used when pulling images + # For more information, see [Pull an Image from a Private Registry](https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/) + # + # For example: + # imagePullSecrets: + # - name: "image-pull-secret" + imagePullSecrets: [] + + # -- Optional additional labels to add to the controller deployment + labels: {} + + # -- Optional additional labels to add to the controller Pods + podLabels: {} + + # -- Optional additional annotations to add to the controller deployment + annotations: {} + + # -- Optional additional annotations to add to the controller Pods + podAnnotations: {} + + # -- Optional additional annotations to add to the controller service + serviceAnnotations: {} + + # -- Pod Security Context + # For more information, see [Configure a Security Context for a Pod or Container](https://kubernetes.io/docs/tasks/configure-pod-container/security-context/) + securityContext: + runAsNonRoot: true + seccompProfile: + type: RuntimeDefault + + # -- Container Security Context to be set on the controller component container + # For more information, see [Configure a Security Context for a Pod or Container](https://kubernetes.io/docs/tasks/configure-pod-container/security-context/) + containerSecurityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + privileged: false + readOnlyRootFilesystem: true + runAsNonRoot: true + runAsUser: 1000 + seccompProfile: + type: RuntimeDefault + + # -- Metrics bind address + metricsBindAddress: "127.0.0.1" + + # -- Metrics bind port + metricsBindPort: "8443" + + # -- The nodeSelector on Pods tells Kubernetes to schedule Pods on the nodes with matching labels + # For more information, see [Assigning Pods to Nodes](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/) + # + # For example: + # nodeSelector: + # kubernetes.io/arch: amd64 + nodeSelector: {} + + # -- A list of Kubernetes Tolerations, if required + # For more information, see [Toleration v1 core](https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.27/#toleration-v1-core) + # + # For example: + # tolerations: + # - key: foo.bar.com/role + # operator: Equal + # value: master + # effect: NoSchedule + tolerations: [] + + # -- A list of Kubernetes TopologySpreadConstraints, if required + # For more information, see [Topology spread constraint v1 core](https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.27/#topologyspreadconstraint-v1-core) + # + # For example: + # topologySpreadConstraints: + # - maxSkew: 2 + # topologyKey: topology.kubernetes.io/zone + # whenUnsatisfiable: ScheduleAnyway + # labelSelector: + # matchLabels: + # app.kubernetes.io/instance: llmisvc-controller-manager + # app.kubernetes.io/component: controller + topologySpreadConstraints: [] + + # -- A Kubernetes Affinity, if required + # For more information, see [Affinity v1 core](https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.27/#affinity-v1-core) + # + # For example: + # affinity: + # nodeAffinity: + # requiredDuringSchedulingIgnoredDuringExecution: + # nodeSelectorTerms: + # - matchExpressions: + # - key: foo.bar.com/role + # operator: In + # values: + # - master + affinity: {} + + # -- Resources to provide to the llmisvc controller pod + # + # For example: + # resources: + # limits: + # cpu: 100m + # memory: 300Mi + # requests: + # cpu: 100m + # memory: 300Mi + # + # For more information, see [Resource Management for Pods and Containers](https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/) + resources: + limits: + cpu: 100m + memory: 300Mi + requests: + cpu: 100m + memory: 300Mi + + # -- Number of replicas for the controller deployment + replicas: 1 + + # -- Deployment strategy + strategy: + type: RollingUpdate + rollingUpdate: + maxSurge: 1 + maxUnavailable: 0 + + # -- Liveness probe configuration + livenessProbe: + enabled: true + initialDelaySeconds: 30 + periodSeconds: 10 + timeoutSeconds: 5 + failureThreshold: 5 + httpGet: + path: /healthz + port: 8081 + + # -- Readiness probe configuration + readinessProbe: + enabled: true + initialDelaySeconds: 30 + periodSeconds: 5 + timeoutSeconds: 5 + failureThreshold: 5 + httpGet: + path: /readyz + port: 8081 + + # -- Service configuration + service: + # -- Service type + type: ClusterIP + # -- Service port for metrics + port: 8443 + # -- Service target port + targetPort: metrics + + # -- Service account configuration + serviceAccount: + # -- Name of the service account to use + # If not set, a name is generated using the deployment name + name: "" + + # -- Environment variables to be set on the controller container + env: [] + + # -- Additional volumes to be mounted + extraVolumes: [] + + # -- Additional volume mounts + extraVolumeMounts: [] + + # -- Additional command line arguments + extraArgs: [] + + # -- Termination grace period in seconds + terminationGracePeriodSeconds: 10 diff --git a/cmd/llmisvc/main.go b/cmd/llmisvc/main.go new file mode 100644 index 00000000000..53c909abd40 --- /dev/null +++ b/cmd/llmisvc/main.go @@ -0,0 +1,159 @@ +/* +Copyright 2025 The KServe Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package main + +import ( + "crypto/tls" + "flag" + "os" + + "k8s.io/apimachinery/pkg/runtime" + utilruntime "k8s.io/apimachinery/pkg/util/runtime" + clientgoscheme "k8s.io/client-go/kubernetes/scheme" + ctrl "sigs.k8s.io/controller-runtime" + "sigs.k8s.io/controller-runtime/pkg/healthz" + "sigs.k8s.io/controller-runtime/pkg/log/zap" + "sigs.k8s.io/controller-runtime/pkg/metrics/filters" + metricsserver "sigs.k8s.io/controller-runtime/pkg/metrics/server" + "sigs.k8s.io/controller-runtime/pkg/webhook" + + "github.com/kserve/kserve/pkg/apis/serving/v1alpha1" + + "github.com/kserve/kserve/pkg/controller/v1alpha1/llmisvc" +) + +var ( + scheme = runtime.NewScheme() + setupLog = ctrl.Log.WithName("setup") +) + +func init() { + utilruntime.Must(clientgoscheme.AddToScheme(scheme)) + + utilruntime.Must(v1alpha1.AddToScheme(scheme)) +} + +type Options struct { + metricsAddr string + webhookPort int + enableLeaderElection bool + probeAddr string + metricsSecure bool + enableHTTP2 bool + zapOpts zap.Options +} + +func DefaultOptions() Options { + return Options{ + metricsAddr: ":8443", + webhookPort: 9443, + enableLeaderElection: false, + probeAddr: ":8081", + metricsSecure: true, + enableHTTP2: false, + zapOpts: zap.Options{}, + } +} + +// GetOptions parses the program flags and returns them as Options. +func GetOptions() Options { + opts := DefaultOptions() + flag.StringVar(&opts.metricsAddr, "metrics-addr", opts.metricsAddr, "The address the metric endpoint binds to.") + flag.IntVar(&opts.webhookPort, "webhook-port", opts.webhookPort, "The port that the webhook server binds to.") + flag.BoolVar(&opts.enableLeaderElection, "leader-elect", opts.enableLeaderElection, + "Enable leader election for kserve controller manager. "+ + "Enabling this will ensure there is only one active kserve controller manager.") + flag.StringVar(&opts.probeAddr, "health-probe-addr", opts.probeAddr, "The address the probe endpoint binds to.") + flag.BoolVar(&opts.metricsSecure, "metrics-secure", opts.metricsSecure, "Whether to serve metric via HTTPS.") + flag.BoolVar(&opts.enableHTTP2, "enable-http2", false, "If set, HTTP/2 will be enabled for the metrics and webhook servers") + opts.zapOpts.BindFlags(flag.CommandLine) + flag.Parse() + return opts +} + +func main() { + options := GetOptions() + ctrl.SetLogger(zap.New(zap.UseFlagOptions(&options.zapOpts))) + + // http/2 should be disabled due to its vulnerabilities. More specifically, disabling http/2 will + // prevent from being vulnerable to the HTTP/2 Stream Cancellation and + // Rapid Reset CVEs. For more information see: + // - https://github.com/advisories/GHSA-qppj-fm5r-hxr3 + // - https://github.com/advisories/GHSA-4374-p667-p6c8 + disableHTTP2 := func(c *tls.Config) { + setupLog.Info("disabling http/2") + c.NextProtos = []string{"http/1.1"} + } + + var tlsOpts []func(*tls.Config) + if !options.enableHTTP2 { + tlsOpts = append(tlsOpts, disableHTTP2) + } + // Metrics endpoint is enabled in 'config/default/kustomization.yaml'. The Metrics options configure the server. + // More info: + // - https://pkg.go.dev/sigs.k8s.io/controller-runtime@v0.21.0/pkg/metrics/server + // - https://book.kubebuilder.io/reference/metrics.html + metricsServerOptions := metricsserver.Options{ + BindAddress: options.metricsAddr, + SecureServing: options.metricsSecure, + TLSOpts: tlsOpts, + } + + if options.metricsSecure { + // FilterProvider is used to protect the metrics endpoint with authn/authz. + // These configurations ensure that only authorized users and service accounts + // can access the metrics endpoint. The RBAC are configured in 'config/rbac/kustomization.yaml'. More info: + // https://pkg.go.dev/sigs.k8s.io/controller-runtime@v0.21.0/pkg/metrics/filters#WithAuthenticationAndAuthorization + metricsServerOptions.FilterProvider = filters.WithAuthenticationAndAuthorization + } + + mgr, err := ctrl.NewManager(ctrl.GetConfigOrDie(), ctrl.Options{ + Scheme: scheme, + Metrics: metricsServerOptions, + WebhookServer: webhook.NewServer(webhook.Options{Port: options.webhookPort, TLSOpts: tlsOpts}), + HealthProbeBindAddress: options.probeAddr, + LeaderElection: options.enableLeaderElection, + LeaderElectionID: "llminferenceservice-kserve-controller-manager", + }) + if err != nil { + setupLog.Error(err, "unable to start manager") + os.Exit(1) + } + + if err := (&llmisvc.LLMISVCReconciler{ + Client: mgr.GetClient(), + Scheme: mgr.GetScheme(), + }).SetupWithManager(mgr); err != nil { + setupLog.Error(err, "unable to create controller", "controller", "LLMInferenceService") + os.Exit(1) + } + + if err := mgr.AddHealthzCheck("healthz", healthz.Ping); err != nil { + setupLog.Error(err, "unable to set up health check") + os.Exit(1) + } + if err := mgr.AddReadyzCheck("readyz", healthz.Ping); err != nil { + setupLog.Error(err, "unable to set up ready check") + os.Exit(1) + } + + setupLog.Info("starting manager") + if err := mgr.Start(ctrl.SetupSignalHandler()); err != nil { + setupLog.Error(err, "unable to run the manager") + os.Exit(1) + } +} diff --git a/config/rbac/llmisvc/role.yaml b/config/rbac/llmisvc/role.yaml new file mode 100644 index 00000000000..7bedb10becf --- /dev/null +++ b/config/rbac/llmisvc/role.yaml @@ -0,0 +1,27 @@ +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRole +metadata: + name: llmisvc-manager-role +rules: +- apiGroups: + - serving.kserve.io + resources: + - llminferenceservices + - llminferenceservices/finalizers + verbs: + - create + - delete + - get + - list + - patch + - update + - watch +- apiGroups: + - serving.kserve.io + resources: + - llminferenceservices/status + verbs: + - get + - patch + - update diff --git a/go.mod b/go.mod index 97d4fa7864c..23830e7250a 100644 --- a/go.mod +++ b/go.mod @@ -63,8 +63,11 @@ require ( github.com/GoogleCloudPlatform/opentelemetry-operations-go/detectors/gcp v1.25.0 // indirect github.com/GoogleCloudPlatform/opentelemetry-operations-go/exporter/metric v0.48.1 // indirect github.com/GoogleCloudPlatform/opentelemetry-operations-go/internal/resourcemapping v0.48.1 // indirect + github.com/antlr4-go/antlr/v4 v4.13.0 // indirect github.com/beorn7/perks v1.0.1 // indirect + github.com/blang/semver/v4 v4.0.0 // indirect github.com/blendle/zapdriver v1.3.1 // indirect + github.com/cenkalti/backoff/v4 v4.3.0 // indirect github.com/census-instrumentation/opencensus-proto v0.4.1 // indirect github.com/cespare/xxhash/v2 v2.3.0 // indirect github.com/cncf/xds/go v0.0.0-20241223141626-cff3c89139a3 // indirect @@ -88,6 +91,7 @@ require ( github.com/gogo/protobuf v1.3.2 // indirect github.com/golang/groupcache v0.0.0-20241129210726-2c02b8208cf8 // indirect github.com/golang/protobuf v1.5.4 // indirect + github.com/google/cel-go v0.23.2 // indirect github.com/google/gnostic-models v0.6.9 // indirect github.com/google/go-containerregistry v0.13.0 // indirect github.com/google/pprof v0.0.0-20250208200701-d0013a598941 // indirect @@ -120,6 +124,7 @@ require ( github.com/prometheus/procfs v0.16.1 // indirect github.com/prometheus/prometheus v0.55.1 // indirect github.com/prometheus/statsd_exporter v0.27.1 // indirect + github.com/stoewer/go-strcase v1.3.0 // indirect github.com/stretchr/objx v0.5.2 // indirect github.com/tidwall/match v1.1.1 // indirect github.com/tidwall/pretty v1.2.1 // indirect @@ -131,11 +136,14 @@ require ( go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.59.0 // indirect go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.60.0 // indirect go.opentelemetry.io/otel v1.35.0 // indirect + go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.33.0 // indirect + go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.33.0 // indirect go.opentelemetry.io/otel/exporters/prometheus v0.56.0 // indirect go.opentelemetry.io/otel/metric v1.35.0 // indirect go.opentelemetry.io/otel/sdk v1.35.0 // indirect go.opentelemetry.io/otel/sdk/metric v1.35.0 // indirect go.opentelemetry.io/otel/trace v1.35.0 // indirect + go.opentelemetry.io/proto/otlp v1.4.0 // indirect go.uber.org/multierr v1.11.0 // indirect golang.org/x/crypto v0.39.0 // indirect golang.org/x/exp v0.0.0-20250606033433-dcc06ee1d476 // indirect @@ -158,7 +166,10 @@ require ( gopkg.in/yaml.v2 v2.4.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect k8s.io/apiextensions-apiserver v0.33.1 // indirect + k8s.io/apiserver v0.33.1 // indirect + k8s.io/component-base v0.33.1 // indirect k8s.io/gengo/v2 v2.0.0-20250207200755-1244d31929d7 // indirect + sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.31.2 // indirect sigs.k8s.io/json v0.0.0-20241014173422-cfa47c3a1cc8 // indirect sigs.k8s.io/randfill v1.0.0 // indirect sigs.k8s.io/structured-merge-diff/v4 v4.7.0 // indirect diff --git a/go.sum b/go.sum index 97aba2d4de0..7657e779268 100644 --- a/go.sum +++ b/go.sum @@ -96,6 +96,8 @@ github.com/alecthomas/units v0.0.0-20211218093645-b94a6e3cc137/go.mod h1:OMCwj8V github.com/alecthomas/units v0.0.0-20240626203959-61d1e3462e30 h1:t3eaIm0rUkzbrIewtiFmMK5RXHej2XnoXNhxVsAYUfg= github.com/alecthomas/units v0.0.0-20240626203959-61d1e3462e30/go.mod h1:fvzegU4vN3H1qMT+8wDmzjAcDONcgo2/SZ/TyfdUOFs= github.com/antihax/optional v1.0.0/go.mod h1:uupD/76wgC+ih3iEmQUL+0Ugr19nfwCT1kdvxnR2qWY= +github.com/antlr4-go/antlr/v4 v4.13.0 h1:lxCg3LAv+EUK6t1i0y1V6/SLeUi0eKEKdhQAlS8TVTI= +github.com/antlr4-go/antlr/v4 v4.13.0/go.mod h1:pfChB/xh/Unjila75QW7+VU4TSnWnnk9UTnmpPaOR2g= github.com/armon/go-metrics v0.4.1 h1:hR91U9KYmb6bLBYLQjyM+3j+rcd/UhE+G78SFnF8gJA= github.com/armon/go-metrics v0.4.1/go.mod h1:E6amYzXo6aW1tqzoZGT755KkbgrJsSdpwZ+3JqfkOG4= github.com/aws/aws-sdk-go v1.55.6 h1:cSg4pvZ3m8dgYcgqB97MrcdjUmZ1BeMYKUxMMB89IPk= @@ -104,8 +106,12 @@ github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24 github.com/beorn7/perks v1.0.0/go.mod h1:KWe93zE9D1o94FZ5RNwFwVgaQK1VOXiVxmqh+CedLV8= github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= +github.com/blang/semver/v4 v4.0.0 h1:1PFHFE6yCCTv8C1TeyNNarDzntLi7wMI5i/pzqYIsAM= +github.com/blang/semver/v4 v4.0.0/go.mod h1:IbckMUScFkM3pff0VJDNKRiT6TG/YpiHIM2yvyW5YoQ= github.com/blendle/zapdriver v1.3.1 h1:C3dydBOWYRiOk+B8X9IVZ5IOe+7cl+tGOexN4QqHfpE= github.com/blendle/zapdriver v1.3.1/go.mod h1:mdXfREi6u5MArG4j9fewC+FGnXaBR+T4Ox4J2u4eHCc= +github.com/cenkalti/backoff/v4 v4.3.0 h1:MyRJ/UdXutAwSAT+s3wNd7MfTIcy71VQueUuFK343L8= +github.com/cenkalti/backoff/v4 v4.3.0/go.mod h1:Y3VNntkOUPxTVeUxJ/G5vcM//AlwfmyYozVcomhLiZE= github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= github.com/census-instrumentation/opencensus-proto v0.4.1 h1:iKLQ0xPNFxR/2hzXZMrBo8f1j86j5WHzznCCQxV/b8g= github.com/census-instrumentation/opencensus-proto v0.4.1/go.mod h1:4T9NM4+4Vw91VeyqjLS6ao50K5bOcLKN6Q42XnYaRYw= @@ -253,6 +259,8 @@ github.com/golang/protobuf v1.5.4 h1:i7eJL8qZTpSEXOPTxNKhASYpMn+8e5Q6AdndVa1dWek github.com/golang/protobuf v1.5.4/go.mod h1:lnTiLA8Wa4RWRcIUkrtSVa5nRhsEGBg48fD6rSs7xps= github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= +github.com/google/cel-go v0.23.2 h1:UdEe3CvQh3Nv+E/j9r1Y//WO0K0cSyD7/y0bzyLIMI4= +github.com/google/cel-go v0.23.2/go.mod h1:52Pb6QsDbC5kvgxvZhiL9QX1oZEkcUF/ZqaPx1J5Wwo= github.com/google/gnostic-models v0.6.9 h1:MU/8wDLif2qCXZmzncUQ/BOfxWfthHi63KqpoNbWqVw= github.com/google/gnostic-models v0.6.9/go.mod h1:CiWsm0s6BSQd1hRn8/QmxqB6BesYcbSZxsz9b0KuDBw= github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M= @@ -511,6 +519,8 @@ github.com/spf13/cobra v1.8.1/go.mod h1:wHxEcudfqmLYa8iTfL+OuZPbBZkmvliBWKIezN3k github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= github.com/spf13/pflag v1.0.6 h1:jFzHGLGAlb3ruxLB8MhbI6A8+AQX/2eW4qeyNZXNp2o= github.com/spf13/pflag v1.0.6/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= +github.com/stoewer/go-strcase v1.3.0 h1:g0eASXYtp+yvN9fK8sH94oCIk0fau9uV1/ZdJ0AVEzs= +github.com/stoewer/go-strcase v1.3.0/go.mod h1:fAH5hQ5pehh+j3nZfvwdk2RgEgQjAoM8wodgtPmh1xo= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw= @@ -566,6 +576,10 @@ go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.60.0 h1:sbiXRND go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.60.0/go.mod h1:69uWxva0WgAA/4bu2Yy70SLDBwZXuQ6PbBpbsa5iZrQ= go.opentelemetry.io/otel v1.35.0 h1:xKWKPxrxB6OtMCbmMY021CqC45J+3Onta9MqjhnusiQ= go.opentelemetry.io/otel v1.35.0/go.mod h1:UEqy8Zp11hpkUrL73gSlELM0DupHoiq72dR+Zqel/+Y= +go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.33.0 h1:Vh5HayB/0HHfOQA7Ctx69E/Y/DcQSMPpKANYVMQ7fBA= +go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.33.0/go.mod h1:cpgtDBaqD/6ok/UG0jT15/uKjAY8mRA53diogHBg3UI= +go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.33.0 h1:5pojmb1U1AogINhN3SurB+zm/nIcusopeBNp42f45QM= +go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.33.0/go.mod h1:57gTHJSE5S1tqg+EKsLPlTWhpHMsWlVmer+LA926XiA= go.opentelemetry.io/otel/exporters/prometheus v0.56.0 h1:GnCIi0QyG0yy2MrJLzVrIM7laaJstj//flf1zEJCG+E= go.opentelemetry.io/otel/exporters/prometheus v0.56.0/go.mod h1:JQcVZtbIIPM+7SWBB+T6FK+xunlyidwLp++fN0sUaOk= go.opentelemetry.io/otel/exporters/stdout/stdoutmetric v1.29.0 h1:WDdP9acbMYjbKIyJUhTvtzj601sVJOqgWdUxSdR/Ysc= @@ -578,6 +592,8 @@ go.opentelemetry.io/otel/sdk/metric v1.35.0 h1:1RriWBmCKgkeHEhM7a2uMjMUfP7MsOF5J go.opentelemetry.io/otel/sdk/metric v1.35.0/go.mod h1:is6XYCUMpcKi+ZsOvfluY5YstFnhW0BidkR+gL+qN+w= go.opentelemetry.io/otel/trace v1.35.0 h1:dPpEfJu1sDIqruz7BHFG3c7528f6ddfSWfFDVt/xgMs= go.opentelemetry.io/otel/trace v1.35.0/go.mod h1:WUk7DtFp1Aw2MkvqGdwiXYDZZNvA/1J8o6xRXLrIkyc= +go.opentelemetry.io/proto/otlp v1.4.0 h1:TA9WRvW6zMwP+Ssb6fLoUIuirti1gGbP28GcKG1jgeg= +go.opentelemetry.io/proto/otlp v1.4.0/go.mod h1:PPBWZIP98o2ElSqI35IHfu7hIhSwvc5N38Jw8pXuGFY= go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= go.uber.org/goleak v1.3.0 h1:2K3zAYmnTNqV73imy9J1T3WC+gmCePx2hEGkimedGto= go.uber.org/goleak v1.3.0/go.mod h1:CoHD4mav9JJNrW/WLlf7HGZPjdw8EucARQHekz1X6bE= @@ -937,10 +953,14 @@ k8s.io/apiextensions-apiserver v0.33.1 h1:N7ccbSlRN6I2QBcXevB73PixX2dQNIW0ZRuguE k8s.io/apiextensions-apiserver v0.33.1/go.mod h1:uNQ52z1A1Gu75QSa+pFK5bcXc4hq7lpOXbweZgi4dqA= k8s.io/apimachinery v0.33.1 h1:mzqXWV8tW9Rw4VeW9rEkqvnxj59k1ezDUl20tFK/oM4= k8s.io/apimachinery v0.33.1/go.mod h1:BHW0YOu7n22fFv/JkYOEfkUYNRN0fj0BlvMFWA7b+SM= +k8s.io/apiserver v0.33.1 h1:yLgLUPDVC6tHbNcw5uE9mo1T6ELhJj7B0geifra3Qdo= +k8s.io/apiserver v0.33.1/go.mod h1:VMbE4ArWYLO01omz+k8hFjAdYfc3GVAYPrhP2tTKccs= k8s.io/client-go v0.33.1 h1:ZZV/Ks2g92cyxWkRRnfUDsnhNn28eFpt26aGc8KbXF4= k8s.io/client-go v0.33.1/go.mod h1:JAsUrl1ArO7uRVFWfcj6kOomSlCv+JpvIsp6usAGefA= k8s.io/code-generator v0.33.1 h1:ZLzIRdMsh3Myfnx9BaooX6iQry29UJjVfVG+BuS+UMw= k8s.io/code-generator v0.33.1/go.mod h1:HUKT7Ubp6bOgIbbaPIs9lpd2Q02uqkMCMx9/GjDrWpY= +k8s.io/component-base v0.33.1 h1:EoJ0xA+wr77T+G8p6T3l4efT2oNwbqBVKR71E0tBIaI= +k8s.io/component-base v0.33.1/go.mod h1:guT/w/6piyPfTgq7gfvgetyXMIh10zuXA6cRRm3rDuY= k8s.io/component-helpers v0.32.1 h1:TwdsSM1vW9GjnfX18lkrZbwE5G9psCIS2/rhenTDXd8= k8s.io/component-helpers v0.32.1/go.mod h1:1JT1Ei3FD29yFQ18F3laj1WyvxYdHIhyxx6adKMFQXI= k8s.io/gengo/v2 v2.0.0-20250207200755-1244d31929d7 h1:2OX19X59HxDprNCVrWi6jb7LW1PoqTlYqEq5H2oetog= @@ -960,6 +980,8 @@ knative.dev/serving v0.44.0/go.mod h1:9bFONngDZtkdYZkP5ko9LDS9ZelnFY9SaPoHKG0vFx rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= rsc.io/quote/v3 v3.1.0/go.mod h1:yEA65RcK8LyAZtP9Kv3t0HmxON59tX3rD+tICJqUlj0= rsc.io/sampler v1.3.0/go.mod h1:T1hPZKmBbMNahiBKFy5HrXp6adAjACjK9JXDnKaTXpA= +sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.31.2 h1:jpcvIRr3GLoUoEKRkHKSmGjxb6lWwrBlJsXc+eUYQHM= +sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.31.2/go.mod h1:Ve9uj1L+deCXFrPOk1LpFXqTg7LCFzFso6PA48q/XZw= sigs.k8s.io/controller-runtime v0.19.7 h1:DLABZfMr20A+AwCZOHhcbcu+TqBXnJZaVBri9K3EO48= sigs.k8s.io/controller-runtime v0.19.7/go.mod h1:iRmWllt8IlaLjvTTDLhRBXIEtkCK6hwVBJJsYS9Ajf4= sigs.k8s.io/gateway-api v1.2.1 h1:fZZ/+RyRb+Y5tGkwxFKuYuSRQHu9dZtbjenblleOLHM= diff --git a/llmisvc-controller.Dockerfile b/llmisvc-controller.Dockerfile new file mode 100644 index 00000000000..1924371ae2e --- /dev/null +++ b/llmisvc-controller.Dockerfile @@ -0,0 +1,28 @@ +# Build the manager binary +FROM golang:1.24 AS builder + +# Copy in the go src +WORKDIR /go/src/github.com/kserve/kserve +COPY go.mod go.mod +COPY go.sum go.sum + +RUN go mod download + +COPY cmd/ cmd/ +COPY pkg/ pkg/ + +# Build +RUN CGO_ENABLED=0 GOOS=linux go build -a -o manager ./cmd/llmisvc + +# Generate third-party licenses +COPY LICENSE LICENSE +RUN go install github.com/google/go-licenses@latest +# Forbidden Licenses: https://github.com/google/licenseclassifier/blob/e6a9bb99b5a6f71d5a34336b8245e305f5430f99/license_type.go#L341 +RUN go-licenses check ./cmd/... ./pkg/... --disallowed_types="forbidden,unknown" +RUN go-licenses save --save_path third_party/library ./cmd/llmisvc + +# Copy the controller-manager into a thin image +FROM gcr.io/distroless/static:nonroot +COPY --from=builder /go/src/github.com/kserve/kserve/third_party /third_party +COPY --from=builder /go/src/github.com/kserve/kserve/llmisvc / +ENTRYPOINT ["/llmisvc"] diff --git a/pkg/controller/v1alpha1/llmisvc/controller.go b/pkg/controller/v1alpha1/llmisvc/controller.go new file mode 100644 index 00000000000..9f12826977e --- /dev/null +++ b/pkg/controller/v1alpha1/llmisvc/controller.go @@ -0,0 +1,52 @@ +/* +Copyright 2025 The KServe Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package llmisvc + +import ( + "context" + + "k8s.io/apimachinery/pkg/runtime" + ctrl "sigs.k8s.io/controller-runtime" + "sigs.k8s.io/controller-runtime/pkg/client" + logf "sigs.k8s.io/controller-runtime/pkg/log" + + "github.com/kserve/kserve/pkg/apis/serving/v1alpha1" +) + +// +kubebuilder:rbac:groups=serving.kserve.io,resources=llminferenceservices;llminferenceservices/finalizers,verbs=get;list;watch;create;update;patch;delete +// +kubebuilder:rbac:groups=serving.kserve.io,resources=llminferenceservices/status,verbs=get;update;patch + +// LLMISVCReconciler reconciles a LLMInferenceService object +// This controller is responsible for managing the lifecycle of LLMInferenceService resources. +type LLMISVCReconciler struct { + client.Client + Scheme *runtime.Scheme +} + +func (r *LLMISVCReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error) { + log := logf.FromContext(ctx) + log.Info("Reconciling LLMISVC", "name", req.Name, "namespace", req.Namespace) + // Implement the reconciliation logic here + return ctrl.Result{}, nil +} + +// SetupWithManager sets up the controller with the Manager. +func (r *LLMISVCReconciler) SetupWithManager(mgr ctrl.Manager) error { + return ctrl.NewControllerManagedBy(mgr). + For(&v1alpha1.LLMInferenceService{}). + Complete(r) +} From a3862fe21783b1ecbf69c732a92574e0c1cdde8f Mon Sep 17 00:00:00 2001 From: Vedant Mahabaleshwarkar Date: Thu, 3 Jul 2025 12:38:49 -0400 Subject: [PATCH 6/9] Add logic to merge specs for LLMInferenceService (#4563) Signed-off-by: Vedant Mahabaleshwarkar Co-authored-by: Bartosz Majsak Co-authored-by: Pierangelo Di Pilato --- .../v1alpha1/llmisvc/config_merge.go | 120 ++ .../v1alpha1/llmisvc/config_merge_test.go | 1524 +++++++++++++++++ .../v1alpha1/llmisvc/controller_types.go | 23 + 3 files changed, 1667 insertions(+) create mode 100644 pkg/controller/v1alpha1/llmisvc/config_merge.go create mode 100644 pkg/controller/v1alpha1/llmisvc/config_merge_test.go create mode 100644 pkg/controller/v1alpha1/llmisvc/controller_types.go diff --git a/pkg/controller/v1alpha1/llmisvc/config_merge.go b/pkg/controller/v1alpha1/llmisvc/config_merge.go new file mode 100644 index 00000000000..57ad1d71ac7 --- /dev/null +++ b/pkg/controller/v1alpha1/llmisvc/config_merge.go @@ -0,0 +1,120 @@ +/* +Copyright 2025 The KServe Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package llmisvc + +import ( + "bytes" + "encoding/json" + "fmt" + "text/template" + + "k8s.io/apimachinery/pkg/util/strategicpatch" + "knative.dev/pkg/kmeta" + + "github.com/kserve/kserve/pkg/apis/serving/v1alpha1" +) + +func ReplaceVariables(llmSvc *v1alpha1.LLMInferenceService, llmSvcCfg *v1alpha1.LLMInferenceServiceConfig, reconcilerConfig *Config) (*v1alpha1.LLMInferenceServiceConfig, error) { + templateBytes, _ := json.Marshal(llmSvcCfg) + buf := bytes.NewBuffer(nil) + config := struct { + *v1alpha1.LLMInferenceService + GlobalConfig *Config + }{ + LLMInferenceService: llmSvc, + GlobalConfig: reconcilerConfig, + } + t, err := template.New("config"). + Funcs(map[string]any{ + "ChildName": kmeta.ChildName, + }). + Option("missingkey=error"). + Parse(string(templateBytes)) + if err != nil { + return nil, fmt.Errorf("failed to parse template config: %w", err) + } + if err := t.Execute(buf, config); err != nil { + return nil, fmt.Errorf("failed to merge config: %w", err) + } + + out := &v1alpha1.LLMInferenceServiceConfig{} + if err := json.Unmarshal(buf.Bytes(), out); err != nil { + return nil, fmt.Errorf("failed to unmarshal config from template: %w", err) + } + return out, nil +} + +func MergeSpecs(cfgs ...v1alpha1.LLMInferenceServiceSpec) (v1alpha1.LLMInferenceServiceSpec, error) { + if len(cfgs) == 0 { + return v1alpha1.LLMInferenceServiceSpec{}, nil + } + + out := cfgs[0] + for i := 1; i < len(cfgs); i++ { + cfg := cfgs[i] + var err error + out, err = mergeSpecs(out, cfg) + if err != nil { + return v1alpha1.LLMInferenceServiceSpec{}, fmt.Errorf("failed to merge specs: %w", err) + } + } + return out, nil +} + +// mergeSpecs performs a strategic merge by creating a clean patch from the override +// object and applying it to the base object. +func mergeSpecs(base, override v1alpha1.LLMInferenceServiceSpec) (v1alpha1.LLMInferenceServiceSpec, error) { + baseJSON, err := json.Marshal(base) + if err != nil { + return v1alpha1.LLMInferenceServiceSpec{}, fmt.Errorf("could not marshal base spec: %w", err) + } + + // To create a patch containing only the fields specified in the override, + // we create a patch between a zero-valued ("empty") object and the override object. + // This prevents zero-valued fields in the override struct (e.g., an empty string for an + // unspecified image) from incorrectly wiping out values from the base. + zero := v1alpha1.LLMInferenceServiceSpec{} + zeroJSON, err := json.Marshal(zero) + if err != nil { + return v1alpha1.LLMInferenceServiceSpec{}, fmt.Errorf("could not marshal zero spec: %w", err) + } + + overrideJSON, err := json.Marshal(override) + if err != nil { + return v1alpha1.LLMInferenceServiceSpec{}, fmt.Errorf("could not marshal override spec: %w", err) + } + + // Create the patch. It will only contain the non-default fields from the override. + patch, err := strategicpatch.CreateTwoWayMergePatch(zeroJSON, overrideJSON, v1alpha1.LLMInferenceServiceSpec{}) + if err != nil { + return v1alpha1.LLMInferenceServiceSpec{}, fmt.Errorf("could not create merge patch from override: %w", err) + } + + // Apply this "clean" patch to the base JSON. The strategic merge logic will correctly + // merge lists and objects based on their Kubernetes patch strategy annotations. + mergedJSON, err := strategicpatch.StrategicMergePatch(baseJSON, patch, v1alpha1.LLMInferenceServiceSpec{}) + if err != nil { + return v1alpha1.LLMInferenceServiceSpec{}, fmt.Errorf("could not apply merge patch: %w", err) + } + + // Unmarshal the merged JSON back into a Go struct. + var finalSpec v1alpha1.LLMInferenceServiceSpec + if err := json.Unmarshal(mergedJSON, &finalSpec); err != nil { + return v1alpha1.LLMInferenceServiceSpec{}, fmt.Errorf("could not unmarshal merged spec: %w", err) + } + return finalSpec, nil +} diff --git a/pkg/controller/v1alpha1/llmisvc/config_merge_test.go b/pkg/controller/v1alpha1/llmisvc/config_merge_test.go new file mode 100644 index 00000000000..92e96e949ca --- /dev/null +++ b/pkg/controller/v1alpha1/llmisvc/config_merge_test.go @@ -0,0 +1,1524 @@ +/* +Copyright 2025 The KServe Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package llmisvc_test + +import ( + "testing" + + "github.com/google/go-cmp/cmp" + corev1 "k8s.io/api/core/v1" + "k8s.io/apimachinery/pkg/api/resource" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/utils/ptr" + "knative.dev/pkg/apis" + igwapi "sigs.k8s.io/gateway-api-inference-extension/api/v1alpha2" + gwapiv1 "sigs.k8s.io/gateway-api/apis/v1" + + "github.com/kserve/kserve/pkg/apis/serving/v1alpha1" + "github.com/kserve/kserve/pkg/controller/v1alpha1/llmisvc" +) + +func TestMergeSpecs(t *testing.T) { + tests := []struct { + name string + cfgs []v1alpha1.LLMInferenceServiceSpec + want v1alpha1.LLMInferenceServiceSpec + wantErr bool + }{ + { + name: "no configs", + cfgs: []v1alpha1.LLMInferenceServiceSpec{}, + want: v1alpha1.LLMInferenceServiceSpec{}, + wantErr: false, + }, + { + name: "single config", + cfgs: []v1alpha1.LLMInferenceServiceSpec{ + {Model: v1alpha1.LLMModelSpec{URI: mustParseURL("model-a")}}, + }, + want: v1alpha1.LLMInferenceServiceSpec{Model: v1alpha1.LLMModelSpec{URI: mustParseURL("model-a")}}, + wantErr: false, + }, + { + name: "two configs simple merge", + cfgs: []v1alpha1.LLMInferenceServiceSpec{ + {Model: v1alpha1.LLMModelSpec{URI: mustParseURL("model-a")}}, + }, + want: v1alpha1.LLMInferenceServiceSpec{ + Model: v1alpha1.LLMModelSpec{URI: mustParseURL("model-a")}, + }, + wantErr: false, + }, + { + name: "two configs with override", + cfgs: []v1alpha1.LLMInferenceServiceSpec{ + { + Model: v1alpha1.LLMModelSpec{URI: mustParseURL("model-a")}, + WorkloadSpec: v1alpha1.WorkloadSpec{ + Replicas: ptr.To[int32](1), + }, + }, + { + Model: v1alpha1.LLMModelSpec{URI: mustParseURL("model-b")}, + WorkloadSpec: v1alpha1.WorkloadSpec{ + Replicas: ptr.To[int32](2), + }, + }, + }, + want: v1alpha1.LLMInferenceServiceSpec{ + Model: v1alpha1.LLMModelSpec{URI: mustParseURL("model-b")}, + WorkloadSpec: v1alpha1.WorkloadSpec{ + Replicas: ptr.To[int32](2), + }, + }, + wantErr: false, + }, + { + name: "three configs chained merge", + cfgs: []v1alpha1.LLMInferenceServiceSpec{ + {Model: v1alpha1.LLMModelSpec{URI: mustParseURL("model-a")}}, + { + Model: v1alpha1.LLMModelSpec{URI: mustParseURL("model-b")}, + }, + }, + want: v1alpha1.LLMInferenceServiceSpec{ + Model: v1alpha1.LLMModelSpec{URI: mustParseURL("model-b")}, + }, + wantErr: false, + }, + { + name: "deep merge with podspec template", + cfgs: []v1alpha1.LLMInferenceServiceSpec{ + // Base configuration + { + WorkloadSpec: v1alpha1.WorkloadSpec{ + Replicas: ptr.To[int32](1), + Template: &corev1.PodSpec{ + InitContainers: []corev1.Container{ + { + Name: "storage-initializer", + Image: "kserve/storage-initializer:latest", + Resources: corev1.ResourceRequirements{ + Requests: corev1.ResourceList{ + corev1.ResourceStorage: resource.MustParse("1Mi"), + }, + }, + }, + }, + Containers: []corev1.Container{ + { + Name: "kserve-container", + Image: "base:0.1", + Resources: corev1.ResourceRequirements{ + Requests: corev1.ResourceList{ + corev1.ResourceCPU: resource.MustParse("1"), + }, + }, + }, + }, + Tolerations: []corev1.Toleration{ + {Key: "team", Operator: corev1.TolerationOpEqual, Value: "a"}, + }, + }, + }, + }, + // Override configuration + { + WorkloadSpec: v1alpha1.WorkloadSpec{ + Replicas: ptr.To[int32](2), + Template: &corev1.PodSpec{ + InitContainers: []corev1.Container{ + { + Name: "storage-initializer", + Resources: corev1.ResourceRequirements{ + Requests: corev1.ResourceList{ + corev1.ResourceStorage: resource.MustParse("1Gi"), + }, + }, + }, + }, + Containers: []corev1.Container{ + // This container should replace the base one due to the same name + { + Name: "kserve-container", + Image: "override:1.0", + Env: []corev1.EnvVar{ + {Name: "FOO", Value: "bar"}, + }, + Resources: corev1.ResourceRequirements{ + Requests: corev1.ResourceList{ + corev1.ResourceCPU: resource.MustParse("2"), // Override CPU + }, + }, + }, + // This is a new container that should be added + { + Name: "transformer", + Image: "transformer:latest", + }, + }, + // Tolerations should be REPLACED, not merged, as there is no patchMergeKey + Tolerations: []corev1.Toleration{ + {Key: "gpu", Operator: corev1.TolerationOpExists}, + }, + PriorityClassName: "high-priority", // Add a new field + }, + }, + }, + }, + // Expected result of the merge + want: v1alpha1.LLMInferenceServiceSpec{ + WorkloadSpec: v1alpha1.WorkloadSpec{ + Replicas: ptr.To[int32](2), + Template: &corev1.PodSpec{ + InitContainers: []corev1.Container{ + { + Name: "storage-initializer", + Image: "kserve/storage-initializer:latest", // Image is preserved from base + Resources: corev1.ResourceRequirements{ // Resources are updated from override + Requests: corev1.ResourceList{ + corev1.ResourceStorage: resource.MustParse("1Gi"), + }, + }, + }, + }, + Containers: []corev1.Container{ + { + Name: "kserve-container", + Image: "override:1.0", + Env: []corev1.EnvVar{ + {Name: "FOO", Value: "bar"}, + }, + Resources: corev1.ResourceRequirements{ + Requests: corev1.ResourceList{ + corev1.ResourceCPU: resource.MustParse("2"), + }, + }, + }, + { + Name: "transformer", + Image: "transformer:latest", + }, + }, + // Tolerations slice is replaced by the override + Tolerations: []corev1.Toleration{ + {Key: "gpu", Operator: corev1.TolerationOpExists}, + }, + PriorityClassName: "high-priority", + }, + }, + }, + wantErr: false, + }, + { + name: "merge with prefill spec", + cfgs: []v1alpha1.LLMInferenceServiceSpec{ + // Base has only a decode workload + { + WorkloadSpec: v1alpha1.WorkloadSpec{ + Replicas: ptr.To[int32](1), + Template: &corev1.PodSpec{Containers: []corev1.Container{{Name: "kserve-container", Image: "decode:0.1"}}}, + }, + }, + // Override adds a prefill workload + { + Prefill: &v1alpha1.WorkloadSpec{ + Replicas: ptr.To[int32](4), + Template: &corev1.PodSpec{Containers: []corev1.Container{{Name: "kserve-container", Image: "prefill:0.1"}}}, + }, + }, + }, + want: v1alpha1.LLMInferenceServiceSpec{ + // Base workload spec is preserved + WorkloadSpec: v1alpha1.WorkloadSpec{ + Replicas: ptr.To[int32](1), + Template: &corev1.PodSpec{Containers: []corev1.Container{{Name: "kserve-container", Image: "decode:0.1"}}}, + }, + // Prefill spec is added + Prefill: &v1alpha1.WorkloadSpec{ + Replicas: ptr.To[int32](4), + Template: &corev1.PodSpec{Containers: []corev1.Container{{Name: "kserve-container", Image: "prefill:0.1"}}}, + }, + }, + }, + { + name: "merge with worker spec", + cfgs: []v1alpha1.LLMInferenceServiceSpec{ + // Base has the main head/decode template + { + WorkloadSpec: v1alpha1.WorkloadSpec{ + Template: &corev1.PodSpec{Containers: []corev1.Container{{Name: "kserve-container", Image: "head:0.1"}}}, + }, + }, + // Override adds a worker spec + { + WorkloadSpec: v1alpha1.WorkloadSpec{ + Worker: &corev1.PodSpec{Containers: []corev1.Container{{Name: "kserve-container", Image: "worker:0.1"}}}, + }, + }, + }, + want: v1alpha1.LLMInferenceServiceSpec{ + WorkloadSpec: v1alpha1.WorkloadSpec{ + // Head template is preserved + Template: &corev1.PodSpec{Containers: []corev1.Container{{Name: "kserve-container", Image: "head:0.1"}}}, + // Worker spec is added + Worker: &corev1.PodSpec{Containers: []corev1.Container{{Name: "kserve-container", Image: "worker:0.1"}}}, + }, + }, + }, + { + name: "merge with parallelism spec", + cfgs: []v1alpha1.LLMInferenceServiceSpec{ + // Base defines tensor parallelism + { + WorkloadSpec: v1alpha1.WorkloadSpec{ + Parallelism: &v1alpha1.ParallelismSpec{ + Tensor: ptr.To[int64](2), + }, + }, + }, + // Override defines pipeline parallelism + { + WorkloadSpec: v1alpha1.WorkloadSpec{ + Parallelism: &v1alpha1.ParallelismSpec{ + Pipeline: ptr.To[int64](4), + }, + }, + }, + }, + want: v1alpha1.LLMInferenceServiceSpec{ + WorkloadSpec: v1alpha1.WorkloadSpec{ + // Both parallelism values should be present + Parallelism: &v1alpha1.ParallelismSpec{ + Tensor: ptr.To[int64](2), + Pipeline: ptr.To[int64](4), + }, + }, + }, + }, + { + name: "deep merge of prefill spec", + cfgs: []v1alpha1.LLMInferenceServiceSpec{ + // Base defines a prefill workload with replicas and a container with a resource request + { + Prefill: &v1alpha1.WorkloadSpec{ + Replicas: ptr.To[int32](2), + Template: &corev1.PodSpec{ + Containers: []corev1.Container{ + { + Name: "prefill-container", + Image: "prefill:0.1", + Resources: corev1.ResourceRequirements{ + Requests: corev1.ResourceList{corev1.ResourceCPU: resource.MustParse("1")}, + }, + }, + }, + }, + }, + }, + // Override changes replica count and adds an environment variable to the container + { + Prefill: &v1alpha1.WorkloadSpec{ + Replicas: ptr.To[int32](4), + Template: &corev1.PodSpec{ + Containers: []corev1.Container{ + { + Name: "prefill-container", + Env: []corev1.EnvVar{ + {Name: "PREFILL_MODE", Value: "FAST"}, + }, + }, + }, + }, + }, + }, + }, + want: v1alpha1.LLMInferenceServiceSpec{ + Prefill: &v1alpha1.WorkloadSpec{ + Replicas: ptr.To[int32](4), // Replicas are overridden + Template: &corev1.PodSpec{ + Containers: []corev1.Container{ + { + Name: "prefill-container", + Image: "prefill:0.1", // Image is preserved from base + Env: []corev1.EnvVar{ // Env var is added from override + {Name: "PREFILL_MODE", Value: "FAST"}, + }, + Resources: corev1.ResourceRequirements{ // Resources are preserved from base + Requests: corev1.ResourceList{corev1.ResourceCPU: resource.MustParse("1")}, + }, + }, + }, + }, + }, + }, + }, + { + name: "4 chained merge router, epp, multi node", + cfgs: []v1alpha1.LLMInferenceServiceSpec{ + { + Router: &v1alpha1.RouterSpec{ + Route: &v1alpha1.GatewayRoutesSpec{}, + Gateway: &v1alpha1.GatewaySpec{}, + }, + }, + { + WorkloadSpec: v1alpha1.WorkloadSpec{ + Parallelism: &v1alpha1.ParallelismSpec{ + Tensor: ptr.To[int64](1), + Pipeline: ptr.To[int64](1), + }, + Worker: &corev1.PodSpec{ + Containers: []corev1.Container{ + { + Name: "main", + Resources: corev1.ResourceRequirements{ + Requests: corev1.ResourceList{ + corev1.ResourceCPU: resource.MustParse("1"), + "nvidia.com/gpu": resource.MustParse("1"), + }, + }, + }, + }, + }, + }, + }, + { + Router: &v1alpha1.RouterSpec{ + Scheduler: &v1alpha1.SchedulerSpec{ + Pool: &v1alpha1.InferencePoolSpec{ + Spec: &igwapi.InferencePoolSpec{ + TargetPortNumber: 0, + EndpointPickerConfig: igwapi.EndpointPickerConfig{ + ExtensionRef: &igwapi.Extension{ + ExtensionConnection: igwapi.ExtensionConnection{ + FailureMode: ptr.To(igwapi.FailClose), + }, + }, + }, + }, + }, + Template: &corev1.PodSpec{ + Containers: []corev1.Container{ + { + Name: "main", + }, + }, + }, + }, + }, + }, + { + WorkloadSpec: v1alpha1.WorkloadSpec{ + Parallelism: &v1alpha1.ParallelismSpec{ + Tensor: ptr.To[int64](4), + Pipeline: ptr.To[int64](2), + }, + Worker: &corev1.PodSpec{ + Containers: []corev1.Container{ + { + Name: "main", + Resources: corev1.ResourceRequirements{ + Requests: corev1.ResourceList{ + corev1.ResourceCPU: resource.MustParse("1"), + "nvidia.com/gpu": resource.MustParse("4"), + }, + }, + }, + }, + }, + }, + }, + }, + want: v1alpha1.LLMInferenceServiceSpec{ + Router: &v1alpha1.RouterSpec{ + Route: &v1alpha1.GatewayRoutesSpec{}, + Gateway: &v1alpha1.GatewaySpec{}, + Scheduler: &v1alpha1.SchedulerSpec{ + Pool: &v1alpha1.InferencePoolSpec{ + Spec: &igwapi.InferencePoolSpec{ + TargetPortNumber: 0, + EndpointPickerConfig: igwapi.EndpointPickerConfig{ + ExtensionRef: &igwapi.Extension{ + ExtensionConnection: igwapi.ExtensionConnection{ + FailureMode: ptr.To(igwapi.FailClose), + }, + }, + }, + }, + }, + Template: &corev1.PodSpec{ + Containers: []corev1.Container{ + { + Name: "main", + }, + }, + }, + }, + }, + WorkloadSpec: v1alpha1.WorkloadSpec{ + Parallelism: &v1alpha1.ParallelismSpec{ + Tensor: ptr.To[int64](4), + Pipeline: ptr.To[int64](2), + }, + Worker: &corev1.PodSpec{ + Containers: []corev1.Container{ + { + Name: "main", + Resources: corev1.ResourceRequirements{ + Requests: corev1.ResourceList{ + corev1.ResourceCPU: resource.MustParse("1"), + "nvidia.com/gpu": resource.MustParse("4"), + }, + }, + }, + }, + }, + }, + }, + }, + { + name: "4 chained merge router with scheduler, http route and gateway ref, multi node", + cfgs: []v1alpha1.LLMInferenceServiceSpec{ + { + Router: &v1alpha1.RouterSpec{ + Route: &v1alpha1.GatewayRoutesSpec{ + HTTP: &v1alpha1.HTTPRouteSpec{ + Spec: &gwapiv1.HTTPRouteSpec{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ + { + Name: "my-parent", + }, + }, + }, + Hostnames: nil, + Rules: nil, + }, + Refs: []corev1.LocalObjectReference{{Name: "my-route"}}, + }, + }, + Gateway: &v1alpha1.GatewaySpec{ + Refs: []v1alpha1.UntypedObjectReference{{Name: "my-gateway"}}, + }, + }, + }, + { + Router: &v1alpha1.RouterSpec{ + Route: &v1alpha1.GatewayRoutesSpec{ + HTTP: &v1alpha1.HTTPRouteSpec{ + Refs: []corev1.LocalObjectReference{{Name: "my-second-route"}}, + }, + }, + Gateway: &v1alpha1.GatewaySpec{ + Refs: []v1alpha1.UntypedObjectReference{{Name: "my-second-gateway"}}, + }, + }, + }, + { + WorkloadSpec: v1alpha1.WorkloadSpec{ + Parallelism: &v1alpha1.ParallelismSpec{ + Tensor: ptr.To[int64](1), + Pipeline: ptr.To[int64](1), + }, + Worker: &corev1.PodSpec{ + Containers: []corev1.Container{ + { + Name: "main", + Resources: corev1.ResourceRequirements{ + Requests: corev1.ResourceList{ + corev1.ResourceCPU: resource.MustParse("1"), + "nvidia.com/gpu": resource.MustParse("1"), + }, + }, + }, + }, + }, + }, + }, + { + Router: &v1alpha1.RouterSpec{ + Scheduler: &v1alpha1.SchedulerSpec{ + Pool: &v1alpha1.InferencePoolSpec{ + Ref: &corev1.LocalObjectReference{ + Name: "my-pool", + }, + }, + }, + }, + }, + { + WorkloadSpec: v1alpha1.WorkloadSpec{ + Parallelism: &v1alpha1.ParallelismSpec{ + Tensor: ptr.To[int64](4), + Pipeline: ptr.To[int64](2), + }, + Worker: &corev1.PodSpec{ + Containers: []corev1.Container{ + { + Name: "main", + Resources: corev1.ResourceRequirements{ + Requests: corev1.ResourceList{ + corev1.ResourceCPU: resource.MustParse("1"), + "nvidia.com/gpu": resource.MustParse("4"), + }, + }, + }, + }, + }, + }, + }, + }, + want: v1alpha1.LLMInferenceServiceSpec{ + Router: &v1alpha1.RouterSpec{ + Route: &v1alpha1.GatewayRoutesSpec{ + HTTP: &v1alpha1.HTTPRouteSpec{ + Spec: &gwapiv1.HTTPRouteSpec{ + CommonRouteSpec: gwapiv1.CommonRouteSpec{ + ParentRefs: []gwapiv1.ParentReference{ + { + Name: "my-parent", + }, + }, + }, + Hostnames: nil, + Rules: nil, + }, + Refs: []corev1.LocalObjectReference{{Name: "my-second-route"}}, + }, + }, + Gateway: &v1alpha1.GatewaySpec{ + Refs: []v1alpha1.UntypedObjectReference{{Name: "my-second-gateway"}}, + }, + Scheduler: &v1alpha1.SchedulerSpec{ + Pool: &v1alpha1.InferencePoolSpec{ + Ref: &corev1.LocalObjectReference{ + Name: "my-pool", + }, + }, + }, + }, + WorkloadSpec: v1alpha1.WorkloadSpec{ + Parallelism: &v1alpha1.ParallelismSpec{ + Tensor: ptr.To[int64](4), + Pipeline: ptr.To[int64](2), + }, + Worker: &corev1.PodSpec{ + Containers: []corev1.Container{ + { + Name: "main", + Resources: corev1.ResourceRequirements{ + Requests: corev1.ResourceList{ + corev1.ResourceCPU: resource.MustParse("1"), + "nvidia.com/gpu": resource.MustParse("4"), + }, + }, + }, + }, + }, + }, + }, + }, + { + name: "merge requests and limits", + cfgs: []v1alpha1.LLMInferenceServiceSpec{ + { + Router: &v1alpha1.RouterSpec{ + Route: &v1alpha1.GatewayRoutesSpec{}, + Gateway: &v1alpha1.GatewaySpec{}, + }, + }, + { + WorkloadSpec: v1alpha1.WorkloadSpec{ + Parallelism: &v1alpha1.ParallelismSpec{ + Tensor: ptr.To[int64](1), + Pipeline: ptr.To[int64](1), + }, + Worker: &corev1.PodSpec{ + Containers: []corev1.Container{ + { + Name: "main", + Resources: corev1.ResourceRequirements{ + Requests: corev1.ResourceList{ + corev1.ResourceCPU: resource.MustParse("1"), + "nvidia.com/gpu": resource.MustParse("1"), + }, + Limits: corev1.ResourceList{ + "nvidia.com/gpu": resource.MustParse("1"), + }, + }, + Env: []corev1.EnvVar{ + {Name: "a", Value: "1"}, + {Name: "z", Value: "42"}, + }, + Args: []string{ + "a", "b", + }, + }, + }, + }, + }, + }, + { + WorkloadSpec: v1alpha1.WorkloadSpec{ + Worker: &corev1.PodSpec{ + Containers: []corev1.Container{ + { + Name: "main", + Resources: corev1.ResourceRequirements{ + Requests: corev1.ResourceList{ + corev1.ResourceMemory: resource.MustParse("1Gi"), + }, + Limits: corev1.ResourceList{ + corev1.ResourceCPU: resource.MustParse("2"), + }, + }, + Env: []corev1.EnvVar{ + {Name: "b", Value: "2"}, + {Name: "z", Value: ""}, + }, + Args: []string{ + "x", "y", + }, + }, + }, + }, + }, + }, + }, + want: v1alpha1.LLMInferenceServiceSpec{ + Router: &v1alpha1.RouterSpec{ + Route: &v1alpha1.GatewayRoutesSpec{}, + Gateway: &v1alpha1.GatewaySpec{}, + }, + WorkloadSpec: v1alpha1.WorkloadSpec{ + Parallelism: &v1alpha1.ParallelismSpec{ + Tensor: ptr.To[int64](1), + Pipeline: ptr.To[int64](1), + }, + Worker: &corev1.PodSpec{ + Containers: []corev1.Container{ + { + Name: "main", + Resources: corev1.ResourceRequirements{ + Requests: corev1.ResourceList{ + corev1.ResourceMemory: resource.MustParse("1Gi"), + corev1.ResourceCPU: resource.MustParse("1"), + "nvidia.com/gpu": resource.MustParse("1"), + }, + Limits: corev1.ResourceList{ + corev1.ResourceCPU: resource.MustParse("2"), + "nvidia.com/gpu": resource.MustParse("1"), + }, + }, + Env: []corev1.EnvVar{ + {Name: "b", Value: "2"}, + {Name: "a", Value: "1"}, + {Name: "z", Value: "42"}, + }, + Args: []string{ + "x", "y", + }, + }, + }, + }, + }, + }, + }, + { + name: "merge LoRA adapters", + cfgs: []v1alpha1.LLMInferenceServiceSpec{ + { + Model: v1alpha1.LLMModelSpec{ + URI: mustParseURL("base-model"), + LoRA: &v1alpha1.LoRASpec{ + Adapters: []v1alpha1.ModelSpec{ + {StorageURI: "s3://bucket/adapter1", Framework: "pytorch", Memory: resource.MustParse("1Gi")}, + }, + }, + }, + }, + { + Model: v1alpha1.LLMModelSpec{ + LoRA: &v1alpha1.LoRASpec{ + Adapters: []v1alpha1.ModelSpec{ + {StorageURI: "s3://bucket/adapter2", Framework: "pytorch", Memory: resource.MustParse("512Mi")}, + }, + }, + }, + }, + }, + want: v1alpha1.LLMInferenceServiceSpec{ + Model: v1alpha1.LLMModelSpec{ + URI: mustParseURL("base-model"), + LoRA: &v1alpha1.LoRASpec{ + Adapters: []v1alpha1.ModelSpec{ + {StorageURI: "s3://bucket/adapter2", Framework: "pytorch", Memory: resource.MustParse("512Mi")}, + }, + }, + }, + }, + }, + { + name: "merge storage spec", + cfgs: []v1alpha1.LLMInferenceServiceSpec{ + { + Model: v1alpha1.LLMModelSpec{ + URI: mustParseURL("model-uri"), + Storage: &v1alpha1.LLMStorageSpec{ + Path: ptr.To("/models/base"), + StorageKey: ptr.To("base-key"), + Parameters: &map[string]string{ + "region": "us-east-1", + "bucket": "my-bucket", + }, + }, + }, + }, + { + Model: v1alpha1.LLMModelSpec{ + Storage: &v1alpha1.LLMStorageSpec{ + Path: ptr.To("/models/override"), + StorageKey: ptr.To("override-key"), + Parameters: &map[string]string{ + "region": "us-west-2", + "encryption": "aes256", + }, + }, + }, + }, + }, + want: v1alpha1.LLMInferenceServiceSpec{ + Model: v1alpha1.LLMModelSpec{ + URI: mustParseURL("model-uri"), + Storage: &v1alpha1.LLMStorageSpec{ + Path: ptr.To("/models/override"), + StorageKey: ptr.To("override-key"), + Parameters: &map[string]string{ + "region": "us-west-2", + "bucket": "my-bucket", + "encryption": "aes256", + }, + }, + }, + }, + }, + { + name: "merge model criticality", + cfgs: []v1alpha1.LLMInferenceServiceSpec{ + { + Model: v1alpha1.LLMModelSpec{ + URI: mustParseURL("model-uri"), + Criticality: ptr.To(igwapi.Sheddable), + }, + }, + { + Model: v1alpha1.LLMModelSpec{ + Criticality: ptr.To(igwapi.Critical), + }, + }, + }, + want: v1alpha1.LLMInferenceServiceSpec{ + Model: v1alpha1.LLMModelSpec{ + URI: mustParseURL("model-uri"), + Criticality: ptr.To(igwapi.Critical), + }, + }, + }, + { + name: "merge model URI", + cfgs: []v1alpha1.LLMInferenceServiceSpec{ + { + Model: v1alpha1.LLMModelSpec{ + URI: apis.URL{Scheme: "hf", Host: "hub.com", Path: "/model-a"}, + }, + }, + { + Model: v1alpha1.LLMModelSpec{ + URI: apis.URL{Scheme: "s3", Host: "bucket.com", Path: "/model-b"}, + }, + }, + }, + want: v1alpha1.LLMInferenceServiceSpec{ + Model: v1alpha1.LLMModelSpec{ + URI: apis.URL{Scheme: "s3", Host: "bucket.com", Path: "/model-b"}, + }, + }, + }, + { + name: "merge baseRefs", + cfgs: []v1alpha1.LLMInferenceServiceSpec{ + { + BaseRefs: []corev1.LocalObjectReference{ + {Name: "base-config-1"}, + {Name: "base-config-2"}, + }, + }, + { + BaseRefs: []corev1.LocalObjectReference{ + {Name: "override-config-1"}, + }, + }, + }, + want: v1alpha1.LLMInferenceServiceSpec{ + BaseRefs: []corev1.LocalObjectReference{ + {Name: "override-config-1"}, + }, + }, + }, + { + name: "merge ingress spec", + cfgs: []v1alpha1.LLMInferenceServiceSpec{ + { + Router: &v1alpha1.RouterSpec{ + Ingress: &v1alpha1.IngressSpec{ + Refs: []v1alpha1.UntypedObjectReference{ + {Name: "base-ingress", Namespace: "base-ns"}, + }, + }, + }, + }, + { + Router: &v1alpha1.RouterSpec{ + Ingress: &v1alpha1.IngressSpec{ + Refs: []v1alpha1.UntypedObjectReference{ + {Name: "override-ingress", Namespace: "override-ns"}, + }, + }, + }, + }, + }, + want: v1alpha1.LLMInferenceServiceSpec{ + Router: &v1alpha1.RouterSpec{ + Ingress: &v1alpha1.IngressSpec{ + Refs: []v1alpha1.UntypedObjectReference{ + {Name: "override-ingress", Namespace: "override-ns"}, + }, + }, + }, + }, + }, + { + name: "merge with nil pointer handling", + cfgs: []v1alpha1.LLMInferenceServiceSpec{ + { + Model: v1alpha1.LLMModelSpec{ + URI: mustParseURL("model-uri"), + Name: ptr.To("base-name"), + }, + WorkloadSpec: v1alpha1.WorkloadSpec{ + Replicas: ptr.To[int32](1), + }, + }, + { + Model: v1alpha1.LLMModelSpec{ + Name: nil, // nil pointer should not override non-nil base + }, + WorkloadSpec: v1alpha1.WorkloadSpec{ + Replicas: ptr.To[int32](3), + }, + }, + }, + want: v1alpha1.LLMInferenceServiceSpec{ + Model: v1alpha1.LLMModelSpec{ + URI: mustParseURL("model-uri"), + Name: ptr.To("base-name"), // Base value should be preserved + }, + WorkloadSpec: v1alpha1.WorkloadSpec{ + Replicas: ptr.To[int32](3), + }, + }, + }, + { + name: "merge complex nested structures", + cfgs: []v1alpha1.LLMInferenceServiceSpec{ + { + Model: v1alpha1.LLMModelSpec{ + URI: mustParseURL("base-model"), + Name: ptr.To("base-name"), + Criticality: ptr.To(igwapi.Sheddable), + LoRA: &v1alpha1.LoRASpec{ + Adapters: []v1alpha1.ModelSpec{ + {StorageURI: "base-adapter", Framework: "pytorch", Memory: resource.MustParse("1Gi")}, + }, + }, + Storage: &v1alpha1.LLMStorageSpec{ + Path: ptr.To("/base/path"), + StorageKey: ptr.To("base-key"), + }, + }, + WorkloadSpec: v1alpha1.WorkloadSpec{ + Replicas: ptr.To[int32](1), + Parallelism: &v1alpha1.ParallelismSpec{ + Tensor: ptr.To[int64](2), + }, + }, + Router: &v1alpha1.RouterSpec{ + Gateway: &v1alpha1.GatewaySpec{ + Refs: []v1alpha1.UntypedObjectReference{{Name: "base-gw"}}, + }, + }, + }, + { + Model: v1alpha1.LLMModelSpec{ + Name: ptr.To("override-name"), + Criticality: ptr.To(igwapi.Critical), + LoRA: &v1alpha1.LoRASpec{ + Adapters: []v1alpha1.ModelSpec{ + {StorageURI: "override-adapter", Framework: "tensorflow", Memory: resource.MustParse("2Gi")}, + }, + }, + Storage: &v1alpha1.LLMStorageSpec{ + Path: ptr.To("/override/path"), + Parameters: &map[string]string{ + "new-param": "new-value", + }, + }, + }, + WorkloadSpec: v1alpha1.WorkloadSpec{ + Replicas: ptr.To[int32](5), + Parallelism: &v1alpha1.ParallelismSpec{ + Pipeline: ptr.To[int64](4), + }, + }, + Router: &v1alpha1.RouterSpec{ + Route: &v1alpha1.GatewayRoutesSpec{ + HTTP: &v1alpha1.HTTPRouteSpec{ + Refs: []corev1.LocalObjectReference{{Name: "override-route"}}, + }, + }, + }, + }, + }, + want: v1alpha1.LLMInferenceServiceSpec{ + Model: v1alpha1.LLMModelSpec{ + URI: mustParseURL("base-model"), // Base URI preserved + Name: ptr.To("override-name"), // Override name + Criticality: ptr.To(igwapi.Critical), + LoRA: &v1alpha1.LoRASpec{ + Adapters: []v1alpha1.ModelSpec{ + {StorageURI: "override-adapter", Framework: "tensorflow", Memory: resource.MustParse("2Gi")}, + }, + }, + Storage: &v1alpha1.LLMStorageSpec{ + Path: ptr.To("/override/path"), + StorageKey: ptr.To("base-key"), // Base key preserved + Parameters: &map[string]string{ + "new-param": "new-value", + }, + }, + }, + WorkloadSpec: v1alpha1.WorkloadSpec{ + Replicas: ptr.To[int32](5), + Parallelism: &v1alpha1.ParallelismSpec{ + Tensor: ptr.To[int64](2), // Base tensor preserved + Pipeline: ptr.To[int64](4), // Override pipeline + }, + }, + Router: &v1alpha1.RouterSpec{ + Gateway: &v1alpha1.GatewaySpec{ + Refs: []v1alpha1.UntypedObjectReference{{Name: "base-gw"}}, + }, + Route: &v1alpha1.GatewayRoutesSpec{ + HTTP: &v1alpha1.HTTPRouteSpec{ + Refs: []corev1.LocalObjectReference{{Name: "override-route"}}, + }, + }, + }, + }, + }, + { + name: "merge empty structures", + cfgs: []v1alpha1.LLMInferenceServiceSpec{ + { + Model: v1alpha1.LLMModelSpec{}, + }, + { + Model: v1alpha1.LLMModelSpec{ + URI: mustParseURL("populated-model"), + }, + }, + }, + want: v1alpha1.LLMInferenceServiceSpec{ + Model: v1alpha1.LLMModelSpec{ + URI: mustParseURL("populated-model"), + }, + }, + }, + { + name: "merge with zero values vs nil pointers", + cfgs: []v1alpha1.LLMInferenceServiceSpec{ + { + WorkloadSpec: v1alpha1.WorkloadSpec{ + Replicas: ptr.To[int32](0), // Zero value, but non-nil pointer + }, + }, + { + WorkloadSpec: v1alpha1.WorkloadSpec{ + Replicas: nil, // Nil pointer should not override zero value + }, + }, + }, + want: v1alpha1.LLMInferenceServiceSpec{ + WorkloadSpec: v1alpha1.WorkloadSpec{ + Replicas: ptr.To[int32](0), // Zero value should be preserved + }, + }, + }, + } + for _, tt := range tests { + t.Run(tt.name, func(t *testing.T) { + got, err := llmisvc.MergeSpecs(tt.cfgs...) + if (err != nil) != tt.wantErr { + t.Errorf("MergeSpecs() error = %v, wantErr %v", err, tt.wantErr) + return + } + if diff := cmp.Diff(tt.want, got); diff != "" { + t.Errorf("MergeSpecs() got = \n%#v\n, want \n%#v\nDiff (-want, +got):\n%s", got, tt.want, diff) + } + }) + } +} + +func TestReplaceVariables(t *testing.T) { + tests := []struct { + name string + llmSvc *v1alpha1.LLMInferenceService + cfg *v1alpha1.LLMInferenceServiceConfig + extra *llmisvc.Config + want *v1alpha1.LLMInferenceServiceConfig + wantErr bool + }{ + { + name: "Replace model name", + cfg: &v1alpha1.LLMInferenceServiceConfig{ + Spec: v1alpha1.LLMInferenceServiceSpec{ + Model: v1alpha1.LLMModelSpec{ + Name: ptr.To("{{ .Spec.Model.Name }}"), + }, + WorkloadSpec: v1alpha1.WorkloadSpec{ + Template: &corev1.PodSpec{ + Containers: []corev1.Container{ + {Args: []string{ + "--served-model-name", + "{{ .Spec.Model.Name }}", + }}, + }, + }, + }, + }, + }, + llmSvc: &v1alpha1.LLMInferenceService{ + Spec: v1alpha1.LLMInferenceServiceSpec{ + Model: v1alpha1.LLMModelSpec{ + Name: ptr.To("meta-llama/Llama-3.2-3B-Instruct"), + }, + }, + }, + want: &v1alpha1.LLMInferenceServiceConfig{ + Spec: v1alpha1.LLMInferenceServiceSpec{ + Model: v1alpha1.LLMModelSpec{ + Name: ptr.To("meta-llama/Llama-3.2-3B-Instruct"), + }, + WorkloadSpec: v1alpha1.WorkloadSpec{ + Template: &corev1.PodSpec{ + Containers: []corev1.Container{ + {Args: []string{ + "--served-model-name", + "meta-llama/Llama-3.2-3B-Instruct", + }}, + }, + }, + }, + }, + }, + }, + { + name: "template with ChildName function", + cfg: &v1alpha1.LLMInferenceServiceConfig{ + Spec: v1alpha1.LLMInferenceServiceSpec{ + WorkloadSpec: v1alpha1.WorkloadSpec{ + Template: &corev1.PodSpec{ + ServiceAccountName: "{{ ChildName .Name `-sa` }}", + Containers: []corev1.Container{ + { + Name: "main", + Env: []corev1.EnvVar{ + {Name: "DEPLOYMENT_NAME", Value: "{{ ChildName .Name `-deployment` }}"}, + }, + }, + }, + }, + }, + }, + }, + llmSvc: &v1alpha1.LLMInferenceService{ + ObjectMeta: metav1.ObjectMeta{ + Name: "test-llm", + Namespace: "test-ns", + }, + }, + want: &v1alpha1.LLMInferenceServiceConfig{ + Spec: v1alpha1.LLMInferenceServiceSpec{ + WorkloadSpec: v1alpha1.WorkloadSpec{ + Template: &corev1.PodSpec{ + ServiceAccountName: "test-llm-sa", + Containers: []corev1.Container{ + { + Name: "main", + Env: []corev1.EnvVar{ + {Name: "DEPLOYMENT_NAME", Value: "test-llm-deployment"}, + }, + }, + }, + }, + }, + }, + }, + }, + { + name: "template in model storage parameters", + cfg: &v1alpha1.LLMInferenceServiceConfig{ + Spec: v1alpha1.LLMInferenceServiceSpec{ + Model: v1alpha1.LLMModelSpec{ + URI: mustParseURL("s3://ai-team/models/llama-model"), + Storage: &v1alpha1.LLMStorageSpec{ + Path: ptr.To("/models/{{ .Name }}"), + Parameters: &map[string]string{ + "bucket": "{{ .Namespace }}-models", + "model-id": "{{ .Name }}", + "full-path": "{{ .Namespace }}/{{ .Name }}", + }, + }, + }, + }, + }, + llmSvc: &v1alpha1.LLMInferenceService{ + ObjectMeta: metav1.ObjectMeta{ + Name: "llama-model", + Namespace: "ai-team", + }, + }, + want: &v1alpha1.LLMInferenceServiceConfig{ + Spec: v1alpha1.LLMInferenceServiceSpec{ + Model: v1alpha1.LLMModelSpec{ + URI: mustParseURL("s3://ai-team/models/llama-model"), + Storage: &v1alpha1.LLMStorageSpec{ + Path: ptr.To("/models/llama-model"), + Parameters: &map[string]string{ + "bucket": "ai-team-models", + "model-id": "llama-model", + "full-path": "ai-team/llama-model", + }, + }, + }, + }, + }, + }, + { + name: "template in arrays", + cfg: &v1alpha1.LLMInferenceServiceConfig{ + Spec: v1alpha1.LLMInferenceServiceSpec{ + WorkloadSpec: v1alpha1.WorkloadSpec{ + Template: &corev1.PodSpec{ + Containers: []corev1.Container{ + { + Name: "main", + Args: []string{ + "--model-name={{ .Name }}", + "--namespace={{ .Namespace }}", + "--config-path=/config/{{ .Name }}.yaml", + }, + Env: []corev1.EnvVar{ + {Name: "MODEL_NAME", Value: "{{ .Name }}"}, + {Name: "NAMESPACE", Value: "{{ .Namespace }}"}, + }, + }, + }, + }, + }, + }, + }, + llmSvc: &v1alpha1.LLMInferenceService{ + ObjectMeta: metav1.ObjectMeta{ + Name: "gpt-model", + Namespace: "ml-team", + }, + }, + want: &v1alpha1.LLMInferenceServiceConfig{ + Spec: v1alpha1.LLMInferenceServiceSpec{ + WorkloadSpec: v1alpha1.WorkloadSpec{ + Template: &corev1.PodSpec{ + Containers: []corev1.Container{ + { + Name: "main", + Args: []string{ + "--model-name=gpt-model", + "--namespace=ml-team", + "--config-path=/config/gpt-model.yaml", + }, + Env: []corev1.EnvVar{ + {Name: "MODEL_NAME", Value: "gpt-model"}, + {Name: "NAMESPACE", Value: "ml-team"}, + }, + }, + }, + }, + }, + }, + }, + }, + { + name: "template with complex nested model spec", + cfg: &v1alpha1.LLMInferenceServiceConfig{ + Spec: v1alpha1.LLMInferenceServiceSpec{ + Model: v1alpha1.LLMModelSpec{ + Name: ptr.To("{{ .Spec.Model.Name }}"), + }, + WorkloadSpec: v1alpha1.WorkloadSpec{ + Template: &corev1.PodSpec{ + Containers: []corev1.Container{ + { + Name: "main", + Args: []string{ + "--served-model-name={{ .Spec.Model.Name }}", + "--model-path={{ .Spec.Model.URI.Host }}{{ .Spec.Model.URI.Path }}", + }, + }, + }, + }, + }, + }, + }, + llmSvc: &v1alpha1.LLMInferenceService{ + Spec: v1alpha1.LLMInferenceServiceSpec{ + Model: v1alpha1.LLMModelSpec{ + Name: ptr.To("meta-llama/Llama-3.2-3B-Instruct"), + URI: mustParseURL("hf://meta-llama/Llama-3.2-3B-Instruct"), + }, + }, + }, + want: &v1alpha1.LLMInferenceServiceConfig{ + Spec: v1alpha1.LLMInferenceServiceSpec{ + Model: v1alpha1.LLMModelSpec{ + Name: ptr.To("meta-llama/Llama-3.2-3B-Instruct"), + }, + WorkloadSpec: v1alpha1.WorkloadSpec{ + Template: &corev1.PodSpec{ + Containers: []corev1.Container{ + { + Name: "main", + Args: []string{ + "--served-model-name=meta-llama/Llama-3.2-3B-Instruct", + "--model-path=meta-llama/Llama-3.2-3B-Instruct", + }, + }, + }, + }, + }, + }, + }, + }, + { + name: "template with nil pointer access should not error if default value is provided", + cfg: &v1alpha1.LLMInferenceServiceConfig{ + Spec: v1alpha1.LLMInferenceServiceSpec{ + Model: v1alpha1.LLMModelSpec{ + Name: ptr.To(`{{ if .Spec.Model.Name }}{{ .Spec.Model.Name }}{{ else }}default-model{{ end }}`), + }, + }, + }, + llmSvc: &v1alpha1.LLMInferenceService{ + Spec: v1alpha1.LLMInferenceServiceSpec{ + Model: v1alpha1.LLMModelSpec{ + Name: nil, // Nil pointer + }, + }, + }, + want: &v1alpha1.LLMInferenceServiceConfig{ + Spec: v1alpha1.LLMInferenceServiceSpec{ + Model: v1alpha1.LLMModelSpec{ + Name: ptr.To("default-model"), + }, + }, + }, + }, + { + name: "template with router configurations", + cfg: &v1alpha1.LLMInferenceServiceConfig{ + Spec: v1alpha1.LLMInferenceServiceSpec{ + Router: &v1alpha1.RouterSpec{ + Route: &v1alpha1.GatewayRoutesSpec{ + HTTP: &v1alpha1.HTTPRouteSpec{ + Refs: []corev1.LocalObjectReference{ + {Name: "{{ .Name }}-route"}, + }, + }, + }, + Gateway: &v1alpha1.GatewaySpec{ + Refs: []v1alpha1.UntypedObjectReference{ + {Name: "{{ .Name }}-gateway", Namespace: "{{ .Namespace }}"}, + }, + }, + }, + }, + }, + llmSvc: &v1alpha1.LLMInferenceService{ + ObjectMeta: metav1.ObjectMeta{ + Name: "router-test", + Namespace: "routing-ns", + }, + }, + want: &v1alpha1.LLMInferenceServiceConfig{ + Spec: v1alpha1.LLMInferenceServiceSpec{ + Router: &v1alpha1.RouterSpec{ + Route: &v1alpha1.GatewayRoutesSpec{ + HTTP: &v1alpha1.HTTPRouteSpec{ + Refs: []corev1.LocalObjectReference{ + {Name: "router-test-route"}, + }, + }, + }, + Gateway: &v1alpha1.GatewaySpec{ + Refs: []v1alpha1.UntypedObjectReference{ + {Name: "router-test-gateway", Namespace: "routing-ns"}, + }, + }, + }, + }, + }, + }, + { + name: "template with multiple variables in single string", + cfg: &v1alpha1.LLMInferenceServiceConfig{ + Spec: v1alpha1.LLMInferenceServiceSpec{ + WorkloadSpec: v1alpha1.WorkloadSpec{ + Template: &corev1.PodSpec{ + Containers: []corev1.Container{ + { + Name: "main", + Env: []corev1.EnvVar{ + {Name: "FULL_NAME", Value: "{{ .Namespace }}/{{ .Name }}"}, + {Name: "CONFIG_PATH", Value: "/config/{{ .Namespace }}-{{ .Name }}.yaml"}, + }, + }, + }, + }, + }, + }, + }, + llmSvc: &v1alpha1.LLMInferenceService{ + ObjectMeta: metav1.ObjectMeta{ + Name: "multi-var", + Namespace: "test-ns", + }, + }, + want: &v1alpha1.LLMInferenceServiceConfig{ + Spec: v1alpha1.LLMInferenceServiceSpec{ + WorkloadSpec: v1alpha1.WorkloadSpec{ + Template: &corev1.PodSpec{ + Containers: []corev1.Container{ + { + Name: "main", + Env: []corev1.EnvVar{ + {Name: "FULL_NAME", Value: "test-ns/multi-var"}, + {Name: "CONFIG_PATH", Value: "/config/test-ns-multi-var.yaml"}, + }, + }, + }, + }, + }, + }, + }, + }, + { + name: "template with invalid syntax should error", + cfg: &v1alpha1.LLMInferenceServiceConfig{ + Spec: v1alpha1.LLMInferenceServiceSpec{ + Model: v1alpha1.LLMModelSpec{ + Name: ptr.To("{{ .Name"), // Invalid template syntax - missing closing brace + }, + }, + }, + llmSvc: &v1alpha1.LLMInferenceService{ + ObjectMeta: metav1.ObjectMeta{Name: "test"}, + }, + wantErr: true, + }, + { + name: "template with non-existent field should error", + cfg: &v1alpha1.LLMInferenceServiceConfig{ + Spec: v1alpha1.LLMInferenceServiceSpec{ + Model: v1alpha1.LLMModelSpec{ + Name: ptr.To("{{ .NonExistentField }}"), + }, + }, + }, + llmSvc: &v1alpha1.LLMInferenceService{ + ObjectMeta: metav1.ObjectMeta{Name: "test"}, + }, + wantErr: true, + }, + { + name: "template in baseRefs", + cfg: &v1alpha1.LLMInferenceServiceConfig{ + Spec: v1alpha1.LLMInferenceServiceSpec{ + BaseRefs: []corev1.LocalObjectReference{ + {Name: "{{ .Name }}-base-config"}, + {Name: "{{ .Namespace }}-shared-config"}, + }, + }, + }, + llmSvc: &v1alpha1.LLMInferenceService{ + ObjectMeta: metav1.ObjectMeta{ + Name: "base-ref-test", + Namespace: "template-ns", + }, + }, + want: &v1alpha1.LLMInferenceServiceConfig{ + Spec: v1alpha1.LLMInferenceServiceSpec{ + BaseRefs: []corev1.LocalObjectReference{ + {Name: "base-ref-test-base-config"}, + {Name: "template-ns-shared-config"}, + }, + }, + }, + }, + } + for _, tt := range tests { + t.Run(tt.name, func(t *testing.T) { + got, err := llmisvc.ReplaceVariables(tt.llmSvc, tt.cfg, tt.extra) + if (err != nil) != tt.wantErr { + t.Errorf("ReplaceVariables() error = %v, wantErr %v", err, tt.wantErr) + return + } + if !tt.wantErr { + if diff := cmp.Diff(tt.want, got); diff != "" { + t.Errorf("ReplaceVariables() got = %#v, want %#v\nDiff:\n%s", got, tt.want, diff) + } + } + }) + } +} + +func mustParseURL(s string) apis.URL { + u, err := apis.ParseURL(s) + if err != nil { + panic(err) + } + return *u +} diff --git a/pkg/controller/v1alpha1/llmisvc/controller_types.go b/pkg/controller/v1alpha1/llmisvc/controller_types.go new file mode 100644 index 00000000000..241cff7a69e --- /dev/null +++ b/pkg/controller/v1alpha1/llmisvc/controller_types.go @@ -0,0 +1,23 @@ +/* +Copyright 2025 The KServe Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package llmisvc + +type Config struct { + SystemNamespace string `json:"systemNamespace,omitempty"` + IngressGatewayName string `json:"ingressGatewayName,omitempty"` + IngressGatewayNamespace string `json:"ingressGatewayNamespace,omitempty"` +} From 16ff23d9ac31165b32093ce6b79b8bdf5baeba66 Mon Sep 17 00:00:00 2001 From: Fabien Dupont Date: Fri, 4 Jul 2025 12:45:33 +0200 Subject: [PATCH 7/9] fix: Allow CA bundle path without config map (#4451) Signed-off-by: Fabien Dupont --- python/kserve/kserve/storage/storage.py | 29 ++- .../kserve/storage/test/test_s3_storage.py | 228 ++++++++++++++++++ .../storage/kserve_storage/kserve_storage.py | 4 +- python/storage/test/test_s3_storage.py | 228 ++++++++++++++++++ 4 files changed, 476 insertions(+), 13 deletions(-) diff --git a/python/kserve/kserve/storage/storage.py b/python/kserve/kserve/storage/storage.py index 1b56a334616..d75f937cc37 100644 --- a/python/kserve/kserve/storage/storage.py +++ b/python/kserve/kserve/storage/storage.py @@ -211,19 +211,26 @@ def _download_s3(uri, temp_dir: str) -> str: verify_ssl = True # If verify_ssl is true, then check there is custom ca bundle cert + # The CA bundle can be any local file in the container under the path + # set in the AWS_CA_BUNDLE environment variable. + # It can also be coming from a ConfigMap, in which case the filename + # is cabundle.crt. if verify_ssl: global_ca_bundle_configmap = os.getenv("CA_BUNDLE_CONFIGMAP_NAME") - if global_ca_bundle_configmap: - isvc_aws_ca_bundle_path = os.getenv("AWS_CA_BUNDLE") - if isvc_aws_ca_bundle_path and isvc_aws_ca_bundle_path != "": - ca_bundle_full_path = isvc_aws_ca_bundle_path - else: - global_ca_bundle_volume_mount_path = os.getenv( - "CA_BUNDLE_VOLUME_MOUNT_POINT" - ) - ca_bundle_full_path = ( - global_ca_bundle_volume_mount_path + "/cabundle.crt" - ) + isvc_aws_ca_bundle_path = os.getenv("AWS_CA_BUNDLE") + ca_bundle_set = False + if isvc_aws_ca_bundle_path and isvc_aws_ca_bundle_path != "": + ca_bundle_set = True + ca_bundle_full_path = isvc_aws_ca_bundle_path + elif global_ca_bundle_configmap: + ca_bundle_set = True + global_ca_bundle_volume_mount_path = os.getenv( + "CA_BUNDLE_VOLUME_MOUNT_POINT" + ) + ca_bundle_full_path = os.path.join( + global_ca_bundle_volume_mount_path, "cabundle.crt" + ) + if ca_bundle_set: if os.path.exists(ca_bundle_full_path): logger.info("ca bundle file(%s) exists." % (ca_bundle_full_path)) kwargs.update({"verify": ca_bundle_full_path}) diff --git a/python/kserve/kserve/storage/test/test_s3_storage.py b/python/kserve/kserve/storage/test/test_s3_storage.py index 95f0d3843bc..90a7a40c07c 100644 --- a/python/kserve/kserve/storage/test/test_s3_storage.py +++ b/python/kserve/kserve/storage/test/test_s3_storage.py @@ -16,6 +16,7 @@ import json import pytest import botocore +import tempfile import unittest.mock as mock from botocore.client import Config @@ -377,3 +378,230 @@ def test_target_download_path_and_name(mock_storage): assert arg_list[1] == expected_call_args_list("model", "dest_path", paths)[1] mock_boto3_bucket.objects.filter.assert_called_with(Prefix="model") + + +@mock.patch("boto3.resource") +def test_ca_bundle_with_aws_ca_bundle_only(mock_storage): + """Test that AWS_CA_BUNDLE can be used independently without CA_BUNDLE_CONFIGMAP_NAME""" + bucket_name = "foo" + object_key = "model.pkl" + + # Create a temporary CA bundle file + with tempfile.NamedTemporaryFile( + mode="w", delete=False, suffix=".crt" + ) as temp_ca_file: + temp_ca_file.write( + "-----BEGIN CERTIFICATE-----\ntest\n-----END CERTIFICATE-----" + ) + ca_bundle_path = temp_ca_file.name + + try: + # Mock the boto3 resource and bucket + create_mock_boto3_bucket(mock_storage, [object_key]) + + # Set only AWS_CA_BUNDLE environment variable (no CA_BUNDLE_CONFIGMAP_NAME) + with mock.patch.dict( + os.environ, + {"AWS_CA_BUNDLE": ca_bundle_path, "S3_VERIFY_SSL": "true"}, + clear=True, + ): + Storage._download_s3(f"s3://{bucket_name}/{object_key}", "dest_path") + + # Verify that boto3.resource was called with the correct verify parameter + mock_storage.assert_called_once() + call_args = mock_storage.call_args + assert call_args[1]["verify"] == ca_bundle_path + + finally: + # Clean up the temporary file + os.unlink(ca_bundle_path) + + +@mock.patch("boto3.resource") +def test_ca_bundle_with_configmap_only(mock_storage): + """Test that CA bundle works with ConfigMap when AWS_CA_BUNDLE is not set""" + bucket_name = "foo" + object_key = "model.pkl" + + # Create a temporary CA bundle file in the expected ConfigMap location + with tempfile.TemporaryDirectory() as temp_dir: + ca_bundle_path = os.path.join(temp_dir, "cabundle.crt") + with open(ca_bundle_path, "w") as f: + f.write("-----BEGIN CERTIFICATE-----\ntest\n-----END CERTIFICATE-----") + + # Mock the boto3 resource and bucket + create_mock_boto3_bucket(mock_storage, [object_key]) + + # Set ConfigMap environment variables only + with mock.patch.dict( + os.environ, + { + "CA_BUNDLE_CONFIGMAP_NAME": "test-configmap", + "CA_BUNDLE_VOLUME_MOUNT_POINT": temp_dir, + "S3_VERIFY_SSL": "true", + }, + clear=True, + ): + Storage._download_s3(f"s3://{bucket_name}/{object_key}", "dest_path") + + # Verify that boto3.resource was called with the correct verify parameter + mock_storage.assert_called_once() + call_args = mock_storage.call_args + assert call_args[1]["verify"] == ca_bundle_path + + +@mock.patch("boto3.resource") +def test_ca_bundle_aws_ca_bundle_takes_precedence(mock_storage): + """Test that AWS_CA_BUNDLE takes precedence over ConfigMap when both are set""" + bucket_name = "foo" + object_key = "model.pkl" + + # Create temporary CA bundle files + with tempfile.NamedTemporaryFile( + mode="w", delete=False, suffix=".crt" + ) as aws_ca_file: + aws_ca_file.write( + "-----BEGIN CERTIFICATE-----\naws_ca\n-----END CERTIFICATE-----" + ) + aws_ca_bundle_path = aws_ca_file.name + + with tempfile.TemporaryDirectory() as temp_dir: + configmap_ca_bundle_path = os.path.join(temp_dir, "cabundle.crt") + with open(configmap_ca_bundle_path, "w") as f: + f.write( + "-----BEGIN CERTIFICATE-----\nconfigmap_ca\n-----END CERTIFICATE-----" + ) + + try: + # Mock the boto3 resource and bucket + create_mock_boto3_bucket(mock_storage, [object_key]) + + # Set both AWS_CA_BUNDLE and ConfigMap environment variables + with mock.patch.dict( + os.environ, + { + "AWS_CA_BUNDLE": aws_ca_bundle_path, + "CA_BUNDLE_CONFIGMAP_NAME": "test-configmap", + "CA_BUNDLE_VOLUME_MOUNT_POINT": temp_dir, + "S3_VERIFY_SSL": "true", + }, + clear=True, + ): + Storage._download_s3(f"s3://{bucket_name}/{object_key}", "dest_path") + + # Verify that boto3.resource was called with AWS_CA_BUNDLE path (takes precedence) + mock_storage.assert_called_once() + call_args = mock_storage.call_args + assert call_args[1]["verify"] == aws_ca_bundle_path + + finally: + # Clean up the temporary file + os.unlink(aws_ca_bundle_path) + + +@mock.patch("boto3.resource") +def test_ca_bundle_file_not_found_aws_ca_bundle(mock_storage): + """Test that RuntimeError is raised when AWS_CA_BUNDLE file doesn't exist""" + bucket_name = "foo" + object_key = "model.pkl" + non_existent_path = "/tmp/non_existent_ca_bundle.crt" + + # Mock the boto3 resource and bucket + create_mock_boto3_bucket(mock_storage, [object_key]) + + # Set AWS_CA_BUNDLE to a non-existent file + with mock.patch.dict( + os.environ, + {"AWS_CA_BUNDLE": non_existent_path, "S3_VERIFY_SSL": "true"}, + clear=True, + ): + with pytest.raises( + RuntimeError, + match=f"Failed to find ca bundle file\\({non_existent_path}\\)", + ): + Storage._download_s3(f"s3://{bucket_name}/{object_key}", "dest_path") + + +@mock.patch("boto3.resource") +def test_ca_bundle_file_not_found_configmap(mock_storage): + """Test that RuntimeError is raised when ConfigMap CA bundle file doesn't exist""" + bucket_name = "foo" + object_key = "model.pkl" + + # Mock the boto3 resource and bucket + create_mock_boto3_bucket(mock_storage, [object_key]) + + # Set ConfigMap environment variables with non-existent directory + with mock.patch.dict( + os.environ, + { + "CA_BUNDLE_CONFIGMAP_NAME": "test-configmap", + "CA_BUNDLE_VOLUME_MOUNT_POINT": "/tmp/non_existent_dir", + "S3_VERIFY_SSL": "true", + }, + clear=True, + ): + expected_path = "/tmp/non_existent_dir/cabundle.crt" + with pytest.raises( + RuntimeError, match=f"Failed to find ca bundle file\\({expected_path}\\)" + ): + Storage._download_s3(f"s3://{bucket_name}/{object_key}", "dest_path") + + +@mock.patch("boto3.resource") +def test_ca_bundle_verify_ssl_false_no_ca_bundle_check(mock_storage): + """Test that CA bundle is not checked when S3_VERIFY_SSL is false""" + bucket_name = "foo" + object_key = "model.pkl" + non_existent_path = "/tmp/non_existent_ca_bundle.crt" + + # Mock the boto3 resource and bucket + create_mock_boto3_bucket(mock_storage, [object_key]) + + # Set AWS_CA_BUNDLE to a non-existent file but disable SSL verification + with mock.patch.dict( + os.environ, + {"AWS_CA_BUNDLE": non_existent_path, "S3_VERIFY_SSL": "false"}, + clear=True, + ): + # This should not raise an error because verify_ssl is False + Storage._download_s3(f"s3://{bucket_name}/{object_key}", "dest_path") + + # Verify that boto3.resource was called with verify=False + mock_storage.assert_called_once() + call_args = mock_storage.call_args + assert call_args[1]["verify"] is False + + +@mock.patch("boto3.resource") +def test_ca_bundle_empty_aws_ca_bundle_uses_configmap(mock_storage): + """Test that empty AWS_CA_BUNDLE falls back to ConfigMap""" + bucket_name = "foo" + object_key = "model.pkl" + + # Create a temporary CA bundle file in the expected ConfigMap location + with tempfile.TemporaryDirectory() as temp_dir: + ca_bundle_path = os.path.join(temp_dir, "cabundle.crt") + with open(ca_bundle_path, "w") as f: + f.write("-----BEGIN CERTIFICATE-----\ntest\n-----END CERTIFICATE-----") + + # Mock the boto3 resource and bucket + create_mock_boto3_bucket(mock_storage, [object_key]) + + # Set empty AWS_CA_BUNDLE and ConfigMap environment variables + with mock.patch.dict( + os.environ, + { + "AWS_CA_BUNDLE": "", + "CA_BUNDLE_CONFIGMAP_NAME": "test-configmap", + "CA_BUNDLE_VOLUME_MOUNT_POINT": temp_dir, + "S3_VERIFY_SSL": "true", + }, + clear=True, + ): + Storage._download_s3(f"s3://{bucket_name}/{object_key}", "dest_path") + + # Verify that boto3.resource was called with the ConfigMap path + mock_storage.assert_called_once() + call_args = mock_storage.call_args + assert call_args[1]["verify"] == ca_bundle_path diff --git a/python/storage/kserve_storage/kserve_storage.py b/python/storage/kserve_storage/kserve_storage.py index 24567da92fe..2117d0e5ebe 100644 --- a/python/storage/kserve_storage/kserve_storage.py +++ b/python/storage/kserve_storage/kserve_storage.py @@ -221,8 +221,8 @@ def _download_s3(uri, temp_dir: str) -> str: global_ca_bundle_volume_mount_path = os.getenv( "CA_BUNDLE_VOLUME_MOUNT_POINT" ) - ca_bundle_full_path = ( - global_ca_bundle_volume_mount_path + "/cabundle.crt" + ca_bundle_full_path = os.path.join( + global_ca_bundle_volume_mount_path, "cabundle.crt" ) if os.path.exists(ca_bundle_full_path): logger.info("ca bundle file(%s) exists." % (ca_bundle_full_path)) diff --git a/python/storage/test/test_s3_storage.py b/python/storage/test/test_s3_storage.py index 7ef28b32407..6f1c0a0c534 100644 --- a/python/storage/test/test_s3_storage.py +++ b/python/storage/test/test_s3_storage.py @@ -16,6 +16,7 @@ import json import pytest import botocore +import tempfile import unittest.mock as mock from botocore.client import Config @@ -377,3 +378,230 @@ def test_target_download_path_and_name(mock_storage): assert arg_list[1] == expected_call_args_list("model", "dest_path", paths)[1] mock_boto3_bucket.objects.filter.assert_called_with(Prefix="model") + + +@mock.patch("boto3.resource") +def test_ca_bundle_with_aws_ca_bundle_only(mock_storage): + """Test that AWS_CA_BUNDLE can be used independently without CA_BUNDLE_CONFIGMAP_NAME""" + bucket_name = "foo" + object_key = "model.pkl" + + # Create a temporary CA bundle file + with tempfile.NamedTemporaryFile( + mode="w", delete=False, suffix=".crt" + ) as temp_ca_file: + temp_ca_file.write( + "-----BEGIN CERTIFICATE-----\ntest\n-----END CERTIFICATE-----" + ) + ca_bundle_path = temp_ca_file.name + + try: + # Mock the boto3 resource and bucket + create_mock_boto3_bucket(mock_storage, [object_key]) + + # Set only AWS_CA_BUNDLE environment variable (no CA_BUNDLE_CONFIGMAP_NAME) + with mock.patch.dict( + os.environ, + {"AWS_CA_BUNDLE": ca_bundle_path, "S3_VERIFY_SSL": "true"}, + clear=True, + ): + Storage._download_s3(f"s3://{bucket_name}/{object_key}", "dest_path") + + # Verify that boto3.resource was called with the correct verify parameter + mock_storage.assert_called_once() + call_args = mock_storage.call_args + assert call_args[1]["verify"] == ca_bundle_path + + finally: + # Clean up the temporary file + os.unlink(ca_bundle_path) + + +@mock.patch("boto3.resource") +def test_ca_bundle_with_configmap_only(mock_storage): + """Test that CA bundle works with ConfigMap when AWS_CA_BUNDLE is not set""" + bucket_name = "foo" + object_key = "model.pkl" + + # Create a temporary CA bundle file in the expected ConfigMap location + with tempfile.TemporaryDirectory() as temp_dir: + ca_bundle_path = os.path.join(temp_dir, "cabundle.crt") + with open(ca_bundle_path, "w") as f: + f.write("-----BEGIN CERTIFICATE-----\ntest\n-----END CERTIFICATE-----") + + # Mock the boto3 resource and bucket + create_mock_boto3_bucket(mock_storage, [object_key]) + + # Set ConfigMap environment variables only + with mock.patch.dict( + os.environ, + { + "CA_BUNDLE_CONFIGMAP_NAME": "test-configmap", + "CA_BUNDLE_VOLUME_MOUNT_POINT": temp_dir, + "S3_VERIFY_SSL": "true", + }, + clear=True, + ): + Storage._download_s3(f"s3://{bucket_name}/{object_key}", "dest_path") + + # Verify that boto3.resource was called with the correct verify parameter + mock_storage.assert_called_once() + call_args = mock_storage.call_args + assert call_args[1]["verify"] == ca_bundle_path + + +@mock.patch("boto3.resource") +def test_ca_bundle_aws_ca_bundle_takes_precedence(mock_storage): + """Test that AWS_CA_BUNDLE takes precedence over ConfigMap when both are set""" + bucket_name = "foo" + object_key = "model.pkl" + + # Create temporary CA bundle files + with tempfile.NamedTemporaryFile( + mode="w", delete=False, suffix=".crt" + ) as aws_ca_file: + aws_ca_file.write( + "-----BEGIN CERTIFICATE-----\naws_ca\n-----END CERTIFICATE-----" + ) + aws_ca_bundle_path = aws_ca_file.name + + with tempfile.TemporaryDirectory() as temp_dir: + configmap_ca_bundle_path = os.path.join(temp_dir, "cabundle.crt") + with open(configmap_ca_bundle_path, "w") as f: + f.write( + "-----BEGIN CERTIFICATE-----\nconfigmap_ca\n-----END CERTIFICATE-----" + ) + + try: + # Mock the boto3 resource and bucket + create_mock_boto3_bucket(mock_storage, [object_key]) + + # Set both AWS_CA_BUNDLE and ConfigMap environment variables + with mock.patch.dict( + os.environ, + { + "AWS_CA_BUNDLE": aws_ca_bundle_path, + "CA_BUNDLE_CONFIGMAP_NAME": "test-configmap", + "CA_BUNDLE_VOLUME_MOUNT_POINT": temp_dir, + "S3_VERIFY_SSL": "true", + }, + clear=True, + ): + Storage._download_s3(f"s3://{bucket_name}/{object_key}", "dest_path") + + # Verify that boto3.resource was called with AWS_CA_BUNDLE path (takes precedence) + mock_storage.assert_called_once() + call_args = mock_storage.call_args + assert call_args[1]["verify"] == aws_ca_bundle_path + + finally: + # Clean up the temporary file + os.unlink(aws_ca_bundle_path) + + +@mock.patch("boto3.resource") +def test_ca_bundle_file_not_found_aws_ca_bundle(mock_storage): + """Test that RuntimeError is raised when AWS_CA_BUNDLE file doesn't exist""" + bucket_name = "foo" + object_key = "model.pkl" + non_existent_path = "/tmp/non_existent_ca_bundle.crt" + + # Mock the boto3 resource and bucket + create_mock_boto3_bucket(mock_storage, [object_key]) + + # Set AWS_CA_BUNDLE to a non-existent file + with mock.patch.dict( + os.environ, + {"AWS_CA_BUNDLE": non_existent_path, "S3_VERIFY_SSL": "true"}, + clear=True, + ): + with pytest.raises( + RuntimeError, + match=f"Failed to find ca bundle file\\({non_existent_path}\\)", + ): + Storage._download_s3(f"s3://{bucket_name}/{object_key}", "dest_path") + + +@mock.patch("boto3.resource") +def test_ca_bundle_file_not_found_configmap(mock_storage): + """Test that RuntimeError is raised when ConfigMap CA bundle file doesn't exist""" + bucket_name = "foo" + object_key = "model.pkl" + + # Mock the boto3 resource and bucket + create_mock_boto3_bucket(mock_storage, [object_key]) + + # Set ConfigMap environment variables with non-existent directory + with mock.patch.dict( + os.environ, + { + "CA_BUNDLE_CONFIGMAP_NAME": "test-configmap", + "CA_BUNDLE_VOLUME_MOUNT_POINT": "/tmp/non_existent_dir", + "S3_VERIFY_SSL": "true", + }, + clear=True, + ): + expected_path = "/tmp/non_existent_dir/cabundle.crt" + with pytest.raises( + RuntimeError, match=f"Failed to find ca bundle file\\({expected_path}\\)" + ): + Storage._download_s3(f"s3://{bucket_name}/{object_key}", "dest_path") + + +@mock.patch("boto3.resource") +def test_ca_bundle_verify_ssl_false_no_ca_bundle_check(mock_storage): + """Test that CA bundle is not checked when S3_VERIFY_SSL is false""" + bucket_name = "foo" + object_key = "model.pkl" + non_existent_path = "/tmp/non_existent_ca_bundle.crt" + + # Mock the boto3 resource and bucket + create_mock_boto3_bucket(mock_storage, [object_key]) + + # Set AWS_CA_BUNDLE to a non-existent file but disable SSL verification + with mock.patch.dict( + os.environ, + {"AWS_CA_BUNDLE": non_existent_path, "S3_VERIFY_SSL": "false"}, + clear=True, + ): + # This should not raise an error because verify_ssl is False + Storage._download_s3(f"s3://{bucket_name}/{object_key}", "dest_path") + + # Verify that boto3.resource was called with verify=False + mock_storage.assert_called_once() + call_args = mock_storage.call_args + assert call_args[1]["verify"] is False + + +@mock.patch("boto3.resource") +def test_ca_bundle_empty_aws_ca_bundle_uses_configmap(mock_storage): + """Test that empty AWS_CA_BUNDLE falls back to ConfigMap""" + bucket_name = "foo" + object_key = "model.pkl" + + # Create a temporary CA bundle file in the expected ConfigMap location + with tempfile.TemporaryDirectory() as temp_dir: + ca_bundle_path = os.path.join(temp_dir, "cabundle.crt") + with open(ca_bundle_path, "w") as f: + f.write("-----BEGIN CERTIFICATE-----\ntest\n-----END CERTIFICATE-----") + + # Mock the boto3 resource and bucket + create_mock_boto3_bucket(mock_storage, [object_key]) + + # Set empty AWS_CA_BUNDLE and ConfigMap environment variables + with mock.patch.dict( + os.environ, + { + "AWS_CA_BUNDLE": "", + "CA_BUNDLE_CONFIGMAP_NAME": "test-configmap", + "CA_BUNDLE_VOLUME_MOUNT_POINT": temp_dir, + "S3_VERIFY_SSL": "true", + }, + clear=True, + ): + Storage._download_s3(f"s3://{bucket_name}/{object_key}", "dest_path") + + # Verify that boto3.resource was called with the ConfigMap path + mock_storage.assert_called_once() + call_args = mock_storage.call_args + assert call_args[1]["verify"] == ca_bundle_path From 2c26bbaeef466600410713f1ebc106bb667dd834 Mon Sep 17 00:00:00 2001 From: Bartosz Majsak Date: Sat, 5 Jul 2025 18:47:14 +0200 Subject: [PATCH 8/9] docs: fixes invalid openshift subscription (#4572) Signed-off-by: Bartosz Majsak Co-authored-by: Jooho Lee --- docs/openshift/cert-manager/operator.yaml | 1 - 1 file changed, 1 deletion(-) diff --git a/docs/openshift/cert-manager/operator.yaml b/docs/openshift/cert-manager/operator.yaml index 0e559e80872..52e692a97b4 100644 --- a/docs/openshift/cert-manager/operator.yaml +++ b/docs/openshift/cert-manager/operator.yaml @@ -11,7 +11,6 @@ metadata: namespace: cert-manager-operator spec: targetNamespaces: [] - spec: {} --- apiVersion: operators.coreos.com/v1alpha1 kind: Subscription From f0c8d39680e9618da229fd5298235a960523fdd2 Mon Sep 17 00:00:00 2001 From: Andrews Arokiam <87992092+andyi2it@users.noreply.github.com> Date: Sat, 5 Jul 2025 23:14:36 +0530 Subject: [PATCH 9/9] Add Code Coverage change report for PRs (#4487) Signed-off-by: Andrews Arokiam --- .github/workflows/go.yml | 232 ++++++++++++++++++++++++++++++--------- 1 file changed, 181 insertions(+), 51 deletions(-) diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml index c196bd486a7..f27ae54795e 100644 --- a/.github/workflows/go.yml +++ b/.github/workflows/go.yml @@ -1,56 +1,186 @@ -name: Go +name: Go Test on: - push: - branches: [master, release*] - pull_request: - branches: [] - workflow_dispatch: + push: + branches: [master, release*] + pull_request: + branches: [] + workflow_dispatch: concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: true - + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true +permissions: + contents: write + pull-requests: write jobs: - build: - name: Build - runs-on: ubuntu-latest - steps: - - name: Check out code into the Go module directory - uses: actions/checkout@v4 - - - name: Set up Go 1.x - uses: actions/setup-go@v5 - with: - go-version-file: go.mod - id: go - - - name: Get dependencies - run: | - go get -v -t -d ./... - - - name: Test - id: test - run: | - export GOPATH=/home/runner/go - export PATH=$PATH:/usr/local/kubebuilder/bin:/home/runner/go/bin - wget -O $GOPATH/bin/yq https://github.com/mikefarah/yq/releases/download/v4.28.1/yq_linux_amd64 - chmod +x $GOPATH/bin/yq - make test - ./coverage.sh - echo ::set-output name=coverage::$(./coverage.sh | tr -s '\t' | cut -d$'\t' -f 3) - - - name: Print coverage - run: | - echo "Coverage output is ${{ steps.test.outputs.coverage }}" - - - name: Update coverage badge - if: github.ref == 'refs/heads/master' - uses: schneegans/dynamic-badges-action@v1.7.0 - with: - auth: ${{ secrets.GIST_SECRET }} - gistID: 5174bd748ac63a6e4803afea902e9810 - filename: coverage.json - label: coverage - message: ${{ steps.test.outputs.coverage }} - color: green + test: + name: Test + runs-on: ubuntu-latest + steps: + + - name: Check out code into the Go module directory + uses: actions/checkout@v4 + + - name: Set up Go 1.x + uses: actions/setup-go@v5 + with: + go-version-file: go.mod + id: go + + - name: Get dependencies + run: | + go get -v -t -d ./... + + - name: Test + id: test + run: | + export GOPATH=/home/runner/go + export PATH=$PATH:/usr/local/kubebuilder/bin:/home/runner/go/bin + wget -O $GOPATH/bin/yq https://github.com/mikefarah/yq/releases/download/v4.28.1/yq_linux_amd64 + chmod +x $GOPATH/bin/yq + make test + ./coverage.sh + echo ::set-output name=coverage::$(./coverage.sh | tr -s '\t' | cut -d$'\t' -f 3) + + - name: Print coverage + run: | + echo "Coverage output is ${{ steps.test.outputs.coverage }}" + + - name: upload cover profile artifact + uses: actions/upload-artifact@v4 + with: + name: coverage.out + path: coverage.out + if-no-files-found: error + + check-coverage: + needs: test + runs-on: ubuntu-latest + name: Check Coverage + steps: + - name: checkout + uses: actions/checkout@v4 + + - name: Download cover profile artifact + id: download-coverage + uses: actions/download-artifact@v4 + with: + name: coverage.out + + - name: Extract coverage percentage + id: current-coverage + run: | + if [ -f coverage.out ]; then + COVERAGE=$(go tool cover -func=coverage.out | grep total: | awk '{print $3}' | sed 's/%//') + echo "coverage=$COVERAGE" >> $GITHUB_OUTPUT + else + echo "coverage=0" >> $GITHUB_OUTPUT + fi + + - name: download artifact (master.breakdown) + id: download-master-breakdown + uses: dawidd6/action-download-artifact@v9 + with: + branch: master + workflow_conclusion: success + name: master.breakdown + if_no_artifact_found: warn + + - name: download artifact (master-coverage.out) + id: download-master-coverage + uses: dawidd6/action-download-artifact@v9 + with: + branch: master + workflow_conclusion: success + name: master-coverage.out + if_no_artifact_found: warn + + - name: Extract master coverage percentage + id: master-coverage + run: | + if [ -f master-coverage.out ]; then + MASTER_COVERAGE=$(go tool cover -func=master-coverage.out | grep total: | awk '{print $3}' | sed 's/%//') + echo "coverage=$MASTER_COVERAGE" >> $GITHUB_OUTPUT + else + echo "coverage=0" >> $GITHUB_OUTPUT + fi + + - name: Generate full coverage breakdown + id: full_coverage_report + run: | + if [ -f coverage.out ]; then + REPORT_CONTENT=$(go tool cover -func=coverage.out) # This command outputs function-level coverage [5] + echo "report<> $GITHUB_OUTPUT # Start HERE-doc for multi-line output [3] + echo "$REPORT_CONTENT" >> $GITHUB_OUTPUT + echo "EOF" >> $GITHUB_OUTPUT # End HERE-doc + else + echo "report=No coverage report found." >> $GITHUB_OUTPUT + fi + + - name: check test coverage + id: coverage + uses: vladopajic/go-test-coverage@v2 + continue-on-error: true + with: + config: ./.github/.testcoverage.yml + breakdown-file-name: ${{ github.ref_name == 'master' && 'master.breakdown' || '' }} + diff-base-breakdown-file-name: ${{ steps.download-master-breakdown.outputs.found_artifact == 'true' && 'master.breakdown' || '' }} + + - name: upload artifact (master.breakdown) + uses: actions/upload-artifact@v4 + if: github.ref_name == 'master' + with: + name: master.breakdown + path: master.breakdown + if-no-files-found: error + + - name: Previous coverage + run: | + echo "Previous Coverage ${{ steps.master-coverage.outputs.coverage }}" + + - name: Current coverage + run: | + echo "Current Coverage ${{ steps.current-coverage.outputs.coverage }}" + + - name: post coverage report + if: github.event_name == 'pull_request' + uses: thollander/actions-comment-pull-request@v3 + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + comment-tag: coverage-report + pr-number: ${{ github.event.pull_request.number }} + message: | + ## 📊 Go Test Coverage Report + + ${{ + steps.current-coverage.outputs.coverage > steps.master-coverage.outputs.coverage + && '✅ **Overall code coverage increased.**' + || steps.current-coverage.outputs.coverage < steps.master-coverage.outputs.coverage + && '❌ **Overall code coverage decreased.**' + || 'â„šī¸ **Overall code coverage unchanged.**' + }} + + **🔍 Coverage Summary** + - **Pull Request Coverage:** `${{ steps.current-coverage.outputs.coverage }}%` + - **Main Branch Coverage:** `${{ steps.master-coverage.outputs.coverage }}%` + +
+ 📄 Click to expand full coverage breakdown + + ``` + ${{ steps.full_coverage_report.outputs.report }} + ``` + +
+ - name: Rename and upload master coverage + if: github.ref_name == 'master' + run: mv coverage.out master-coverage.out + + - name: Upload master coverage artifact + if: github.ref_name == 'master' + uses: actions/upload-artifact@v4 + with: + name: master-coverage.out + path: master-coverage.out + if-no-files-found: error \ No newline at end of file