From 16789f094062c3909125f74c354cccdb6cc27e04 Mon Sep 17 00:00:00 2001 From: jooho lee Date: Mon, 10 Jun 2024 22:23:13 -0400 Subject: [PATCH 01/13] add isvc service cert reconciler Signed-off-by: jooho lee --- config/manager/kustomization.yaml | 14 +- controllers/constants/constants.go | 5 + ...kserve_inferenceservice_controller_test.go | 68 +++++++++ .../kserve_isvc_service_cert_reconciler.go | 136 ++++++++++++++++++ ..._serverless_inferenceservice_reconciler.go | 1 + controllers/resources/service.go | 35 ++++- controllers/suite_test.go | 1 + .../servingcert-service/test-isvc-svc.yaml | 9 ++ 8 files changed, 262 insertions(+), 7 deletions(-) create mode 100644 controllers/reconcilers/kserve_isvc_service_cert_reconciler.go create mode 100644 controllers/testdata/servingcert-service/test-isvc-svc.yaml diff --git a/config/manager/kustomization.yaml b/config/manager/kustomization.yaml index 8ee25655..11e821af 100644 --- a/config/manager/kustomization.yaml +++ b/config/manager/kustomization.yaml @@ -1,10 +1,16 @@ resources: - - manager.yaml +- manager.yaml generatorOptions: disableNameSuffixHash: true configMapGenerator: - - files: - - controller_manager_config.yaml - name: manager-config +- files: + - controller_manager_config.yaml + name: manager-config +apiVersion: kustomize.config.k8s.io/v1beta1 +kind: Kustomization +images: +- name: controller + newName: quay.io/jooho/odh-model-controller + newTag: latest diff --git a/controllers/constants/constants.go b/controllers/constants/constants.go index d1dadd0f..0acb83da 100644 --- a/controllers/constants/constants.go +++ b/controllers/constants/constants.go @@ -53,3 +53,8 @@ const ( const ( DefaultStorageConfig = "storage-config" ) + +// openshift +const ( + ServingCertAnnotationKey = "service.beta.openshift.io/serving-cert-secret-name" +) diff --git a/controllers/kserve_inferenceservice_controller_test.go b/controllers/kserve_inferenceservice_controller_test.go index 0f3fb3cd..61573b81 100644 --- a/controllers/kserve_inferenceservice_controller_test.go +++ b/controllers/kserve_inferenceservice_controller_test.go @@ -17,6 +17,8 @@ package controllers import ( "context" + "fmt" + "time" "strings" @@ -31,12 +33,17 @@ import ( corev1 "k8s.io/api/core/v1" v1 "k8s.io/api/networking/v1" "k8s.io/apimachinery/pkg/api/errors" + apierrs "k8s.io/apimachinery/pkg/api/errors" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/types" "knative.dev/pkg/apis" "sigs.k8s.io/controller-runtime/pkg/client" ) +const ( + testIsvcSvcPath = "./testdata/servingcert-service/test-isvc-svc.yaml" +) + var _ = Describe("The Openshift Kserve model controller", func() { When("creating a Kserve ServiceRuntime & InferenceService", func() { @@ -102,6 +109,40 @@ var _ = Describe("The Openshift Kserve model controller", func() { }, timeout, interval).Should(Succeed()) }) + It("With Kserve InferenceService, a runtime Service add serving cert annotation", func() { + // Create a isvc + inferenceService := &kservev1beta1.InferenceService{} + err := convertToStructuredResource(KserveInferenceServicePath1, inferenceService) + Expect(err).NotTo(HaveOccurred()) + inferenceService.SetNamespace(testNs) + + Expect(cli.Create(ctx, inferenceService)).Should(Succeed()) + + // Create a expected service that is supposed to be created by KServe operator. + svc := &corev1.Service{} + err = convertToStructuredResource(testIsvcSvcPath, svc) + Expect(err).NotTo(HaveOccurred()) + svc.SetNamespace(inferenceService.Namespace) + Expect(cli.Create(ctx, svc)).Should(Succeed()) + + // Update URL of ISVC that means it is ready. + deployedInferenceService := &kservev1beta1.InferenceService{} + err = cli.Get(ctx, types.NamespacedName{Name: inferenceService.Name, Namespace: inferenceService.Namespace}, deployedInferenceService) + Expect(err).NotTo(HaveOccurred()) + + url, err := apis.ParseURL("https://example-onnx-mnist-default.test.com") + Expect(err).NotTo(HaveOccurred()) + deployedInferenceService.Status.URL = url + + err = cli.Status().Update(ctx, deployedInferenceService) + Expect(err).NotTo(HaveOccurred()) + + isvcService, err := waitForService(cli, testNs, inferenceService.Name, 10, 3*time.Second) + Expect(err).NotTo(HaveOccurred()) + + Expect(isvcService.Annotations[constants.ServingCertAnnotationKey]).Should(Equal(inferenceService.Name)) + }) + It("should create required network policies when KServe is used", func() { // given inferenceService := &kservev1beta1.InferenceService{} @@ -158,3 +199,30 @@ func withMatchingNestedField(path string, matcher gomegatypes.GomegaMatcher) gom func getKServeRouteName(isvc *kservev1beta1.InferenceService) string { return isvc.Name + "-" + isvc.Namespace } + +func waitForService(cli client.Client, namespace, serviceName string, maxTries int, delay time.Duration) (*corev1.Service, error) { + time.Sleep(delay) + + ctx := context.Background() + service := &corev1.Service{} + for try := 1; try <= maxTries; try++ { + err := cli.Get(ctx, client.ObjectKey{Namespace: namespace, Name: serviceName}, service) + if err == nil { + if service.GetAnnotations() == nil { + time.Sleep(1 * time.Second) + continue + } + return service, nil + } + if !apierrs.IsNotFound(err) { + return nil, fmt.Errorf("failed to get service %s/%s: %v", namespace, serviceName, err) + } + + if try < maxTries { + + time.Sleep(1 * time.Second) + return nil, err + } + } + return service, nil +} diff --git a/controllers/reconcilers/kserve_isvc_service_cert_reconciler.go b/controllers/reconcilers/kserve_isvc_service_cert_reconciler.go new file mode 100644 index 00000000..0116430e --- /dev/null +++ b/controllers/reconcilers/kserve_isvc_service_cert_reconciler.go @@ -0,0 +1,136 @@ +/* + +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 reconcilers + +import ( + "context" + "time" + + "github.com/go-logr/logr" + kservev1beta1 "github.com/kserve/kserve/pkg/apis/serving/v1beta1" + "github.com/opendatahub-io/odh-model-controller/controllers/constants" + "github.com/opendatahub-io/odh-model-controller/controllers/resources" + v1 "k8s.io/api/core/v1" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/types" + "sigs.k8s.io/controller-runtime/pkg/client" +) + +var _ SubResourceReconciler = (*KserveIsvcServiceReconciler)(nil) + +type KserveIsvcServiceReconciler struct { + client client.Client + serviceHandler resources.ServiceHandler +} + +func NewKserveIsvcServiceReconciler(client client.Client) *KserveIsvcServiceReconciler { + return &KserveIsvcServiceReconciler{ + client: client, + serviceHandler: resources.NewServiceHandler(client), + } +} + +func (r *KserveIsvcServiceReconciler) Delete(ctx context.Context, log logr.Logger, isvc *kservev1beta1.InferenceService) error { + // NOOP - resources are deleted together with ISVCs + return nil +} + +func (r *KserveIsvcServiceReconciler) Cleanup(_ context.Context, _ logr.Logger, _ string) error { + // NOOP - resources are deleted together with ISVCs + return nil +} + +func (r *KserveIsvcServiceReconciler) Reconcile(ctx context.Context, log logr.Logger, isvc *kservev1beta1.InferenceService) error { + log.V(1).Info("Reconciling ISVC service serving cert for for Kserve InferenceService") + + // return if URL is not set + if isvc.Status.URL == nil { + log.V(1).Info("Inference Service not ready yet, waiting for URL") + return nil + } + + // Create Desired resource + desiredResource, err := r.createDesiredResource(isvc, log) + if err != nil { + return err + } + + // Get Existing resource + existingResource, err := r.getExistingResource(ctx, log, isvc) + if err != nil { + return err + } + + // Process Delta + if err = r.processDelta(ctx, log, desiredResource, existingResource); err != nil { + return err + } + return nil +} + +func (r *KserveIsvcServiceReconciler) createDesiredResource(isvc *kservev1beta1.InferenceService, log logr.Logger) (*v1.Service, error) { + service := &v1.Service{ + ObjectMeta: metav1.ObjectMeta{ + Name: "isvc-service", + Annotations: map[string]string{ + constants.ServingCertAnnotationKey: isvc.Name, + }, + }, + } + return service, nil +} + +func (r *KserveIsvcServiceReconciler) getExistingResource(ctx context.Context, log logr.Logger, isvc *kservev1beta1.InferenceService) (*v1.Service, error) { + // log.Info("Fetching existing KServe runtime Service") + return r.serviceHandler.FetchWithRetryAndDelay(ctx, log, types.NamespacedName{Name: isvc.Name, Namespace: isvc.Namespace}, 1*time.Second, 10) +} + +func (r *KserveIsvcServiceReconciler) processDelta(ctx context.Context, log logr.Logger, desiredService *v1.Service, existingService *v1.Service) (err error) { + + if isUpdated(desiredService, existingService, log) { + log.V(1).Info("Delta found", "update", existingService.GetName()) + service := existingService.DeepCopy() + if service.Annotations == nil { + service.Annotations = make(map[string]string) + } + service.Annotations = desiredService.Annotations + + if err = r.client.Update(ctx, service); err != nil { + return err + } + + // log.V(1).Info("Add Serving cert annotation to kserve inferenceservice Service object", "update", existingService.GetName()) + } + return nil +} + +func isUpdated(desiredService *v1.Service, existingService *v1.Service, log logr.Logger) bool { + if existingService == nil { + log.Info("Service for a InferenceService is not created yet") + return false + } + deployedAnnotations := existingService.GetAnnotations() + + if len(deployedAnnotations) != 0 { + if val, exists := existingService.Annotations[constants.ServingCertAnnotationKey]; exists { + if val == desiredService.Annotations[constants.ServingCertAnnotationKey] { + return false + } + } + } + + return true +} diff --git a/controllers/reconcilers/kserve_serverless_inferenceservice_reconciler.go b/controllers/reconcilers/kserve_serverless_inferenceservice_reconciler.go index abbf9487..02883c70 100644 --- a/controllers/reconcilers/kserve_serverless_inferenceservice_reconciler.go +++ b/controllers/reconcilers/kserve_serverless_inferenceservice_reconciler.go @@ -45,6 +45,7 @@ func NewKServeServerlessInferenceServiceReconciler(client client.Client) *Kserve NewKServeIstioPeerAuthenticationReconciler(client), NewKServeNetworkPolicyReconciler(client), NewKserveAuthConfigReconciler(client), + NewKserveIsvcServiceReconciler(client), } return &KserveServerlessInferenceServiceReconciler{ diff --git a/controllers/resources/service.go b/controllers/resources/service.go index c3ac39ff..411efbc6 100644 --- a/controllers/resources/service.go +++ b/controllers/resources/service.go @@ -17,6 +17,9 @@ package resources import ( "context" + "fmt" + "time" + "github.com/go-logr/logr" v1 "k8s.io/api/core/v1" "k8s.io/apimachinery/pkg/api/errors" @@ -26,6 +29,7 @@ import ( type ServiceHandler interface { FetchService(ctx context.Context, log logr.Logger, key types.NamespacedName) (*v1.Service, error) + FetchWithRetryAndDelay(ctx context.Context, log logr.Logger, key types.NamespacedName, retryDelay time.Duration, retry int) (*v1.Service, error) } type serviceHandler struct { @@ -39,8 +43,8 @@ func NewServiceHandler(client client.Client) ServiceHandler { } func (r *serviceHandler) FetchService(ctx context.Context, log logr.Logger, key types.NamespacedName) (*v1.Service, error) { - route := &v1.Service{} - err := r.client.Get(ctx, key, route) + svc := &v1.Service{} + err := r.client.Get(ctx, key, svc) if err != nil && errors.IsNotFound(err) { log.V(1).Info("Service not found.") return nil, nil @@ -48,5 +52,30 @@ func (r *serviceHandler) FetchService(ctx context.Context, log logr.Logger, key return nil, err } log.V(1).Info("Successfully fetch deployed Service") - return route, nil + return svc, nil +} + +func (r *serviceHandler) FetchWithRetryAndDelay(ctx context.Context, log logr.Logger, key types.NamespacedName, retryDelay time.Duration, retry int) (*v1.Service, error) { + var svc *v1.Service + var err error + + for attempt := 1; attempt <= retry; attempt++ { + svc, err = r.FetchService(ctx, log, key) + if err != nil { + if svc == nil || errors.IsNotFound(err) { + log.Info(fmt.Sprintf("Service is not created yet, attempt %d", attempt)) + time.Sleep(retryDelay) + continue + } else { + return nil, err + } + } + } + + if svc != nil { + log.Info("Successfully fetched the Service") + } else { + log.Info(fmt.Sprintf("Failed to fetch the Service(%s) after retries(%d)", key.Name, retry)) + } + return svc, nil } diff --git a/controllers/suite_test.go b/controllers/suite_test.go index 0d5099e0..39659627 100644 --- a/controllers/suite_test.go +++ b/controllers/suite_test.go @@ -212,6 +212,7 @@ var _ = AfterEach(func() { Expect(cli.DeleteAllOf(context.TODO(), &corev1.Secret{}, inNamespace)).ToNot(HaveOccurred()) Expect(cli.DeleteAllOf(context.TODO(), &authorinov1beta2.AuthConfig{}, inNamespace)).ToNot(HaveOccurred()) Expect(cli.DeleteAllOf(context.TODO(), &corev1.ConfigMap{}, inNamespace)).ToNot(HaveOccurred()) + Expect(cli.DeleteAllOf(context.TODO(), &corev1.Service{}, inNamespace)).ToNot(HaveOccurred()) } cleanUp(WorkingNamespace, cli) for _, ns := range Namespaces.All() { diff --git a/controllers/testdata/servingcert-service/test-isvc-svc.yaml b/controllers/testdata/servingcert-service/test-isvc-svc.yaml new file mode 100644 index 00000000..94ccecd4 --- /dev/null +++ b/controllers/testdata/servingcert-service/test-isvc-svc.yaml @@ -0,0 +1,9 @@ +apiVersion: v1 +kind: Service +metadata: + name: example-onnx-mnist + namespace: default +spec: + externalName: kserve-local-gateway.istio-system.svc.cluster.local + sessionAffinity: None + type: ExternalName From 455d4399690a0671fb6a2bd0e6246bde7f21bf5a Mon Sep 17 00:00:00 2001 From: jooho lee Date: Tue, 11 Jun 2024 22:23:16 -0400 Subject: [PATCH 02/13] add gateway reconcile, update minor comments, fix some minor issue Signed-off-by: jooho lee --- .../gateways.networking.istio.io.yaml | 258 +++++++++++++++++ config/manager/kustomization.yaml | 7 +- config/rbac/role.yaml | 24 ++ controllers/comparators/gateway_comparator.go | 44 +++ controllers/constants/constants.go | 1 + ...kserve_inferenceservice_controller_test.go | 214 +++++++++++++- .../kserve_isvc_gateway_reconciler.go | 263 ++++++++++++++++++ .../kserve_isvc_service_cert_reconciler.go | 18 +- ..._serverless_inferenceservice_reconciler.go | 1 + controllers/resources/gateway.go | 55 ++++ controllers/resources/secret.go | 47 ++++ controllers/resources/service.go | 7 +- controllers/suite_test.go | 11 +- .../gateway/kserve-local-gateway.yaml | 15 + .../gateway/test-isvc-svc-secret.yaml | 19 ++ controllers/utils/init.go | 2 + main.go | 2 + 17 files changed, 952 insertions(+), 36 deletions(-) create mode 100644 config/crd/external/gateways.networking.istio.io.yaml create mode 100644 controllers/comparators/gateway_comparator.go create mode 100644 controllers/reconcilers/kserve_isvc_gateway_reconciler.go create mode 100644 controllers/resources/gateway.go create mode 100644 controllers/resources/secret.go create mode 100644 controllers/testdata/gateway/kserve-local-gateway.yaml create mode 100644 controllers/testdata/gateway/test-isvc-svc-secret.yaml diff --git a/config/crd/external/gateways.networking.istio.io.yaml b/config/crd/external/gateways.networking.istio.io.yaml new file mode 100644 index 00000000..0213bc9f --- /dev/null +++ b/config/crd/external/gateways.networking.istio.io.yaml @@ -0,0 +1,258 @@ +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + labels: + app: istio-pilot + chart: istio + heritage: Tiller + maistra-version: 2.5.2 + release: istio + name: gateways.networking.istio.io +spec: + conversion: + strategy: None + group: networking.istio.io + names: + categories: + - istio-io + - networking-istio-io + kind: Gateway + listKind: GatewayList + plural: gateways + shortNames: + - gw + singular: gateway + scope: Namespaced + versions: + - name: v1alpha3 + schema: + openAPIV3Schema: + properties: + spec: + description: 'Configuration affecting edge load balancer. See more details + at: https://istio.io/docs/reference/config/networking/gateway.html' + properties: + selector: + additionalProperties: + type: string + type: object + servers: + description: A list of server specifications. + items: + properties: + bind: + type: string + defaultEndpoint: + type: string + hosts: + description: One or more hosts exposed by this gateway. + items: + type: string + type: array + name: + description: An optional name of the server, when set must be + unique across all servers. + type: string + port: + properties: + name: + description: Label assigned to the port. + type: string + number: + description: A valid non-negative integer port number. + type: integer + protocol: + description: The protocol exposed on the port. + type: string + targetPort: + type: integer + type: object + tls: + description: Set of TLS related options that govern the server's + behavior. + properties: + caCertificates: + description: REQUIRED if mode is `MUTUAL`. + type: string + cipherSuites: + description: 'Optional: If specified, only support the specified + cipher list.' + items: + type: string + type: array + credentialName: + type: string + httpsRedirect: + type: boolean + maxProtocolVersion: + description: 'Optional: Maximum TLS protocol version.' + enum: + - TLS_AUTO + - TLSV1_0 + - TLSV1_1 + - TLSV1_2 + - TLSV1_3 + type: string + minProtocolVersion: + description: 'Optional: Minimum TLS protocol version.' + enum: + - TLS_AUTO + - TLSV1_0 + - TLSV1_1 + - TLSV1_2 + - TLSV1_3 + type: string + mode: + enum: + - PASSTHROUGH + - SIMPLE + - MUTUAL + - AUTO_PASSTHROUGH + - ISTIO_MUTUAL + type: string + privateKey: + description: REQUIRED if mode is `SIMPLE` or `MUTUAL`. + type: string + serverCertificate: + description: REQUIRED if mode is `SIMPLE` or `MUTUAL`. + type: string + subjectAltNames: + items: + type: string + type: array + verifyCertificateHash: + items: + type: string + type: array + verifyCertificateSpki: + items: + type: string + type: array + type: object + type: object + type: array + type: object + status: + type: object + x-kubernetes-preserve-unknown-fields: true + type: object + served: true + storage: true + subresources: + status: {} + - name: v1beta1 + schema: + openAPIV3Schema: + properties: + spec: + description: 'Configuration affecting edge load balancer. See more details + at: https://istio.io/docs/reference/config/networking/gateway.html' + properties: + selector: + additionalProperties: + type: string + type: object + servers: + description: A list of server specifications. + items: + properties: + bind: + type: string + defaultEndpoint: + type: string + hosts: + description: One or more hosts exposed by this gateway. + items: + type: string + type: array + name: + description: An optional name of the server, when set must be + unique across all servers. + type: string + port: + properties: + name: + description: Label assigned to the port. + type: string + number: + description: A valid non-negative integer port number. + type: integer + protocol: + description: The protocol exposed on the port. + type: string + targetPort: + type: integer + type: object + tls: + description: Set of TLS related options that govern the server's + behavior. + properties: + caCertificates: + description: REQUIRED if mode is `MUTUAL`. + type: string + cipherSuites: + description: 'Optional: If specified, only support the specified + cipher list.' + items: + type: string + type: array + credentialName: + type: string + httpsRedirect: + type: boolean + maxProtocolVersion: + description: 'Optional: Maximum TLS protocol version.' + enum: + - TLS_AUTO + - TLSV1_0 + - TLSV1_1 + - TLSV1_2 + - TLSV1_3 + type: string + minProtocolVersion: + description: 'Optional: Minimum TLS protocol version.' + enum: + - TLS_AUTO + - TLSV1_0 + - TLSV1_1 + - TLSV1_2 + - TLSV1_3 + type: string + mode: + enum: + - PASSTHROUGH + - SIMPLE + - MUTUAL + - AUTO_PASSTHROUGH + - ISTIO_MUTUAL + type: string + privateKey: + description: REQUIRED if mode is `SIMPLE` or `MUTUAL`. + type: string + serverCertificate: + description: REQUIRED if mode is `SIMPLE` or `MUTUAL`. + type: string + subjectAltNames: + items: + type: string + type: array + verifyCertificateHash: + items: + type: string + type: array + verifyCertificateSpki: + items: + type: string + type: array + type: object + type: object + type: array + type: object + status: + type: object + x-kubernetes-preserve-unknown-fields: true + type: object + served: true + storage: false + subresources: + status: {} diff --git a/config/manager/kustomization.yaml b/config/manager/kustomization.yaml index 11e821af..f033e3ee 100644 --- a/config/manager/kustomization.yaml +++ b/config/manager/kustomization.yaml @@ -8,9 +8,4 @@ configMapGenerator: - files: - controller_manager_config.yaml name: manager-config -apiVersion: kustomize.config.k8s.io/v1beta1 -kind: Kustomization -images: -- name: controller - newName: quay.io/jooho/odh-model-controller - newTag: latest + diff --git a/config/rbac/role.yaml b/config/rbac/role.yaml index 5e235fe2..f1fb6c1f 100644 --- a/config/rbac/role.yaml +++ b/config/rbac/role.yaml @@ -141,6 +141,30 @@ rules: - patch - update - watch +- apiGroups: + - networking.istio.io + resources: + - gateways + verbs: + - create + - delete + - get + - list + - patch + - update + - watch +- apiGroups: + - networking.istio.io + resources: + - gateways/finalizers + verbs: + - create + - delete + - get + - list + - patch + - update + - watch - apiGroups: - networking.istio.io resources: diff --git a/controllers/comparators/gateway_comparator.go b/controllers/comparators/gateway_comparator.go new file mode 100644 index 00000000..cdbf68fb --- /dev/null +++ b/controllers/comparators/gateway_comparator.go @@ -0,0 +1,44 @@ +/* + +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 comparators + +import ( + istiov1beta1 "istio.io/api/networking/v1beta1" + istioclientv1beta1 "istio.io/client-go/pkg/apis/networking/v1beta1" + "sigs.k8s.io/controller-runtime/pkg/client" +) + +func GetGatewayComparator() ResourceComparator { + return func(existing client.Object, desired client.Object) bool { + existingGateway := existing.(*istioclientv1beta1.Gateway) + desiredGateway := desired.(*istioclientv1beta1.Gateway) + + exists := false + for _, server := range existingGateway.Spec.Servers { + if serversEqual(server, desiredGateway.Spec.Servers[0]) { + exists = true + break + } + } + + return exists + } +} + +// Function to compare two Server objects +func serversEqual(s1, s2 *istiov1beta1.Server) bool { + return s1.Port.Name == s2.Port.Name +} diff --git a/controllers/constants/constants.go b/controllers/constants/constants.go index 0acb83da..b3644849 100644 --- a/controllers/constants/constants.go +++ b/controllers/constants/constants.go @@ -48,6 +48,7 @@ const ( KServeCACertConfigMapName = "odh-kserve-custom-ca-bundle" ODHGlobalCertConfigMapName = "odh-trusted-ca-bundle" ODHCustomCACertFileName = "odh-ca-bundle.crt" + KServeGatewayName = "kserve-local-gateway" ) const ( diff --git a/controllers/kserve_inferenceservice_controller_test.go b/controllers/kserve_inferenceservice_controller_test.go index 61573b81..a8842993 100644 --- a/controllers/kserve_inferenceservice_controller_test.go +++ b/controllers/kserve_inferenceservice_controller_test.go @@ -17,7 +17,6 @@ package controllers import ( "context" - "fmt" "time" "strings" @@ -30,10 +29,10 @@ import ( gomegatypes "github.com/onsi/gomega/types" "github.com/opendatahub-io/odh-model-controller/controllers/constants" routev1 "github.com/openshift/api/route/v1" + istioclientv1beta1 "istio.io/client-go/pkg/apis/networking/v1beta1" corev1 "k8s.io/api/core/v1" v1 "k8s.io/api/networking/v1" "k8s.io/apimachinery/pkg/api/errors" - apierrs "k8s.io/apimachinery/pkg/api/errors" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/types" "knative.dev/pkg/apis" @@ -41,7 +40,9 @@ import ( ) const ( - testIsvcSvcPath = "./testdata/servingcert-service/test-isvc-svc.yaml" + testIsvcSvcPath = "./testdata/servingcert-service/test-isvc-svc.yaml" + kserveLocalGatewayPath = "./testdata/gateway/kserve-local-gateway.yaml" + testIsvcSvcSecretPath = "./testdata/gateway/test-isvc-svc-secret.yaml" ) var _ = Describe("The Openshift Kserve model controller", func() { @@ -109,23 +110,22 @@ var _ = Describe("The Openshift Kserve model controller", func() { }, timeout, interval).Should(Succeed()) }) - It("With Kserve InferenceService, a runtime Service add serving cert annotation", func() { - // Create a isvc + It("With a new Kserve InferenceService, serving cert annotation should be added to the runtime Service object.", func() { + // Create a new InferenceService inferenceService := &kservev1beta1.InferenceService{} err := convertToStructuredResource(KserveInferenceServicePath1, inferenceService) Expect(err).NotTo(HaveOccurred()) inferenceService.SetNamespace(testNs) - Expect(cli.Create(ctx, inferenceService)).Should(Succeed()) - // Create a expected service that is supposed to be created by KServe operator. + // Stub: Create a Runtime Service, which must be created by the OpenDataHub operator. svc := &corev1.Service{} err = convertToStructuredResource(testIsvcSvcPath, svc) Expect(err).NotTo(HaveOccurred()) svc.SetNamespace(inferenceService.Namespace) Expect(cli.Create(ctx, svc)).Should(Succeed()) - // Update URL of ISVC that means it is ready. + // Update the URL of the InferenceService to indicate it is ready. deployedInferenceService := &kservev1beta1.InferenceService{} err = cli.Get(ctx, types.NamespacedName{Name: inferenceService.Name, Namespace: inferenceService.Namespace}, deployedInferenceService) Expect(err).NotTo(HaveOccurred()) @@ -137,12 +137,62 @@ var _ = Describe("The Openshift Kserve model controller", func() { err = cli.Status().Update(ctx, deployedInferenceService) Expect(err).NotTo(HaveOccurred()) - isvcService, err := waitForService(cli, testNs, inferenceService.Name, 10, 3*time.Second) + isvcService, err := waitForService(cli, testNs, inferenceService.Name, 5, 2*time.Second) Expect(err).NotTo(HaveOccurred()) Expect(isvcService.Annotations[constants.ServingCertAnnotationKey]).Should(Equal(inferenceService.Name)) }) + It("should create a secret for runtime and update kserve local gateway in the istio-system namespace", func() { + // Stub: Create a kserve-local-gateway, which must be created by the OpenDataHub operator. + kserveLocalGateway := &istioclientv1beta1.Gateway{} + err := convertToStructuredResource(kserveLocalGatewayPath, kserveLocalGateway) + Expect(err).NotTo(HaveOccurred()) + Expect(cli.Create(ctx, kserveLocalGateway)).Should(Succeed()) + + // Create a new InferenceService + inferenceService := &kservev1beta1.InferenceService{} + err = convertToStructuredResource(KserveInferenceServicePath1, inferenceService) + Expect(err).NotTo(HaveOccurred()) + inferenceService.SetNamespace(testNs) + + Expect(cli.Create(ctx, inferenceService)).Should(Succeed()) + + // Update the URL of the InferenceService to indicate it is ready. + deployedInferenceService := &kservev1beta1.InferenceService{} + err = cli.Get(ctx, types.NamespacedName{Name: inferenceService.Name, Namespace: inferenceService.Namespace}, deployedInferenceService) + Expect(err).NotTo(HaveOccurred()) + + url, err := apis.ParseURL("https://example-onnx-mnist-default.test.com") + Expect(err).NotTo(HaveOccurred()) + deployedInferenceService.Status.URL = url + + err = cli.Status().Update(ctx, deployedInferenceService) + Expect(err).NotTo(HaveOccurred()) + + // Stub: Create a certificate Secret, which must be created by the openshift service-ca operator. + secret := &corev1.Secret{} + err = convertToStructuredResource(testIsvcSvcSecretPath, secret) + Expect(err).NotTo(HaveOccurred()) + secret.SetNamespace(inferenceService.Namespace) + Expect(cli.Create(ctx, secret)).Should(Succeed()) + + // Verify that the certificate secret is found in the same namespace where the InferenceService is created. + _, err = waitForSecret(cli, inferenceService.Namespace, inferenceService.Name, 5, 1*time.Second) + Expect(err).NotTo(HaveOccurred()) + + // Verify that the certificate secret is created in the istio-system namespace. + _, err = waitForSecret(cli, constants.IstioNamespace, inferenceService.Name, 5, 5*time.Second) + Expect(err).NotTo(HaveOccurred()) + + gateway, err := waitForUpdatedGatewayCompletion(cli, "add", constants.IstioNamespace, constants.KServeGatewayName, inferenceService.Name, 5, 2*time.Second) + Expect(err).NotTo(HaveOccurred()) + + // Ensure that the server is successfully added to the KServe local gateway within the istio-system namespace. + targetServerExist := isServerExistFromGateway(gateway, inferenceService.Name) + Expect(targetServerExist).Should(BeTrue()) + }) + It("should create required network policies when KServe is used", func() { // given inferenceService := &kservev1beta1.InferenceService{} @@ -169,8 +219,105 @@ var _ = Describe("The Openshift Kserve model controller", func() { ), ) }) + }) + + Context("when deleting a Kserve InferenceService", func() { + var testNs string + var isvcName string + + BeforeEach(func() { + ctx := context.Background() + testNs = Namespaces.Get() + testNamespace := &corev1.Namespace{ + ObjectMeta: metav1.ObjectMeta{ + Name: testNs, + Namespace: testNs, + }, + } + Expect(cli.Create(ctx, testNamespace)).Should(Succeed()) + + inferenceServiceConfig := &corev1.ConfigMap{} + Expect(convertToStructuredResource(InferenceServiceConfigPath1, inferenceServiceConfig)).To(Succeed()) + if err := cli.Create(ctx, inferenceServiceConfig); err != nil && !errors.IsAlreadyExists(err) { + Fail(err.Error()) + } + + servingRuntime := &kservev1alpha1.ServingRuntime{} + Expect(convertToStructuredResource(KserveServingRuntimePath1, servingRuntime)).To(Succeed()) + if err := cli.Create(ctx, servingRuntime); err != nil && !errors.IsAlreadyExists(err) { + Fail(err.Error()) + } + + // Stub: Create a kserve-local-gateway, which must be created by the OpenDataHub operator. + kserveLocalGateway := &istioclientv1beta1.Gateway{} + err := convertToStructuredResource(kserveLocalGatewayPath, kserveLocalGateway) + Expect(err).NotTo(HaveOccurred()) + + Expect(cli.Create(ctx, kserveLocalGateway)).Should(Succeed()) + + // Create a new InferenceService + inferenceService := &kservev1beta1.InferenceService{} + err = convertToStructuredResource(KserveInferenceServicePath1, inferenceService) + Expect(err).NotTo(HaveOccurred()) + inferenceService.SetNamespace(testNs) + // Ensure the Delete method is called when the InferenceService (ISVC) is deleted. + inferenceService.SetFinalizers([]string{"finalizer.inferenceservice"}) + + Expect(cli.Create(ctx, inferenceService)).Should(Succeed()) + isvcName = inferenceService.Name + + // Update the URL of the InferenceService to indicate it is ready. + deployedInferenceService := &kservev1beta1.InferenceService{} + err = cli.Get(ctx, types.NamespacedName{Name: inferenceService.Name, Namespace: testNs}, deployedInferenceService) + Expect(err).NotTo(HaveOccurred()) + + url, err := apis.ParseURL("https://example-onnx-mnist-default.test.com") + Expect(err).NotTo(HaveOccurred()) + deployedInferenceService.Status.URL = url + + err = cli.Status().Update(ctx, deployedInferenceService) + Expect(err).NotTo(HaveOccurred()) + + // Stub: Create a certificate Secret, which must be created by the openshift service-ca operator. + secret := &corev1.Secret{} + err = convertToStructuredResource(testIsvcSvcSecretPath, secret) + Expect(err).NotTo(HaveOccurred()) + secret.SetNamespace(testNs) + Expect(cli.Create(ctx, secret)).Should(Succeed()) + + // Verify that the certificate secret is created in the istio-system namespace. + _, err = waitForSecret(cli, constants.IstioNamespace, inferenceService.Name, 5, 2*time.Second) + Expect(err).NotTo(HaveOccurred()) + + gateway, err := waitForUpdatedGatewayCompletion(cli, "add", constants.IstioNamespace, constants.KServeGatewayName, inferenceService.Name, 5, 2*time.Second) + Expect(err).NotTo(HaveOccurred()) + + // Ensure that the server is successfully added to the KServe local gateway within the istio-system namespace. + targetServerExist := isServerExistFromGateway(gateway, inferenceService.Name) + Expect(targetServerExist).Should(BeTrue()) + }) + + It("should remove the Server from the kserve local gateway in istio-system and delete the created Secret", func() { + // Delete the existing ISVC + deployedInferenceService := &kservev1beta1.InferenceService{} + err := cli.Get(ctx, types.NamespacedName{Name: isvcName, Namespace: testNs}, deployedInferenceService) + Expect(err).NotTo(HaveOccurred()) + Expect(cli.Delete(ctx, deployedInferenceService)).Should(Succeed()) + + gateway, err := waitForUpdatedGatewayCompletion(cli, "delete", constants.IstioNamespace, constants.KServeGatewayName, isvcName, 5, 2*time.Second) + Expect(err).NotTo(HaveOccurred()) + + // Ensure that the server is successfully removed from the KServe local gateway within the istio-system namespace. + targetServerExist := isServerExistFromGateway(gateway, isvcName) + Expect(targetServerExist).Should(BeFalse()) + // Ensure that the created Secret is successfully deleted within the istio-system namespace. + secret, err := waitForSecret(cli, constants.IstioNamespace, isvcName, 5, 2*time.Second) + Expect(err).To(HaveOccurred()) + Expect(secret).Should(BeNil()) + }) }) + }) func withMatchingNestedField(path string, matcher gomegatypes.GomegaMatcher) gomegatypes.GomegaMatcher { @@ -214,15 +361,58 @@ func waitForService(cli client.Client, namespace, serviceName string, maxTries i } return service, nil } - if !apierrs.IsNotFound(err) { - return nil, fmt.Errorf("failed to get service %s/%s: %v", namespace, serviceName, err) + if !errors.IsNotFound(err) { + continue } if try < maxTries { - time.Sleep(1 * time.Second) return nil, err } } return service, nil } + +// This function waits for the updated gateway completion after a specified delay. +// During the wait, it checks the gateway repeatedly until the specified operation (add or delete) is completed or the maximum number of tries is reached. +// If the maximum number of tries is exceeded, it returns an error. +func waitForUpdatedGatewayCompletion(cli client.Client, op string, namespace, gatewayName string, isvcName string, maxTries int, delay time.Duration) (*istioclientv1beta1.Gateway, error) { + time.Sleep(delay) + + ctx := context.Background() + gateway := &istioclientv1beta1.Gateway{} + for try := 1; try <= maxTries; try++ { + err := cli.Get(ctx, client.ObjectKey{Namespace: namespace, Name: gatewayName}, gateway) + if err == nil { + if op == "add" && !isServerExistFromGateway(gateway, isvcName) { + time.Sleep(1 * time.Second) + continue + } else if op == "delete" && isServerExistFromGateway(gateway, isvcName) { + time.Sleep(1 * time.Second) + continue + } + return gateway, nil + } + if !errors.IsNotFound(err) { + continue + } + + if try < maxTries { + time.Sleep(1 * time.Second) + return nil, err + } + } + return gateway, nil +} + +// checks if the server exists for the given gateway +func isServerExistFromGateway(gateway *istioclientv1beta1.Gateway, inferenceServiceName string) bool { + targetServerExist := false + for _, server := range gateway.Spec.Servers { + if server.Port.Name == inferenceServiceName { + targetServerExist = true + break + } + } + return targetServerExist +} diff --git a/controllers/reconcilers/kserve_isvc_gateway_reconciler.go b/controllers/reconcilers/kserve_isvc_gateway_reconciler.go new file mode 100644 index 00000000..b2b86c44 --- /dev/null +++ b/controllers/reconcilers/kserve_isvc_gateway_reconciler.go @@ -0,0 +1,263 @@ +/* + +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 reconcilers + +import ( + "context" + "fmt" + "time" + + "github.com/go-logr/logr" + kservev1beta1 "github.com/kserve/kserve/pkg/apis/serving/v1beta1" + "github.com/opendatahub-io/odh-model-controller/controllers/comparators" + "github.com/opendatahub-io/odh-model-controller/controllers/constants" + "github.com/opendatahub-io/odh-model-controller/controllers/processors" + "github.com/opendatahub-io/odh-model-controller/controllers/resources" + corev1 "k8s.io/api/core/v1" + "k8s.io/apimachinery/pkg/api/errors" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/types" + "sigs.k8s.io/controller-runtime/pkg/client" + + istiov1beta1 "istio.io/api/networking/v1beta1" + istioclientv1beta1 "istio.io/client-go/pkg/apis/networking/v1beta1" +) + +const ( + internalSerivceHostnameDomain = "svc.cluster.local" + opendatahubManagedLabelName = "opendatahub.io/managed='true'" + secretCheckInterval = 1 * time.Second + maxSecretCheckAttempts = 5 +) + +var _ SubResourceReconciler = (*KserveGatewayReconciler)(nil) + +type KserveGatewayReconciler struct { + client client.Client + secretHandler resources.SecretHandler + gatewayHandler resources.GatewayHandler + deltaProcessor processors.DeltaProcessor +} + +func NewKserveGatewayReconciler(client client.Client) *KserveGatewayReconciler { + return &KserveGatewayReconciler{ + client: client, + secretHandler: resources.NewSecretHandler(client), + gatewayHandler: resources.NewGatewayHandler(client), + deltaProcessor: processors.NewDeltaProcessor(), + } +} + +func (r *KserveGatewayReconciler) Reconcile(ctx context.Context, log logr.Logger, isvc *kservev1beta1.InferenceService) error { + log.V(1).Info("Reconciling KServe local gateway for Kserve InferenceService") + + // return if URL is not set + if isvc.Status.URL == nil { + log.V(1).Info("Waiting for the URL as the Inference Service is not ready yet") + return nil + } + + destinationSecretExist := true + if _, err := r.secretHandler.Get(ctx, types.NamespacedName{Name: isvc.Name, Namespace: constants.IstioNamespace}); err != nil { + if errors.IsNotFound(err) { + destinationSecretExist = false + } else { + return err + } + } + + if !destinationSecretExist { + secret := &corev1.Secret{} + for attempt := 1; attempt <= maxSecretCheckAttempts; attempt++ { + getSecretErr := r.client.Get(ctx, types.NamespacedName{Name: isvc.Name, Namespace: isvc.Namespace}, secret) + if getSecretErr == nil { + break + } + if errors.IsNotFound(getSecretErr) { + log.V(2).Info("The certificate secret is not created yet. Retrying...", "attempt_number", attempt) + + time.Sleep(secretCheckInterval) + } else { + log.Error(getSecretErr, "Failed to retrieve the certificate secret for the InferenceService (ISVC)") + return getSecretErr + } + } + if err := r.copyServingCertSecretFromIsvcNamespace(ctx, secret); err != nil { + log.V(1).Error(err, "Failed to update KServe local gateway in the istio-system namespace") + + return nil + } + } + + // Create Desired resource + desiredResource, err := r.createDesiredResource(isvc) + if err != nil { + return err + } + + // Get Existing resource + existingResource, err := r.getExistingResource(ctx) + if err != nil { + if errors.IsNotFound(err) { + log.Error(err, "Failed to find KServe local gateway in istio-system namespace") + } + return err + } + + // Process Delta + if err = r.processDelta(ctx, log, desiredResource, existingResource); err != nil { + return err + } + return nil +} + +func (r *KserveGatewayReconciler) createDesiredResource(isvc *kservev1beta1.InferenceService) (*istioclientv1beta1.Gateway, error) { + hostname := fmt.Sprintf("%s.%s.%s", isvc.Name, isvc.Namespace, internalSerivceHostnameDomain) + + desiredGateway := &istioclientv1beta1.Gateway{ + ObjectMeta: metav1.ObjectMeta{ + Name: "kserve-local-gateway", + Namespace: isvc.Namespace, + }, + Spec: istiov1beta1.Gateway{ + Servers: []*istiov1beta1.Server{ + { + Hosts: []string{hostname}, + Port: &istiov1beta1.Port{ + Name: isvc.Name, + Number: 8445, + Protocol: "HTTPS", + }, + Tls: &istiov1beta1.ServerTLSSettings{ + CredentialName: isvc.Name, + Mode: istiov1beta1.ServerTLSSettings_SIMPLE, + }, + }, + }, + }, + } + + return desiredGateway, nil +} + +func (r *KserveGatewayReconciler) getExistingResource(ctx context.Context) (*istioclientv1beta1.Gateway, error) { + return r.gatewayHandler.Get(ctx, types.NamespacedName{Name: constants.KServeGatewayName, Namespace: constants.IstioNamespace}) +} + +func (r *KserveGatewayReconciler) Delete(ctx context.Context, log logr.Logger, isvc *kservev1beta1.InferenceService) error { + log.V(1).Info(fmt.Sprintf("Deleting serving cert secret(%s) in the namespace(%s)", isvc.Name, isvc.Namespace)) + if err := r.deleteServingCertSecretInIstioNamespace(ctx, isvc.Name); err != nil { + log.V(1).Error(err, "Failed to delete the copied serving cert secret in the namespace") + return err + } + + log.V(1).Info(fmt.Sprintf("Deleting the Server(%s) from KServe local gateway in the istio-system namespace", isvc.Name)) + if err := r.removeServerFromGateway(ctx, log, isvc.Name); err != nil { + log.V(1).Error(err, "Failed to remove the server from KServe local gateway in the istio-system namespace") + return err + } + + return nil +} + +func (r *KserveGatewayReconciler) Cleanup(ctx context.Context, log logr.Logger, isvcName string) error { + // NOOP - Resources should not be deleted until the kserve component is uninstalled. + return nil +} + +func (r *KserveGatewayReconciler) processDelta(ctx context.Context, log logr.Logger, desiredGateway *istioclientv1beta1.Gateway, existingGateway *istioclientv1beta1.Gateway) (err error) { + comparator := comparators.GetGatewayComparator() + delta := r.deltaProcessor.ComputeDelta(comparator, desiredGateway, existingGateway) + + if !delta.HasChanges() { + // Note: This code will not be executed. + return nil + } + if delta.IsAdded() { + // Note: This code will not be executed. + return nil + } + + if delta.IsUpdated() { + log.V(1).Info("Delta found", "update", desiredGateway.GetName()) + gw := existingGateway.DeepCopy() + gw.Spec.Servers = append(existingGateway.Spec.Servers, desiredGateway.Spec.Servers[0]) + + if err = r.gatewayHandler.Update(ctx, gw); err != nil { + log.V(1).Error(err, fmt.Sprintf("Failed to add the Server(%s) from KServe local gateway in the istio-system namespace", desiredGateway.Spec.Servers[0].Port.Name)) + return err + } + + return nil + } + + if delta.IsRemoved() { + // Note: This code will not be executed. + return nil + } + return nil +} + +func (r *KserveGatewayReconciler) removeServerFromGateway(ctx context.Context, log logr.Logger, serverToRemove string) error { + gateway, err := r.gatewayHandler.Get(ctx, types.NamespacedName{Name: constants.KServeGatewayName, Namespace: constants.IstioNamespace}) + if err != nil { + log.V(1).Error(err, "Failed to retrieve KServe local gateway in istio-system namespace") + return err + } + + newServers := []*istiov1beta1.Server{} + for _, server := range gateway.Spec.Servers { + if server.Port.Name != serverToRemove { + newServers = append(newServers, server) + } + } + + gateway.Spec.Servers = newServers + if err := r.gatewayHandler.Update(ctx, gateway); err != nil { + log.V(1).Error(err, "Failed to update KServe local gateway in istio-system namespace") + return err + } + + return nil +} + +func (r *KserveGatewayReconciler) copyServingCertSecretFromIsvcNamespace(ctx context.Context, sourceSecret *corev1.Secret) error { + destinationSecret := &corev1.Secret{ + ObjectMeta: metav1.ObjectMeta{ + Name: sourceSecret.Name, + Namespace: constants.IstioNamespace, + }, + Data: sourceSecret.Data, + Type: sourceSecret.Type, + } + + if err := r.client.Create(ctx, destinationSecret); err != nil { + return err + } + return nil +} + +func (r *KserveGatewayReconciler) deleteServingCertSecretInIstioNamespace(ctx context.Context, targetSecretName string) error { + secret, err := r.secretHandler.Get(ctx, types.NamespacedName{Name: targetSecretName, Namespace: constants.IstioNamespace}) + if err != nil && errors.IsNotFound(err) { + return nil + } + + if err := r.client.Delete(ctx, secret); err != nil { + return err + } + return nil +} diff --git a/controllers/reconcilers/kserve_isvc_service_cert_reconciler.go b/controllers/reconcilers/kserve_isvc_service_cert_reconciler.go index 0116430e..a15d9cf0 100644 --- a/controllers/reconcilers/kserve_isvc_service_cert_reconciler.go +++ b/controllers/reconcilers/kserve_isvc_service_cert_reconciler.go @@ -44,26 +44,26 @@ func NewKserveIsvcServiceReconciler(client client.Client) *KserveIsvcServiceReco } func (r *KserveIsvcServiceReconciler) Delete(ctx context.Context, log logr.Logger, isvc *kservev1beta1.InferenceService) error { - // NOOP - resources are deleted together with ISVCs + // NOOP - Resources are deleted along with the deletion of InferenceServices return nil } func (r *KserveIsvcServiceReconciler) Cleanup(_ context.Context, _ logr.Logger, _ string) error { - // NOOP - resources are deleted together with ISVCs + // NOOP - Resources are deleted along with the deletion of InferenceServices return nil } func (r *KserveIsvcServiceReconciler) Reconcile(ctx context.Context, log logr.Logger, isvc *kservev1beta1.InferenceService) error { - log.V(1).Info("Reconciling ISVC service serving cert for for Kserve InferenceService") + log.V(1).Info("Reconciling InferenceService Service serving cert") // return if URL is not set if isvc.Status.URL == nil { - log.V(1).Info("Inference Service not ready yet, waiting for URL") + log.V(1).Info("Waiting for the URL as the Inference Service is not ready yet", "reconcile", isvc) return nil } // Create Desired resource - desiredResource, err := r.createDesiredResource(isvc, log) + desiredResource, err := r.createDesiredResource(isvc) if err != nil { return err } @@ -81,7 +81,7 @@ func (r *KserveIsvcServiceReconciler) Reconcile(ctx context.Context, log logr.Lo return nil } -func (r *KserveIsvcServiceReconciler) createDesiredResource(isvc *kservev1beta1.InferenceService, log logr.Logger) (*v1.Service, error) { +func (r *KserveIsvcServiceReconciler) createDesiredResource(isvc *kservev1beta1.InferenceService) (*v1.Service, error) { service := &v1.Service{ ObjectMeta: metav1.ObjectMeta{ Name: "isvc-service", @@ -94,12 +94,10 @@ func (r *KserveIsvcServiceReconciler) createDesiredResource(isvc *kservev1beta1. } func (r *KserveIsvcServiceReconciler) getExistingResource(ctx context.Context, log logr.Logger, isvc *kservev1beta1.InferenceService) (*v1.Service, error) { - // log.Info("Fetching existing KServe runtime Service") return r.serviceHandler.FetchWithRetryAndDelay(ctx, log, types.NamespacedName{Name: isvc.Name, Namespace: isvc.Namespace}, 1*time.Second, 10) } func (r *KserveIsvcServiceReconciler) processDelta(ctx context.Context, log logr.Logger, desiredService *v1.Service, existingService *v1.Service) (err error) { - if isUpdated(desiredService, existingService, log) { log.V(1).Info("Delta found", "update", existingService.GetName()) service := existingService.DeepCopy() @@ -111,15 +109,13 @@ func (r *KserveIsvcServiceReconciler) processDelta(ctx context.Context, log logr if err = r.client.Update(ctx, service); err != nil { return err } - - // log.V(1).Info("Add Serving cert annotation to kserve inferenceservice Service object", "update", existingService.GetName()) } return nil } func isUpdated(desiredService *v1.Service, existingService *v1.Service, log logr.Logger) bool { if existingService == nil { - log.Info("Service for a InferenceService is not created yet") + log.Info("The service for the InferenceService has not been created yet") return false } deployedAnnotations := existingService.GetAnnotations() diff --git a/controllers/reconcilers/kserve_serverless_inferenceservice_reconciler.go b/controllers/reconcilers/kserve_serverless_inferenceservice_reconciler.go index 02883c70..c078eb0b 100644 --- a/controllers/reconcilers/kserve_serverless_inferenceservice_reconciler.go +++ b/controllers/reconcilers/kserve_serverless_inferenceservice_reconciler.go @@ -46,6 +46,7 @@ func NewKServeServerlessInferenceServiceReconciler(client client.Client) *Kserve NewKServeNetworkPolicyReconciler(client), NewKserveAuthConfigReconciler(client), NewKserveIsvcServiceReconciler(client), + NewKserveGatewayReconciler(client), } return &KserveServerlessInferenceServiceReconciler{ diff --git a/controllers/resources/gateway.go b/controllers/resources/gateway.go new file mode 100644 index 00000000..95901842 --- /dev/null +++ b/controllers/resources/gateway.go @@ -0,0 +1,55 @@ +/* + +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 resources + +import ( + "context" + "fmt" + + istionetworkclientv1beta1 "istio.io/client-go/pkg/apis/networking/v1beta1" + "k8s.io/apimachinery/pkg/types" + "sigs.k8s.io/controller-runtime/pkg/client" +) + +type GatewayHandler interface { + Get(ctx context.Context, key types.NamespacedName) (*istionetworkclientv1beta1.Gateway, error) + Update(ctx context.Context, gateway *istionetworkclientv1beta1.Gateway) error +} + +type gatewayHandler struct { + client client.Client +} + +func NewGatewayHandler(client client.Client) GatewayHandler { + return &gatewayHandler{ + client: client, + } +} + +func (g *gatewayHandler) Get(ctx context.Context, key types.NamespacedName) (*istionetworkclientv1beta1.Gateway, error) { + gateway := &istionetworkclientv1beta1.Gateway{} + if err := g.client.Get(ctx, key, gateway); err != nil { + return nil, err + } + return gateway, nil +} + +func (g *gatewayHandler) Update(ctx context.Context, gateway *istionetworkclientv1beta1.Gateway) error { + if err := g.client.Update(ctx, gateway); err != nil { + return fmt.Errorf("could not UPDATE gateway %s/%s. cause %w", gateway.Namespace, gateway.Name, err) + } + return nil +} diff --git a/controllers/resources/secret.go b/controllers/resources/secret.go new file mode 100644 index 00000000..224e6cb6 --- /dev/null +++ b/controllers/resources/secret.go @@ -0,0 +1,47 @@ +/* + +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 resources + +import ( + "context" + + v1 "k8s.io/api/core/v1" + "k8s.io/apimachinery/pkg/types" + "sigs.k8s.io/controller-runtime/pkg/client" +) + +type SecretHandler interface { + Get(ctx context.Context, key types.NamespacedName) (*v1.Secret, error) +} + +type secretHandler struct { + client client.Client +} + +func NewSecretHandler(client client.Client) SecretHandler { + return &secretHandler{ + client: client, + } +} + +func (s *secretHandler) Get(ctx context.Context, key types.NamespacedName) (*v1.Secret, error) { + secret := &v1.Secret{} + if err := s.client.Get(ctx, key, secret); err != nil { + return nil, err + } + + return secret, nil +} diff --git a/controllers/resources/service.go b/controllers/resources/service.go index 411efbc6..544a55b5 100644 --- a/controllers/resources/service.go +++ b/controllers/resources/service.go @@ -63,18 +63,17 @@ func (r *serviceHandler) FetchWithRetryAndDelay(ctx context.Context, log logr.Lo svc, err = r.FetchService(ctx, log, key) if err != nil { if svc == nil || errors.IsNotFound(err) { - log.Info(fmt.Sprintf("Service is not created yet, attempt %d", attempt)) + log.Info(fmt.Sprintf("Service not found. Retrying(%d)..", attempt)) time.Sleep(retryDelay) continue } else { return nil, err } } + break } - if svc != nil { - log.Info("Successfully fetched the Service") - } else { + if svc == nil { log.Info(fmt.Sprintf("Failed to fetch the Service(%s) after retries(%d)", key.Name, retry)) } return svc, nil diff --git a/controllers/suite_test.go b/controllers/suite_test.go index 39659627..397e7bf1 100644 --- a/controllers/suite_test.go +++ b/controllers/suite_test.go @@ -17,15 +17,16 @@ package controllers import ( "context" - "k8s.io/apimachinery/pkg/apis/meta/v1/unstructured" - utilruntime "k8s.io/apimachinery/pkg/util/runtime" "math/rand" "os" "path/filepath" - "sigs.k8s.io/controller-runtime/pkg/metrics/server" "testing" "time" + "k8s.io/apimachinery/pkg/apis/meta/v1/unstructured" + utilruntime "k8s.io/apimachinery/pkg/util/runtime" + "sigs.k8s.io/controller-runtime/pkg/metrics/server" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" kservev1alpha1 "github.com/kserve/kserve/pkg/apis/serving/v1alpha1" @@ -40,6 +41,7 @@ import ( . "github.com/onsi/ginkgo" . "github.com/onsi/gomega" routev1 "github.com/openshift/api/route/v1" + istioclientv1beta1 "istio.io/client-go/pkg/apis/networking/v1beta1" corev1 "k8s.io/api/core/v1" "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/controller-runtime/pkg/envtest" @@ -124,6 +126,7 @@ var _ = BeforeSuite(func() { testScheme := runtime.NewScheme() utils.RegisterSchemes(testScheme) utilruntime.Must(authorinov1beta2.AddToScheme(testScheme)) + utilruntime.Must(istioclientv1beta1.AddToScheme(testScheme)) // +kubebuilder:scaffold:scheme @@ -204,6 +207,7 @@ var _ = AfterSuite(func() { var _ = AfterEach(func() { cleanUp := func(namespace string, cli client.Client) { inNamespace := client.InNamespace(namespace) + istioNamespace := client.InNamespace(constants.IstioNamespace) Expect(cli.DeleteAllOf(context.TODO(), &kservev1alpha1.ServingRuntime{}, inNamespace)).ToNot(HaveOccurred()) Expect(cli.DeleteAllOf(context.TODO(), &kservev1beta1.InferenceService{}, inNamespace)).ToNot(HaveOccurred()) Expect(cli.DeleteAllOf(context.TODO(), &routev1.Route{}, inNamespace)).ToNot(HaveOccurred()) @@ -213,6 +217,7 @@ var _ = AfterEach(func() { Expect(cli.DeleteAllOf(context.TODO(), &authorinov1beta2.AuthConfig{}, inNamespace)).ToNot(HaveOccurred()) Expect(cli.DeleteAllOf(context.TODO(), &corev1.ConfigMap{}, inNamespace)).ToNot(HaveOccurred()) Expect(cli.DeleteAllOf(context.TODO(), &corev1.Service{}, inNamespace)).ToNot(HaveOccurred()) + Expect(cli.DeleteAllOf(context.TODO(), &istioclientv1beta1.Gateway{}, istioNamespace)).ToNot(HaveOccurred()) } cleanUp(WorkingNamespace, cli) for _, ns := range Namespaces.All() { diff --git a/controllers/testdata/gateway/kserve-local-gateway.yaml b/controllers/testdata/gateway/kserve-local-gateway.yaml new file mode 100644 index 00000000..149e9bd6 --- /dev/null +++ b/controllers/testdata/gateway/kserve-local-gateway.yaml @@ -0,0 +1,15 @@ +apiVersion: networking.istio.io/v1beta1 +kind: Gateway +metadata: + name: kserve-local-gateway + namespace: istio-system +spec: + selector: + knative: ingressgateway + servers: + - hosts: + - 'demo.default.svc.cluster.local' + port: + name: http + number: 8080 + protocol: HTTP diff --git a/controllers/testdata/gateway/test-isvc-svc-secret.yaml b/controllers/testdata/gateway/test-isvc-svc-secret.yaml new file mode 100644 index 00000000..a13660db --- /dev/null +++ b/controllers/testdata/gateway/test-isvc-svc-secret.yaml @@ -0,0 +1,19 @@ +apiVersion: v1 +data: + tls.crt: dGxzLmNydAo= + tls.key: dGxzLmtleQo= +kind: Secret +metadata: + annotations: + openshift.io/description: 'Secret contains a pair signed serving certificate/key + that is generated by Service CA operator for service/example-onnx-mnist with + hostname example-onnx-mnist.default.svc and is annotated to the service with + annotating a service resource with ''service.beta.openshift.io/serving-cert-secret-name: + example-onnx-mnist''. The certificate is valid for 2 years.' + openshift.io/owning-component: service-ca + service.alpha.openshift.io/expiry: "2026-06-11T17:58:35Z" + service.beta.openshift.io/expiry: "2026-06-11T17:58:35Z" + service.beta.openshift.io/originating-service-name: example-onnx-mnist + name: example-onnx-mnist + namespace: default +type: kubernetes.io/tls diff --git a/controllers/utils/init.go b/controllers/utils/init.go index d6127515..6f803f1f 100644 --- a/controllers/utils/init.go +++ b/controllers/utils/init.go @@ -6,6 +6,7 @@ import ( authorinov1beta2 "github.com/kuadrant/authorino/api/v1beta2" routev1 "github.com/openshift/api/route/v1" monitoringv1 "github.com/prometheus-operator/prometheus-operator/pkg/apis/monitoring/v1" + istioclientv1beta1 "istio.io/client-go/pkg/apis/networking/v1beta1" istiosecurityv1beta1 "istio.io/client-go/pkg/apis/security/v1beta1" telemetryv1alpha1 "istio.io/client-go/pkg/apis/telemetry/v1alpha1" corev1 "k8s.io/api/core/v1" @@ -34,6 +35,7 @@ func RegisterSchemes(s *runtime.Scheme) { utilruntime.Must(maistrav1.SchemeBuilder.AddToScheme(s)) utilruntime.Must(knservingv1.AddToScheme(s)) utilruntime.Must(authorinov1beta2.SchemeBuilder.AddToScheme(s)) + utilruntime.Must(istioclientv1beta1.AddToScheme(s)) // The following are related to Service Mesh, uncomment this and other // similar blocks to use with Service Mesh diff --git a/main.go b/main.go index 05cecbe1..3112fdea 100644 --- a/main.go +++ b/main.go @@ -59,6 +59,8 @@ func init() { //nolint:gochecknoinits //reason this way we ensure schemes are al // +kubebuilder:rbac:groups=serving.kserve.io,resources=servingruntimes/finalizers,verbs=get;list;watch;create;update;patch;delete // +kubebuilder:rbac:groups=networking.istio.io,resources=virtualservices,verbs=get;list;watch;create;update;patch;delete // +kubebuilder:rbac:groups=networking.istio.io,resources=virtualservices/finalizers,verbs=get;list;watch;create;update;patch;delete +// +kubebuilder:rbac:groups=networking.istio.io,resources=gateways,verbs=get;list;watch;create;update;patch;delete +// +kubebuilder:rbac:groups=networking.istio.io,resources=gateways/finalizers,verbs=get;list;watch;create;update;patch;delete // +kubebuilder:rbac:groups=security.istio.io,resources=peerauthentications,verbs=get;list;watch;create;update;patch;delete // +kubebuilder:rbac:groups=security.istio.io,resources=authorizationpolicies,verbs=get;list // +kubebuilder:rbac:groups=telemetry.istio.io,resources=telemetries,verbs=get;list;watch;create;update;patch;delete From 74d153a964b1b8ff78c371d4a0415029baa6aee9 Mon Sep 17 00:00:00 2001 From: jooho lee Date: Fri, 14 Jun 2024 14:03:42 -0400 Subject: [PATCH 03/13] fix merging conflict with the latest main branch Signed-off-by: jooho lee --- controllers/kserve_inferenceservice_controller_test.go | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/controllers/kserve_inferenceservice_controller_test.go b/controllers/kserve_inferenceservice_controller_test.go index e1be1c05..f5f79428 100644 --- a/controllers/kserve_inferenceservice_controller_test.go +++ b/controllers/kserve_inferenceservice_controller_test.go @@ -220,14 +220,8 @@ var _ = Describe("The Openshift Kserve model controller", func() { BeforeEach(func() { ctx := context.Background() - testNs = Namespaces.Get() - testNamespace := &corev1.Namespace{ - ObjectMeta: metav1.ObjectMeta{ - Name: testNs, - Namespace: testNs, - }, - } - Expect(cli.Create(ctx, testNamespace)).Should(Succeed()) + testNamespace := Namespaces.Create(cli) + testNs = testNamespace.Name inferenceServiceConfig := &corev1.ConfigMap{} Expect(convertToStructuredResource(InferenceServiceConfigPath1, inferenceServiceConfig)).To(Succeed()) From 5543c65cf8b66c47f76f003e55c79129b32c8b7d Mon Sep 17 00:00:00 2001 From: jooho lee Date: Fri, 14 Jun 2024 15:50:31 -0400 Subject: [PATCH 04/13] minor change based on the comments Signed-off-by: jooho lee --- .../reconcilers/kserve_isvc_gateway_reconciler.go | 12 ++++++------ .../kserve_isvc_service_cert_reconciler.go | 2 +- controllers/resources/service.go | 7 ++++--- controllers/utils/init.go | 2 +- 4 files changed, 12 insertions(+), 11 deletions(-) diff --git a/controllers/reconcilers/kserve_isvc_gateway_reconciler.go b/controllers/reconcilers/kserve_isvc_gateway_reconciler.go index b2b86c44..798652b0 100644 --- a/controllers/reconcilers/kserve_isvc_gateway_reconciler.go +++ b/controllers/reconcilers/kserve_isvc_gateway_reconciler.go @@ -88,17 +88,16 @@ func (r *KserveGatewayReconciler) Reconcile(ctx context.Context, log logr.Logger } if errors.IsNotFound(getSecretErr) { log.V(2).Info("The certificate secret is not created yet. Retrying...", "attempt_number", attempt) - time.Sleep(secretCheckInterval) } else { log.Error(getSecretErr, "Failed to retrieve the certificate secret for the InferenceService (ISVC)") return getSecretErr } } - if err := r.copyServingCertSecretFromIsvcNamespace(ctx, secret); err != nil { - log.V(1).Error(err, "Failed to update KServe local gateway in the istio-system namespace") - return nil + if err := r.copyServingCertSecretFromIsvcNamespace(ctx, secret, isvc); err != nil { + log.V(1).Error(err, "Failed to copy the Secret for InferenceService in the istio-system namespace") + return err } } @@ -129,7 +128,7 @@ func (r *KserveGatewayReconciler) createDesiredResource(isvc *kservev1beta1.Infe desiredGateway := &istioclientv1beta1.Gateway{ ObjectMeta: metav1.ObjectMeta{ - Name: "kserve-local-gateway", + Name: constants.KServeGatewayName, Namespace: isvc.Namespace, }, Spec: istiov1beta1.Gateway{ @@ -234,7 +233,8 @@ func (r *KserveGatewayReconciler) removeServerFromGateway(ctx context.Context, l return nil } -func (r *KserveGatewayReconciler) copyServingCertSecretFromIsvcNamespace(ctx context.Context, sourceSecret *corev1.Secret) error { +func (r *KserveGatewayReconciler) copyServingCertSecretFromIsvcNamespace(ctx context.Context, sourceSecret *corev1.Secret, isvc *kservev1beta1.InferenceService) error { + destinationSecret := &corev1.Secret{ ObjectMeta: metav1.ObjectMeta{ Name: sourceSecret.Name, diff --git a/controllers/reconcilers/kserve_isvc_service_cert_reconciler.go b/controllers/reconcilers/kserve_isvc_service_cert_reconciler.go index a15d9cf0..f17fa0e4 100644 --- a/controllers/reconcilers/kserve_isvc_service_cert_reconciler.go +++ b/controllers/reconcilers/kserve_isvc_service_cert_reconciler.go @@ -94,7 +94,7 @@ func (r *KserveIsvcServiceReconciler) createDesiredResource(isvc *kservev1beta1. } func (r *KserveIsvcServiceReconciler) getExistingResource(ctx context.Context, log logr.Logger, isvc *kservev1beta1.InferenceService) (*v1.Service, error) { - return r.serviceHandler.FetchWithRetryAndDelay(ctx, log, types.NamespacedName{Name: isvc.Name, Namespace: isvc.Namespace}, 1*time.Second, 10) + return r.serviceHandler.FetchServiceWithRetryAndDelay(ctx, log, types.NamespacedName{Name: isvc.Name, Namespace: isvc.Namespace}, 1*time.Second, 10) } func (r *KserveIsvcServiceReconciler) processDelta(ctx context.Context, log logr.Logger, desiredService *v1.Service, existingService *v1.Service) (err error) { diff --git a/controllers/resources/service.go b/controllers/resources/service.go index 544a55b5..3da490ae 100644 --- a/controllers/resources/service.go +++ b/controllers/resources/service.go @@ -29,7 +29,7 @@ import ( type ServiceHandler interface { FetchService(ctx context.Context, log logr.Logger, key types.NamespacedName) (*v1.Service, error) - FetchWithRetryAndDelay(ctx context.Context, log logr.Logger, key types.NamespacedName, retryDelay time.Duration, retry int) (*v1.Service, error) + FetchServiceWithRetryAndDelay(ctx context.Context, log logr.Logger, key types.NamespacedName, retryDelay time.Duration, retry int) (*v1.Service, error) } type serviceHandler struct { @@ -55,7 +55,7 @@ func (r *serviceHandler) FetchService(ctx context.Context, log logr.Logger, key return svc, nil } -func (r *serviceHandler) FetchWithRetryAndDelay(ctx context.Context, log logr.Logger, key types.NamespacedName, retryDelay time.Duration, retry int) (*v1.Service, error) { +func (r *serviceHandler) FetchServiceWithRetryAndDelay(ctx context.Context, log logr.Logger, key types.NamespacedName, retryDelay time.Duration, retry int) (*v1.Service, error) { var svc *v1.Service var err error @@ -74,7 +74,8 @@ func (r *serviceHandler) FetchWithRetryAndDelay(ctx context.Context, log logr.Lo } if svc == nil { - log.Info(fmt.Sprintf("Failed to fetch the Service(%s) after retries(%d)", key.Name, retry)) + log.Error(err, fmt.Sprintf("Failed to fetch the Service(%s) after retries(%d)", key.Name, retry)) + return nil, err } return svc, nil } diff --git a/controllers/utils/init.go b/controllers/utils/init.go index 6f803f1f..75a708e0 100644 --- a/controllers/utils/init.go +++ b/controllers/utils/init.go @@ -35,7 +35,7 @@ func RegisterSchemes(s *runtime.Scheme) { utilruntime.Must(maistrav1.SchemeBuilder.AddToScheme(s)) utilruntime.Must(knservingv1.AddToScheme(s)) utilruntime.Must(authorinov1beta2.SchemeBuilder.AddToScheme(s)) - utilruntime.Must(istioclientv1beta1.AddToScheme(s)) + utilruntime.Must(istioclientv1beta1.SchemeBuilder.AddToScheme(s)) // The following are related to Service Mesh, uncomment this and other // similar blocks to use with Service Mesh From c0062aa1c061b8c382a78ba2ef1b61a91723308f Mon Sep 17 00:00:00 2001 From: jooho lee Date: Wed, 19 Jun 2024 09:27:59 -0400 Subject: [PATCH 05/13] follow up more comments Signed-off-by: jooho lee --- config/rbac/role.yaml | 14 - config/webhook/manifests.yaml | 25 ++ controllers/comparators/gateway_comparator.go | 2 +- controllers/inferenceservice_controller.go | 35 ++ ...kserve_inferenceservice_controller_test.go | 130 ++++--- .../kserve_isvc_gateway_reconciler.go | 119 +++--- .../kserve_isvc_service_cert_reconciler.go | 47 ++- controllers/resources/service.go | 28 -- controllers/webhook/kserve_service_mutator.go | 61 +++ .../webhook_kserve_service_mutator_test.go | 62 +++ go.mod | 13 + go.sum | 358 ++++++++++++++++++ main.go | 19 +- 13 files changed, 731 insertions(+), 182 deletions(-) create mode 100644 controllers/webhook/kserve_service_mutator.go create mode 100644 controllers/webhook_kserve_service_mutator_test.go diff --git a/config/rbac/role.yaml b/config/rbac/role.yaml index 93592028..67414f16 100644 --- a/config/rbac/role.yaml +++ b/config/rbac/role.yaml @@ -127,20 +127,6 @@ rules: resources: - gateways verbs: - - create - - delete - - get - - list - - patch - - update - - watch -- apiGroups: - - networking.istio.io - resources: - - gateways/finalizers - verbs: - - create - - delete - get - list - patch diff --git a/config/webhook/manifests.yaml b/config/webhook/manifests.yaml index 26d90b5f..01d11ca7 100644 --- a/config/webhook/manifests.yaml +++ b/config/webhook/manifests.yaml @@ -1,5 +1,30 @@ --- apiVersion: admissionregistration.k8s.io/v1 +kind: MutatingWebhookConfiguration +metadata: + name: mutating-webhook-configuration +webhooks: +- admissionReviewVersions: + - v1 + clientConfig: + service: + name: webhook-service + namespace: system + path: /mutate-serving-kserve-service + failurePolicy: Fail + name: mutating.kserve-service.odh-model-controller.opendatahub.io + rules: + - apiGroups: + - "" + apiVersions: + - v1 + operations: + - CREATE + resources: + - services + sideEffects: None +--- +apiVersion: admissionregistration.k8s.io/v1 kind: ValidatingWebhookConfiguration metadata: name: validating-webhook-configuration diff --git a/controllers/comparators/gateway_comparator.go b/controllers/comparators/gateway_comparator.go index cdbf68fb..2548b474 100644 --- a/controllers/comparators/gateway_comparator.go +++ b/controllers/comparators/gateway_comparator.go @@ -38,7 +38,7 @@ func GetGatewayComparator() ResourceComparator { } } -// Function to compare two Server objects +// serversEquals compare if the inferenceservice name matches got the given resources func serversEqual(s1, s2 *istiov1beta1.Server) bool { return s1.Port.Name == s2.Port.Name } diff --git a/controllers/inferenceservice_controller.go b/controllers/inferenceservice_controller.go index 3e6e98db..29f03953 100644 --- a/controllers/inferenceservice_controller.go +++ b/controllers/inferenceservice_controller.go @@ -17,6 +17,7 @@ package controllers import ( "context" + "github.com/go-logr/logr" kservev1alpha1 "github.com/kserve/kserve/pkg/apis/serving/v1alpha1" kservev1beta1 "github.com/kserve/kserve/pkg/apis/serving/v1beta1" @@ -147,6 +148,40 @@ func (r *OpenshiftInferenceServiceReconciler) SetupWithManager(mgr ctrl.Manager) }) } return reconcileRequests + })). + Watches(&corev1.Service{}, + handler.EnqueueRequestsFromMapFunc(func(ctx context.Context, o client.Object) []reconcile.Request { + r.log.Info("Reconcile event triggered by Service: " + o.GetName()) + isvc := &kservev1beta1.InferenceService{} + err := r.client.Get(ctx, types.NamespacedName{Name: o.GetName(), Namespace: o.GetNamespace()}, isvc) + if err != nil { + if apierrs.IsNotFound(err) { + return []reconcile.Request{} + } + r.log.Error(err, "Error getting the inferenceService", "name", o.GetName()) + return []reconcile.Request{} + } + + return []reconcile.Request{ + {NamespacedName: types.NamespacedName{Name: o.GetName(), Namespace: o.GetNamespace()}}, + } + })). + Watches(&corev1.Secret{}, + handler.EnqueueRequestsFromMapFunc(func(ctx context.Context, o client.Object) []reconcile.Request { + r.log.Info("Reconcile event triggered by Secret: " + o.GetName()) + isvc := &kservev1beta1.InferenceService{} + err := r.client.Get(ctx, types.NamespacedName{Name: o.GetName(), Namespace: o.GetNamespace()}, isvc) + if err != nil { + if apierrs.IsNotFound(err) { + return []reconcile.Request{} + } + r.log.Error(err, "Error getting the inferenceService", "name", o.GetName()) + return []reconcile.Request{} + } + + return []reconcile.Request{ + {NamespacedName: types.NamespacedName{Name: o.GetName(), Namespace: o.GetNamespace()}}, + } })) kserveWithMeshEnabled, kserveWithMeshEnabledErr := utils.VerifyIfComponentIsEnabled(context.Background(), mgr.GetClient(), utils.KServeWithServiceMeshComponent) diff --git a/controllers/kserve_inferenceservice_controller_test.go b/controllers/kserve_inferenceservice_controller_test.go index f5f79428..29634568 100644 --- a/controllers/kserve_inferenceservice_controller_test.go +++ b/controllers/kserve_inferenceservice_controller_test.go @@ -35,6 +35,7 @@ import ( "k8s.io/apimachinery/pkg/api/errors" "k8s.io/apimachinery/pkg/types" "knative.dev/pkg/apis" + duckv1 "knative.dev/pkg/apis/duck/v1" "sigs.k8s.io/controller-runtime/pkg/client" ) @@ -103,46 +104,67 @@ var _ = Describe("The Openshift Kserve model controller", func() { }, timeout, interval).Should(Succeed()) }) - It("With a new Kserve InferenceService, serving cert annotation should be added to the runtime Service object.", func() { - // Create a new InferenceService - inferenceService := &kservev1beta1.InferenceService{} - err := convertToStructuredResource(KserveInferenceServicePath1, inferenceService) - Expect(err).NotTo(HaveOccurred()) - inferenceService.SetNamespace(testNs) - Expect(cli.Create(ctx, inferenceService)).Should(Succeed()) - - // Stub: Create a Runtime Service, which must be created by the OpenDataHub operator. - svc := &corev1.Service{} - err = convertToStructuredResource(testIsvcSvcPath, svc) - Expect(err).NotTo(HaveOccurred()) - svc.SetNamespace(inferenceService.Namespace) - Expect(cli.Create(ctx, svc)).Should(Succeed()) - - // Update the URL of the InferenceService to indicate it is ready. - deployedInferenceService := &kservev1beta1.InferenceService{} - err = cli.Get(ctx, types.NamespacedName{Name: inferenceService.Name, Namespace: inferenceService.Namespace}, deployedInferenceService) - Expect(err).NotTo(HaveOccurred()) - - url, err := apis.ParseURL("https://example-onnx-mnist-default.test.com") - Expect(err).NotTo(HaveOccurred()) - deployedInferenceService.Status.URL = url - - err = cli.Status().Update(ctx, deployedInferenceService) - Expect(err).NotTo(HaveOccurred()) - - isvcService, err := waitForService(cli, testNs, inferenceService.Name, 5, 2*time.Second) - Expect(err).NotTo(HaveOccurred()) - - Expect(isvcService.Annotations[constants.ServingCertAnnotationKey]).Should(Equal(inferenceService.Name)) - }) + // It("With a new Kserve InferenceService, serving cert annotation should be added to the runtime Service object.", func() { + // // We need to stub the cluster state and indicate where is istio namespace (reusing authConfig test data) + // if dsciErr := createDSCI(DSCIWithoutAuthorization); dsciErr != nil && !errors.IsAlreadyExists(dsciErr) { + // Fail(dsciErr.Error()) + // } + // // Create a new InferenceService + // inferenceService := &kservev1beta1.InferenceService{} + // err := convertToStructuredResource(KserveInferenceServicePath1, inferenceService) + // Expect(err).NotTo(HaveOccurred()) + // inferenceService.SetNamespace(testNs) + // Expect(cli.Create(ctx, inferenceService)).Should(Succeed()) + + // // Update the URL of the InferenceService to indicate it is ready. + // deployedInferenceService := &kservev1beta1.InferenceService{} + // err = cli.Get(ctx, types.NamespacedName{Name: inferenceService.Name, Namespace: inferenceService.Namespace}, deployedInferenceService) + // Expect(err).NotTo(HaveOccurred()) + + // // url, err := apis.ParseURL("https://example-onnx-mnist-default.test.com") + // Expect(err).NotTo(HaveOccurred()) + // newAddress := &duckv1.Addressable{ + // URL: apis.HTTPS("example-onnx-mnist-default.test.com"), + // } + // deployedInferenceService.Status.Address = newAddress + + // err = cli.Status().Update(ctx, deployedInferenceService) + // Expect(err).NotTo(HaveOccurred()) + + // // Stub: Create a Kserve Service, which must be created by the KServe operator. + // svc := &corev1.Service{} + // err = convertToStructuredResource(testIsvcSvcPath, svc) + // Expect(err).NotTo(HaveOccurred()) + // svc.SetNamespace(inferenceService.Namespace) + // Expect(cli.Create(ctx, svc)).Should(Succeed()) + + // err = cli.Status().Update(ctx, deployedInferenceService) + // Expect(err).NotTo(HaveOccurred()) + + // isvcService, err := waitForService(cli, testNs, inferenceService.Name, 5, 2*time.Second) + // Expect(err).NotTo(HaveOccurred()) + + // Expect(isvcService.Annotations[constants.ServingCertAnnotationKey]).Should(Equal(inferenceService.Name)) + // }) It("should create a secret for runtime and update kserve local gateway in the istio-system namespace", func() { + // We need to stub the cluster state and indicate where is istio namespace (reusing authConfig test data) + if dsciErr := createDSCI(DSCIWithoutAuthorization); dsciErr != nil && !errors.IsAlreadyExists(dsciErr) { + Fail(dsciErr.Error()) + } // Stub: Create a kserve-local-gateway, which must be created by the OpenDataHub operator. kserveLocalGateway := &istioclientv1beta1.Gateway{} err := convertToStructuredResource(kserveLocalGatewayPath, kserveLocalGateway) Expect(err).NotTo(HaveOccurred()) Expect(cli.Create(ctx, kserveLocalGateway)).Should(Succeed()) + // Stub: Create a certificate Secret, which must be created by the openshift service-ca operator. + secret := &corev1.Secret{} + err = convertToStructuredResource(testIsvcSvcSecretPath, secret) + Expect(err).NotTo(HaveOccurred()) + secret.SetNamespace(testNs) + Expect(cli.Create(ctx, secret)).Should(Succeed()) + // Create a new InferenceService inferenceService := &kservev1beta1.InferenceService{} err = convertToStructuredResource(KserveInferenceServicePath1, inferenceService) @@ -156,24 +178,14 @@ var _ = Describe("The Openshift Kserve model controller", func() { err = cli.Get(ctx, types.NamespacedName{Name: inferenceService.Name, Namespace: inferenceService.Namespace}, deployedInferenceService) Expect(err).NotTo(HaveOccurred()) - url, err := apis.ParseURL("https://example-onnx-mnist-default.test.com") - Expect(err).NotTo(HaveOccurred()) - deployedInferenceService.Status.URL = url + newAddress := &duckv1.Addressable{ + URL: apis.HTTPS("example-onnx-mnist-default.test.com"), + } + deployedInferenceService.Status.Address = newAddress err = cli.Status().Update(ctx, deployedInferenceService) Expect(err).NotTo(HaveOccurred()) - // Stub: Create a certificate Secret, which must be created by the openshift service-ca operator. - secret := &corev1.Secret{} - err = convertToStructuredResource(testIsvcSvcSecretPath, secret) - Expect(err).NotTo(HaveOccurred()) - secret.SetNamespace(inferenceService.Namespace) - Expect(cli.Create(ctx, secret)).Should(Succeed()) - - // Verify that the certificate secret is found in the same namespace where the InferenceService is created. - _, err = waitForSecret(cli, inferenceService.Namespace, inferenceService.Name, 5, 1*time.Second) - Expect(err).NotTo(HaveOccurred()) - // Verify that the certificate secret is created in the istio-system namespace. _, err = waitForSecret(cli, constants.IstioNamespace, inferenceService.Name, 5, 5*time.Second) Expect(err).NotTo(HaveOccurred()) @@ -229,6 +241,11 @@ var _ = Describe("The Openshift Kserve model controller", func() { Fail(err.Error()) } + // We need to stub the cluster state and indicate where is istio namespace (reusing authConfig test data) + if dsciErr := createDSCI(DSCIWithoutAuthorization); dsciErr != nil && !errors.IsAlreadyExists(dsciErr) { + Fail(dsciErr.Error()) + } + servingRuntime := &kservev1alpha1.ServingRuntime{} Expect(convertToStructuredResource(KserveServingRuntimePath1, servingRuntime)).To(Succeed()) if err := cli.Create(ctx, servingRuntime); err != nil && !errors.IsAlreadyExists(err) { @@ -242,6 +259,13 @@ var _ = Describe("The Openshift Kserve model controller", func() { Expect(cli.Create(ctx, kserveLocalGateway)).Should(Succeed()) + // Stub: Create a certificate Secret, which must be created by the openshift service-ca operator. + secret := &corev1.Secret{} + err = convertToStructuredResource(testIsvcSvcSecretPath, secret) + Expect(err).NotTo(HaveOccurred()) + secret.SetNamespace(testNs) + Expect(cli.Create(ctx, secret)).Should(Succeed()) + // Create a new InferenceService inferenceService := &kservev1beta1.InferenceService{} err = convertToStructuredResource(KserveInferenceServicePath1, inferenceService) @@ -258,20 +282,14 @@ var _ = Describe("The Openshift Kserve model controller", func() { err = cli.Get(ctx, types.NamespacedName{Name: inferenceService.Name, Namespace: testNs}, deployedInferenceService) Expect(err).NotTo(HaveOccurred()) - url, err := apis.ParseURL("https://example-onnx-mnist-default.test.com") - Expect(err).NotTo(HaveOccurred()) - deployedInferenceService.Status.URL = url + newAddress := &duckv1.Addressable{ + URL: apis.HTTPS("example-onnx-mnist-default.test.com"), + } + deployedInferenceService.Status.Address = newAddress err = cli.Status().Update(ctx, deployedInferenceService) Expect(err).NotTo(HaveOccurred()) - // Stub: Create a certificate Secret, which must be created by the openshift service-ca operator. - secret := &corev1.Secret{} - err = convertToStructuredResource(testIsvcSvcSecretPath, secret) - Expect(err).NotTo(HaveOccurred()) - secret.SetNamespace(testNs) - Expect(cli.Create(ctx, secret)).Should(Succeed()) - // Verify that the certificate secret is created in the istio-system namespace. _, err = waitForSecret(cli, constants.IstioNamespace, inferenceService.Name, 5, 2*time.Second) Expect(err).NotTo(HaveOccurred()) diff --git a/controllers/reconcilers/kserve_isvc_gateway_reconciler.go b/controllers/reconcilers/kserve_isvc_gateway_reconciler.go index 798652b0..7a9688a0 100644 --- a/controllers/reconcilers/kserve_isvc_gateway_reconciler.go +++ b/controllers/reconcilers/kserve_isvc_gateway_reconciler.go @@ -18,7 +18,6 @@ package reconcilers import ( "context" "fmt" - "time" "github.com/go-logr/logr" kservev1beta1 "github.com/kserve/kserve/pkg/apis/serving/v1beta1" @@ -26,6 +25,7 @@ import ( "github.com/opendatahub-io/odh-model-controller/controllers/constants" "github.com/opendatahub-io/odh-model-controller/controllers/processors" "github.com/opendatahub-io/odh-model-controller/controllers/resources" + "github.com/opendatahub-io/odh-model-controller/controllers/utils" corev1 "k8s.io/api/core/v1" "k8s.io/apimachinery/pkg/api/errors" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" @@ -36,14 +36,15 @@ import ( istioclientv1beta1 "istio.io/client-go/pkg/apis/networking/v1beta1" ) -const ( - internalSerivceHostnameDomain = "svc.cluster.local" - opendatahubManagedLabelName = "opendatahub.io/managed='true'" - secretCheckInterval = 1 * time.Second - maxSecretCheckAttempts = 5 -) +// const ( +// internalSerivceHostnameDomain = "svc.cluster.local" +// opendatahubManagedLabelName = "opendatahub.io/managed='true'" +// secretCheckInterval = 1 * time.Second +// maxSecretCheckAttempts = 5 +// ) var _ SubResourceReconciler = (*KserveGatewayReconciler)(nil) +var meshNamespace string type KserveGatewayReconciler struct { client client.Client @@ -63,46 +64,66 @@ func NewKserveGatewayReconciler(client client.Client) *KserveGatewayReconciler { func (r *KserveGatewayReconciler) Reconcile(ctx context.Context, log logr.Logger, isvc *kservev1beta1.InferenceService) error { log.V(1).Info("Reconciling KServe local gateway for Kserve InferenceService") + _, meshNamespace = utils.GetIstioControlPlaneName(ctx, r.client) + log.V(1).Info("AAAAA1", "meshNamespace", meshNamespace) + log.V(1).Info("AAAAA2", "isvc", isvc) - // return if URL is not set - if isvc.Status.URL == nil { + // return if Address.URL is not set + if isvc.Status.Address == nil { log.V(1).Info("Waiting for the URL as the Inference Service is not ready yet") return nil } - destinationSecretExist := true - if _, err := r.secretHandler.Get(ctx, types.NamespacedName{Name: isvc.Name, Namespace: constants.IstioNamespace}); err != nil { + // return if serving cert secret in the destination namespace is not created + certSecret, err := r.secretHandler.Get(ctx, types.NamespacedName{Name: isvc.Name, Namespace: isvc.Namespace}) + if err != nil { if errors.IsNotFound(err) { - destinationSecretExist = false - } else { - return err + log.V(1).Info("Waiting for creating serving cert secret in the inference service namespace") + return nil } + return err } - - if !destinationSecretExist { - secret := &corev1.Secret{} - for attempt := 1; attempt <= maxSecretCheckAttempts; attempt++ { - getSecretErr := r.client.Get(ctx, types.NamespacedName{Name: isvc.Name, Namespace: isvc.Namespace}, secret) - if getSecretErr == nil { - break - } - if errors.IsNotFound(getSecretErr) { - log.V(2).Info("The certificate secret is not created yet. Retrying...", "attempt_number", attempt) - time.Sleep(secretCheckInterval) - } else { - log.Error(getSecretErr, "Failed to retrieve the certificate secret for the InferenceService (ISVC)") - return getSecretErr + // return if serving cert secret in the destination namespace is not created + _, err = r.secretHandler.Get(ctx, types.NamespacedName{Name: isvc.Name, Namespace: meshNamespace}) + if err != nil { + if errors.IsNotFound(err) { + if err := r.copyServingCertSecretFromIsvcNamespace(ctx, certSecret, isvc); err != nil { + log.V(1).Error(err, "Failed to copy the Secret for InferenceService in the istio-system namespace") + return err } + log.V(1).Info("Waiting for creating serving cert secret in the inference service namespace") + return nil } - - if err := r.copyServingCertSecretFromIsvcNamespace(ctx, secret, isvc); err != nil { - log.V(1).Error(err, "Failed to copy the Secret for InferenceService in the istio-system namespace") - return err - } + return err } + // destinationSecretExist := true + // if _, err := r.secretHandler.Get(ctx, types.NamespacedName{Name: isvc.Name, Namespace: meshNamespace}); err != nil { + // if errors.IsNotFound(err) { + // destinationSecretExist = false + // } else { + // return err + // } + // } + + // if !destinationSecretExist { + // secret := &corev1.Secret{} + // for attempt := 1; attempt <= maxSecretCheckAttempts; attempt++ { + // getSecretErr := r.client.Get(ctx, types.NamespacedName{Name: isvc.Name, Namespace: isvc.Namespace}, secret) + // if getSecretErr == nil { + // break + // } + // if errors.IsNotFound(getSecretErr) { + // log.V(2).Info("The certificate secret is not created yet. Retrying...", "attempt_number", attempt) + // time.Sleep(secretCheckInterval) + // } else { + // log.Error(getSecretErr, "Failed to retrieve the certificate secret for the InferenceService (ISVC)") + // return getSecretErr + // } + // } + // Create Desired resource - desiredResource, err := r.createDesiredResource(isvc) + desiredResource, err := r.getDesiredResource(isvc) if err != nil { return err } @@ -123,13 +144,13 @@ func (r *KserveGatewayReconciler) Reconcile(ctx context.Context, log logr.Logger return nil } -func (r *KserveGatewayReconciler) createDesiredResource(isvc *kservev1beta1.InferenceService) (*istioclientv1beta1.Gateway, error) { - hostname := fmt.Sprintf("%s.%s.%s", isvc.Name, isvc.Namespace, internalSerivceHostnameDomain) +func (r *KserveGatewayReconciler) getDesiredResource(isvc *kservev1beta1.InferenceService) (*istioclientv1beta1.Gateway, error) { + hostname := isvc.Status.Address.URL.String() desiredGateway := &istioclientv1beta1.Gateway{ ObjectMeta: metav1.ObjectMeta{ Name: constants.KServeGatewayName, - Namespace: isvc.Namespace, + Namespace: meshNamespace, }, Spec: istiov1beta1.Gateway{ Servers: []*istiov1beta1.Server{ @@ -153,7 +174,7 @@ func (r *KserveGatewayReconciler) createDesiredResource(isvc *kservev1beta1.Infe } func (r *KserveGatewayReconciler) getExistingResource(ctx context.Context) (*istioclientv1beta1.Gateway, error) { - return r.gatewayHandler.Get(ctx, types.NamespacedName{Name: constants.KServeGatewayName, Namespace: constants.IstioNamespace}) + return r.gatewayHandler.Get(ctx, types.NamespacedName{Name: constants.KServeGatewayName, Namespace: meshNamespace}) } func (r *KserveGatewayReconciler) Delete(ctx context.Context, log logr.Logger, isvc *kservev1beta1.InferenceService) error { @@ -181,15 +202,6 @@ func (r *KserveGatewayReconciler) processDelta(ctx context.Context, log logr.Log comparator := comparators.GetGatewayComparator() delta := r.deltaProcessor.ComputeDelta(comparator, desiredGateway, existingGateway) - if !delta.HasChanges() { - // Note: This code will not be executed. - return nil - } - if delta.IsAdded() { - // Note: This code will not be executed. - return nil - } - if delta.IsUpdated() { log.V(1).Info("Delta found", "update", desiredGateway.GetName()) gw := existingGateway.DeepCopy() @@ -203,15 +215,12 @@ func (r *KserveGatewayReconciler) processDelta(ctx context.Context, log logr.Log return nil } - if delta.IsRemoved() { - // Note: This code will not be executed. - return nil - } return nil } func (r *KserveGatewayReconciler) removeServerFromGateway(ctx context.Context, log logr.Logger, serverToRemove string) error { - gateway, err := r.gatewayHandler.Get(ctx, types.NamespacedName{Name: constants.KServeGatewayName, Namespace: constants.IstioNamespace}) + + gateway, err := r.gatewayHandler.Get(ctx, types.NamespacedName{Name: constants.KServeGatewayName, Namespace: meshNamespace}) if err != nil { log.V(1).Error(err, "Failed to retrieve KServe local gateway in istio-system namespace") return err @@ -234,11 +243,11 @@ func (r *KserveGatewayReconciler) removeServerFromGateway(ctx context.Context, l } func (r *KserveGatewayReconciler) copyServingCertSecretFromIsvcNamespace(ctx context.Context, sourceSecret *corev1.Secret, isvc *kservev1beta1.InferenceService) error { - + fmt.Print("AAAAA2", "meshNamespace", meshNamespace) destinationSecret := &corev1.Secret{ ObjectMeta: metav1.ObjectMeta{ Name: sourceSecret.Name, - Namespace: constants.IstioNamespace, + Namespace: meshNamespace, }, Data: sourceSecret.Data, Type: sourceSecret.Type, @@ -251,7 +260,7 @@ func (r *KserveGatewayReconciler) copyServingCertSecretFromIsvcNamespace(ctx con } func (r *KserveGatewayReconciler) deleteServingCertSecretInIstioNamespace(ctx context.Context, targetSecretName string) error { - secret, err := r.secretHandler.Get(ctx, types.NamespacedName{Name: targetSecretName, Namespace: constants.IstioNamespace}) + secret, err := r.secretHandler.Get(ctx, types.NamespacedName{Name: targetSecretName, Namespace: meshNamespace}) if err != nil && errors.IsNotFound(err) { return nil } diff --git a/controllers/reconcilers/kserve_isvc_service_cert_reconciler.go b/controllers/reconcilers/kserve_isvc_service_cert_reconciler.go index f17fa0e4..119743ce 100644 --- a/controllers/reconcilers/kserve_isvc_service_cert_reconciler.go +++ b/controllers/reconcilers/kserve_isvc_service_cert_reconciler.go @@ -17,7 +17,6 @@ package reconcilers import ( "context" - "time" "github.com/go-logr/logr" kservev1beta1 "github.com/kserve/kserve/pkg/apis/serving/v1beta1" @@ -56,28 +55,28 @@ func (r *KserveIsvcServiceReconciler) Cleanup(_ context.Context, _ logr.Logger, func (r *KserveIsvcServiceReconciler) Reconcile(ctx context.Context, log logr.Logger, isvc *kservev1beta1.InferenceService) error { log.V(1).Info("Reconciling InferenceService Service serving cert") - // return if URL is not set - if isvc.Status.URL == nil { - log.V(1).Info("Waiting for the URL as the Inference Service is not ready yet", "reconcile", isvc) - return nil - } - - // Create Desired resource - desiredResource, err := r.createDesiredResource(isvc) - if err != nil { - return err - } - - // Get Existing resource - existingResource, err := r.getExistingResource(ctx, log, isvc) - if err != nil { - return err - } - - // Process Delta - if err = r.processDelta(ctx, log, desiredResource, existingResource); err != nil { - return err - } + // // return if URL is not set + // if isvc.Status.URL == nil { + // log.V(1).Info("Waiting for the URL as the Inference Service is not ready yet", "reconcile", isvc) + // return nil + // } + + // // Create Desired resource + // desiredResource, err := r.createDesiredResource(isvc) + // if err != nil { + // return err + // } + + // // Get Existing resource + // existingResource, err := r.getExistingResource(ctx, log, isvc) + // if err != nil { + // return err + // } + + // // Process Delta + // if err = r.processDelta(ctx, log, desiredResource, existingResource); err != nil { + // return err + // } return nil } @@ -94,7 +93,7 @@ func (r *KserveIsvcServiceReconciler) createDesiredResource(isvc *kservev1beta1. } func (r *KserveIsvcServiceReconciler) getExistingResource(ctx context.Context, log logr.Logger, isvc *kservev1beta1.InferenceService) (*v1.Service, error) { - return r.serviceHandler.FetchServiceWithRetryAndDelay(ctx, log, types.NamespacedName{Name: isvc.Name, Namespace: isvc.Namespace}, 1*time.Second, 10) + return r.serviceHandler.FetchService(ctx, log, types.NamespacedName{Name: isvc.Name, Namespace: isvc.Namespace}) } func (r *KserveIsvcServiceReconciler) processDelta(ctx context.Context, log logr.Logger, desiredService *v1.Service, existingService *v1.Service) (err error) { diff --git a/controllers/resources/service.go b/controllers/resources/service.go index 3da490ae..678b2104 100644 --- a/controllers/resources/service.go +++ b/controllers/resources/service.go @@ -17,8 +17,6 @@ package resources import ( "context" - "fmt" - "time" "github.com/go-logr/logr" v1 "k8s.io/api/core/v1" @@ -29,7 +27,6 @@ import ( type ServiceHandler interface { FetchService(ctx context.Context, log logr.Logger, key types.NamespacedName) (*v1.Service, error) - FetchServiceWithRetryAndDelay(ctx context.Context, log logr.Logger, key types.NamespacedName, retryDelay time.Duration, retry int) (*v1.Service, error) } type serviceHandler struct { @@ -54,28 +51,3 @@ func (r *serviceHandler) FetchService(ctx context.Context, log logr.Logger, key log.V(1).Info("Successfully fetch deployed Service") return svc, nil } - -func (r *serviceHandler) FetchServiceWithRetryAndDelay(ctx context.Context, log logr.Logger, key types.NamespacedName, retryDelay time.Duration, retry int) (*v1.Service, error) { - var svc *v1.Service - var err error - - for attempt := 1; attempt <= retry; attempt++ { - svc, err = r.FetchService(ctx, log, key) - if err != nil { - if svc == nil || errors.IsNotFound(err) { - log.Info(fmt.Sprintf("Service not found. Retrying(%d)..", attempt)) - time.Sleep(retryDelay) - continue - } else { - return nil, err - } - } - break - } - - if svc == nil { - log.Error(err, fmt.Sprintf("Failed to fetch the Service(%s) after retries(%d)", key.Name, retry)) - return nil, err - } - return svc, nil -} diff --git a/controllers/webhook/kserve_service_mutator.go b/controllers/webhook/kserve_service_mutator.go new file mode 100644 index 00000000..06aea89f --- /dev/null +++ b/controllers/webhook/kserve_service_mutator.go @@ -0,0 +1,61 @@ +package webhook + +import ( + "context" + "fmt" + + kservev1beta1 "github.com/kserve/kserve/pkg/apis/serving/v1beta1" + corev1 "k8s.io/api/core/v1" + apierrors "k8s.io/apimachinery/pkg/api/errors" + "k8s.io/apimachinery/pkg/runtime" + "sigs.k8s.io/controller-runtime/pkg/client" + logf "sigs.k8s.io/controller-runtime/pkg/log" + "sigs.k8s.io/controller-runtime/pkg/webhook/admission" +) + +// +kubebuilder:webhook:admissionReviewVersions=v1,path=/mutate-serving-kserve-service,mutating=true,failurePolicy=fail,groups="",resources=services,verbs=create,versions=v1,name=mutating.kserve-service.odh-model-controller.opendatahub.io,sideEffects=None + +type kserveServiceMutator struct { + client client.Client + Decoder *admission.Decoder +} + +func NewKserveServiceMutator(client client.Client) *kserveServiceMutator { + return &kserveServiceMutator{client: client} +} + +// Default implements the admission.Defaulter interface to mutate the resources +func (m *kserveServiceMutator) Default(ctx context.Context, obj runtime.Object) error { + log := logf.FromContext(ctx).WithName("KserviceServiceMutateWebhook") + + svc, ok := obj.(*corev1.Service) + if !ok { + return fmt.Errorf("unexpected object type") + } + + // Retrieve the InferenceService directly by name + var isvc kservev1beta1.InferenceService + err := m.client.Get(ctx, client.ObjectKey{Name: svc.Name, Namespace: svc.Namespace}, &isvc) + if err != nil { + if apierrors.IsNotFound(err) { + // If InferenceService is not found, return without error + return nil + } + return fmt.Errorf("failed to get InferenceService: %w", err) + } + + // Add the annotation if a matching InferenceService is found + if svc.Annotations == nil { + svc.Annotations = make(map[string]string) + } + svc.Annotations["service.beta.openshift.io/serving-cert-secret-name"] = isvc.Name + log.Info("Added annotation to Service", "ServiceName", svc.Name, "Annotation", svc.Annotations["service.beta.openshift.io/serving-cert-secret-name"]) + + return nil +} + +// InjectDecoder injects the decoder into the KserveServiceMutator +func (m *kserveServiceMutator) InjectDecoder(d *admission.Decoder) error { + m.Decoder = d + return nil +} diff --git a/controllers/webhook_kserve_service_mutator_test.go b/controllers/webhook_kserve_service_mutator_test.go new file mode 100644 index 00000000..c3543da0 --- /dev/null +++ b/controllers/webhook_kserve_service_mutator_test.go @@ -0,0 +1,62 @@ +package controllers + +import ( + kservev1beta1 "github.com/kserve/kserve/pkg/apis/serving/v1beta1" + . "github.com/onsi/ginkgo" + . "github.com/onsi/gomega" + "github.com/opendatahub-io/odh-model-controller/controllers/webhook" + corev1 "k8s.io/api/core/v1" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "sigs.k8s.io/controller-runtime/pkg/webhook/admission" +) + +var _ = Describe("KServe Service mutator webhook", func() { + var mutator admission.CustomDefaulter + defaultIsvcName := "isvc-name" + defaultNsName := "default" + createServiceOwnedKserve := func() *corev1.Service { + return &corev1.Service{ + ObjectMeta: metav1.ObjectMeta{ + Name: defaultIsvcName, + Namespace: "default", + }, + } + } + + BeforeEach(func() { + mutator = webhook.NewKserveServiceMutator(cli) + + }) + + It("adds serving cert annotation if Service name matches InferenceService name", func() { + // Create a new InferenceService + inferenceService := &kservev1beta1.InferenceService{ + ObjectMeta: metav1.ObjectMeta{ + Name: defaultIsvcName, + Namespace: defaultNsName, + }, + } + Expect(cli.Create(ctx, inferenceService)).Should(Succeed()) + + kserveService := createServiceOwnedKserve() + + err := mutator.Default(ctx, kserveService) + Expect(err).ShouldNot(HaveOccurred()) + + // Verify that serving cert annoation is set + Expect(kserveService.Annotations).To(HaveKey("service.beta.openshift.io/serving-cert-secret-name")) + Expect(kserveService.Annotations["service.beta.openshift.io/serving-cert-secret-name"]).To(Equal(defaultIsvcName)) + }) + + It("skips adding annotation when Service name does not match InferenceService name", func() { + kserveServiceName := "different-name" + kserveService := createServiceOwnedKserve() + kserveService.SetName(kserveServiceName) + + err := mutator.Default(ctx, kserveService) + Expect(err).ShouldNot(HaveOccurred()) + + // Verify that serving cert annoation is NOT set + Expect(kserveService.Annotations).NotTo(HaveKey("service.beta.openshift.io/serving-cert-secret-name")) + }) +}) diff --git a/go.mod b/go.mod index c71d0843..58457df7 100644 --- a/go.mod +++ b/go.mod @@ -7,6 +7,7 @@ require ( github.com/hashicorp/go-multierror v1.1.1 github.com/kserve/kserve v0.12.1 github.com/kuadrant/authorino v0.15.0 + github.com/moby/moby v27.0.0+incompatible github.com/onsi/ginkgo v1.16.5 github.com/onsi/gomega v1.30.0 github.com/opendatahub-io/model-registry v0.1.1 @@ -39,7 +40,14 @@ require ( github.com/beorn7/perks v1.0.1 // indirect github.com/blendle/zapdriver v1.3.1 // indirect github.com/cespare/xxhash/v2 v2.2.0 // indirect + github.com/containerd/fifo v1.1.0 // indirect + github.com/containerd/log v0.1.0 // indirect github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect + github.com/docker/distribution v2.8.2+incompatible // indirect + github.com/docker/docker v24.0.7+incompatible // indirect + github.com/docker/go-connections v0.4.0 // indirect + github.com/docker/go-metrics v0.0.1 // indirect + github.com/docker/go-units v0.5.0 // indirect github.com/emicklei/go-restful/v3 v3.11.0 // indirect github.com/evanphx/json-patch/v5 v5.7.0 // indirect github.com/fsnotify/fsnotify v1.7.0 // indirect @@ -67,16 +75,21 @@ require ( github.com/json-iterator/go v1.1.12 // indirect github.com/mailru/easyjson v0.7.7 // indirect github.com/matttproud/golang_protobuf_extensions/v2 v2.0.0 // indirect + github.com/moby/term v0.5.0 // indirect github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect github.com/modern-go/reflect2 v1.0.2 // indirect + github.com/morikuni/aec v1.0.0 // indirect github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect github.com/nxadm/tail v1.4.8 // indirect github.com/opencontainers/go-digest v1.0.0 // indirect + github.com/opencontainers/image-spec v1.1.0-rc5 // indirect github.com/pkg/errors v0.9.1 // indirect github.com/prometheus/client_golang v1.17.0 // indirect github.com/prometheus/client_model v0.5.0 // indirect github.com/prometheus/common v0.45.0 // indirect github.com/prometheus/procfs v0.12.0 // indirect + github.com/rootless-containers/rootlesskit v1.1.1 // indirect + github.com/sirupsen/logrus v1.9.3 // indirect github.com/spf13/pflag v1.0.5 // indirect github.com/tidwall/match v1.1.1 // indirect github.com/tidwall/pretty v1.2.1 // indirect diff --git a/go.sum b/go.sum index 0de96e76..f50e18af 100644 --- a/go.sum +++ b/go.sum @@ -6,86 +6,280 @@ cloud.google.com/go v0.44.2/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxK cloud.google.com/go v0.44.3/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxKY= cloud.google.com/go v0.110.10 h1:LXy9GEO+timppncPIAZoOj3l58LIU9k+kn48AN7IO3Y= cloud.google.com/go v0.110.10/go.mod h1:v1OoFqYxiBkUrruItNM3eT4lLByNjxmJSV/xDKJNnic= +cloud.google.com/go/accessapproval v1.7.4/go.mod h1:/aTEh45LzplQgFYdQdwPMR9YdX0UlhBmvB84uAmQKUc= +cloud.google.com/go/accesscontextmanager v1.8.4/go.mod h1:ParU+WbMpD34s5JFEnGAnPBYAgUHozaTmDJU7aCU9+M= +cloud.google.com/go/aiplatform v1.52.0/go.mod h1:pwZMGvqe0JRkI1GWSZCtnAfrR4K1bv65IHILGA//VEU= +cloud.google.com/go/analytics v0.21.6/go.mod h1:eiROFQKosh4hMaNhF85Oc9WO97Cpa7RggD40e/RBy8w= +cloud.google.com/go/apigateway v1.6.4/go.mod h1:0EpJlVGH5HwAN4VF4Iec8TAzGN1aQgbxAWGJsnPCGGY= +cloud.google.com/go/apigeeconnect v1.6.4/go.mod h1:CapQCWZ8TCjnU0d7PobxhpOdVz/OVJ2Hr/Zcuu1xFx0= +cloud.google.com/go/apigeeregistry v0.8.2/go.mod h1:h4v11TDGdeXJDJvImtgK2AFVvMIgGWjSb0HRnBSjcX8= +cloud.google.com/go/appengine v1.8.4/go.mod h1:TZ24v+wXBujtkK77CXCpjZbnuTvsFNT41MUaZ28D6vg= +cloud.google.com/go/area120 v0.8.4/go.mod h1:jfawXjxf29wyBXr48+W+GyX/f8fflxp642D/bb9v68M= +cloud.google.com/go/artifactregistry v1.14.6/go.mod h1:np9LSFotNWHcjnOgh8UVK0RFPCTUGbO0ve3384xyHfE= +cloud.google.com/go/asset v1.15.3/go.mod h1:yYLfUD4wL4X589A9tYrv4rFrba0QlDeag0CMcM5ggXU= +cloud.google.com/go/assuredworkloads v1.11.4/go.mod h1:4pwwGNwy1RP0m+y12ef3Q/8PaiWrIDQ6nD2E8kvWI9U= +cloud.google.com/go/automl v1.13.4/go.mod h1:ULqwX/OLZ4hBVfKQaMtxMSTlPx0GqGbWN8uA/1EqCP8= +cloud.google.com/go/baremetalsolution v1.2.3/go.mod h1:/UAQ5xG3faDdy180rCUv47e0jvpp3BFxT+Cl0PFjw5g= +cloud.google.com/go/batch v1.6.3/go.mod h1:J64gD4vsNSA2O5TtDB5AAux3nJ9iV8U3ilg3JDBYejU= +cloud.google.com/go/beyondcorp v1.0.3/go.mod h1:HcBvnEd7eYr+HGDd5ZbuVmBYX019C6CEXBonXbCVwJo= cloud.google.com/go/bigquery v1.0.1/go.mod h1:i/xbL2UlR5RvWAURpBYZTtm/cXjCha9lbfbpx4poX+o= +cloud.google.com/go/bigquery v1.57.1/go.mod h1:iYzC0tGVWt1jqSzBHqCr3lrRn0u13E8e+AqowBsDgug= +cloud.google.com/go/billing v1.17.4/go.mod h1:5DOYQStCxquGprqfuid/7haD7th74kyMBHkjO/OvDtk= +cloud.google.com/go/binaryauthorization v1.7.3/go.mod h1:VQ/nUGRKhrStlGr+8GMS8f6/vznYLkdK5vaKfdCIpvU= +cloud.google.com/go/certificatemanager v1.7.4/go.mod h1:FHAylPe/6IIKuaRmHbjbdLhGhVQ+CWHSD5Jq0k4+cCE= +cloud.google.com/go/channel v1.17.3/go.mod h1:QcEBuZLGGrUMm7kNj9IbU1ZfmJq2apotsV83hbxX7eE= +cloud.google.com/go/cloudbuild v1.14.3/go.mod h1:eIXYWmRt3UtggLnFGx4JvXcMj4kShhVzGndL1LwleEM= +cloud.google.com/go/clouddms v1.7.3/go.mod h1:fkN2HQQNUYInAU3NQ3vRLkV2iWs8lIdmBKOx4nrL6Hc= +cloud.google.com/go/cloudtasks v1.12.4/go.mod h1:BEPu0Gtt2dU6FxZHNqqNdGqIG86qyWKBPGnsb7udGY0= cloud.google.com/go/compute v1.23.3 h1:6sVlXXBmbd7jNX0Ipq0trII3e4n1/MsADLK6a+aiVlk= cloud.google.com/go/compute v1.23.3/go.mod h1:VCgBUoMnIVIR0CscqQiPJLAG25E3ZRZMzcFZeQ+h8CI= cloud.google.com/go/compute/metadata v0.2.3 h1:mg4jlk7mCAj6xXp9UJ4fjI9VUI5rubuGBW5aJ7UnBMY= cloud.google.com/go/compute/metadata v0.2.3/go.mod h1:VAV5nSsACxMJvgaAuX6Pk2AawlZn8kiOGuCv6gTkwuA= +cloud.google.com/go/contactcenterinsights v1.11.3/go.mod h1:HHX5wrz5LHVAwfI2smIotQG9x8Qd6gYilaHcLLLmNis= +cloud.google.com/go/container v1.27.1/go.mod h1:b1A1gJeTBXVLQ6GGw9/9M4FG94BEGsqJ5+t4d/3N7O4= +cloud.google.com/go/containeranalysis v0.11.3/go.mod h1:kMeST7yWFQMGjiG9K7Eov+fPNQcGhb8mXj/UcTiWw9U= +cloud.google.com/go/datacatalog v1.18.3/go.mod h1:5FR6ZIF8RZrtml0VUao22FxhdjkoG+a0866rEnObryM= +cloud.google.com/go/dataflow v0.9.4/go.mod h1:4G8vAkHYCSzU8b/kmsoR2lWyHJD85oMJPHMtan40K8w= +cloud.google.com/go/dataform v0.9.1/go.mod h1:pWTg+zGQ7i16pyn0bS1ruqIE91SdL2FDMvEYu/8oQxs= +cloud.google.com/go/datafusion v1.7.4/go.mod h1:BBs78WTOLYkT4GVZIXQCZT3GFpkpDN4aBY4NDX/jVlM= +cloud.google.com/go/datalabeling v0.8.4/go.mod h1:Z1z3E6LHtffBGrNUkKwbwbDxTiXEApLzIgmymj8A3S8= +cloud.google.com/go/dataplex v1.11.1/go.mod h1:mHJYQQ2VEJHsyoC0OdNyy988DvEbPhqFs5OOLffLX0c= +cloud.google.com/go/dataproc/v2 v2.2.3/go.mod h1:G5R6GBc9r36SXv/RtZIVfB8SipI+xVn0bX5SxUzVYbY= +cloud.google.com/go/dataqna v0.8.4/go.mod h1:mySRKjKg5Lz784P6sCov3p1QD+RZQONRMRjzGNcFd0c= cloud.google.com/go/datastore v1.0.0/go.mod h1:LXYbyblFSglQ5pkeyhO+Qmw7ukd3C+pD7TKLgZqpHYE= +cloud.google.com/go/datastore v1.15.0/go.mod h1:GAeStMBIt9bPS7jMJA85kgkpsMkvseWWXiaHya9Jes8= +cloud.google.com/go/datastream v1.10.3/go.mod h1:YR0USzgjhqA/Id0Ycu1VvZe8hEWwrkjuXrGbzeDOSEA= +cloud.google.com/go/deploy v1.14.2/go.mod h1:e5XOUI5D+YGldyLNZ21wbp9S8otJbBE4i88PtO9x/2g= +cloud.google.com/go/dialogflow v1.44.3/go.mod h1:mHly4vU7cPXVweuB5R0zsYKPMzy240aQdAu06SqBbAQ= +cloud.google.com/go/dlp v1.11.1/go.mod h1:/PA2EnioBeXTL/0hInwgj0rfsQb3lpE3R8XUJxqUNKI= +cloud.google.com/go/documentai v1.23.5/go.mod h1:ghzBsyVTiVdkfKaUCum/9bGBEyBjDO4GfooEcYKhN+g= +cloud.google.com/go/domains v0.9.4/go.mod h1:27jmJGShuXYdUNjyDG0SodTfT5RwLi7xmH334Gvi3fY= +cloud.google.com/go/edgecontainer v1.1.4/go.mod h1:AvFdVuZuVGdgaE5YvlL1faAoa1ndRR/5XhXZvPBHbsE= +cloud.google.com/go/errorreporting v0.3.0/go.mod h1:xsP2yaAp+OAW4OIm60An2bbLpqIhKXdWR/tawvl7QzU= +cloud.google.com/go/essentialcontacts v1.6.5/go.mod h1:jjYbPzw0x+yglXC890l6ECJWdYeZ5dlYACTFL0U/VuM= +cloud.google.com/go/eventarc v1.13.3/go.mod h1:RWH10IAZIRcj1s/vClXkBgMHwh59ts7hSWcqD3kaclg= +cloud.google.com/go/filestore v1.7.4/go.mod h1:S5JCxIbFjeBhWMTfIYH2Jx24J6BqjwpkkPl+nBA5DlI= +cloud.google.com/go/firestore v1.14.0/go.mod h1:96MVaHLsEhbvkBEdZgfN+AS/GIkco1LRpH9Xp9YZfzQ= +cloud.google.com/go/functions v1.15.4/go.mod h1:CAsTc3VlRMVvx+XqXxKqVevguqJpnVip4DdonFsX28I= +cloud.google.com/go/gkebackup v1.3.4/go.mod h1:gLVlbM8h/nHIs09ns1qx3q3eaXcGSELgNu1DWXYz1HI= +cloud.google.com/go/gkeconnect v0.8.4/go.mod h1:84hZz4UMlDCKl8ifVW8layK4WHlMAFeq8vbzjU0yJkw= +cloud.google.com/go/gkehub v0.14.4/go.mod h1:Xispfu2MqnnFt8rV/2/3o73SK1snL8s9dYJ9G2oQMfc= +cloud.google.com/go/gkemulticloud v1.0.3/go.mod h1:7NpJBN94U6DY1xHIbsDqB2+TFZUfjLUKLjUX8NGLor0= +cloud.google.com/go/gsuiteaddons v1.6.4/go.mod h1:rxtstw7Fx22uLOXBpsvb9DUbC+fiXs7rF4U29KHM/pE= cloud.google.com/go/iam v1.1.5 h1:1jTsCu4bcsNsE4iiqNT5SHwrDRCfRmIaaaVFhRveTJI= cloud.google.com/go/iam v1.1.5/go.mod h1:rB6P/Ic3mykPbFio+vo7403drjlgvoWfYpJhMXEbzv8= +cloud.google.com/go/iap v1.9.3/go.mod h1:DTdutSZBqkkOm2HEOTBzhZxh2mwwxshfD/h3yofAiCw= +cloud.google.com/go/ids v1.4.4/go.mod h1:z+WUc2eEl6S/1aZWzwtVNWoSZslgzPxAboS0lZX0HjI= +cloud.google.com/go/iot v1.7.4/go.mod h1:3TWqDVvsddYBG++nHSZmluoCAVGr1hAcabbWZNKEZLk= +cloud.google.com/go/kms v1.15.5/go.mod h1:cU2H5jnp6G2TDpUGZyqTCoy1n16fbubHZjmVXSMtwDI= +cloud.google.com/go/language v1.12.2/go.mod h1:9idWapzr/JKXBBQ4lWqVX/hcadxB194ry20m/bTrhWc= +cloud.google.com/go/lifesciences v0.9.4/go.mod h1:bhm64duKhMi7s9jR9WYJYvjAFJwRqNj+Nia7hF0Z7JA= +cloud.google.com/go/logging v1.8.1/go.mod h1:TJjR+SimHwuC8MZ9cjByQulAMgni+RkXeI3wwctHJEI= +cloud.google.com/go/longrunning v0.5.4/go.mod h1:zqNVncI0BOP8ST6XQD1+VcvuShMmq7+xFSzOL++V0dI= +cloud.google.com/go/managedidentities v1.6.4/go.mod h1:WgyaECfHmF00t/1Uk8Oun3CQ2PGUtjc3e9Alh79wyiM= +cloud.google.com/go/maps v1.6.1/go.mod h1:4+buOHhYXFBp58Zj/K+Lc1rCmJssxxF4pJ5CJnhdz18= +cloud.google.com/go/mediatranslation v0.8.4/go.mod h1:9WstgtNVAdN53m6TQa5GjIjLqKQPXe74hwSCxUP6nj4= +cloud.google.com/go/memcache v1.10.4/go.mod h1:v/d8PuC8d1gD6Yn5+I3INzLR01IDn0N4Ym56RgikSI0= +cloud.google.com/go/metastore v1.13.3/go.mod h1:K+wdjXdtkdk7AQg4+sXS8bRrQa9gcOr+foOMF2tqINE= +cloud.google.com/go/monitoring v1.16.3/go.mod h1:KwSsX5+8PnXv5NJnICZzW2R8pWTis8ypC4zmdRD63Tw= +cloud.google.com/go/networkconnectivity v1.14.3/go.mod h1:4aoeFdrJpYEXNvrnfyD5kIzs8YtHg945Og4koAjHQek= +cloud.google.com/go/networkmanagement v1.9.3/go.mod h1:y7WMO1bRLaP5h3Obm4tey+NquUvB93Co1oh4wpL+XcU= +cloud.google.com/go/networksecurity v0.9.4/go.mod h1:E9CeMZ2zDsNBkr8axKSYm8XyTqNhiCHf1JO/Vb8mD1w= +cloud.google.com/go/notebooks v1.11.2/go.mod h1:z0tlHI/lREXC8BS2mIsUeR3agM1AkgLiS+Isov3SS70= +cloud.google.com/go/optimization v1.6.2/go.mod h1:mWNZ7B9/EyMCcwNl1frUGEuY6CPijSkz88Fz2vwKPOY= +cloud.google.com/go/orchestration v1.8.4/go.mod h1:d0lywZSVYtIoSZXb0iFjv9SaL13PGyVOKDxqGxEf/qI= +cloud.google.com/go/orgpolicy v1.11.4/go.mod h1:0+aNV/nrfoTQ4Mytv+Aw+stBDBjNf4d8fYRA9herfJI= +cloud.google.com/go/osconfig v1.12.4/go.mod h1:B1qEwJ/jzqSRslvdOCI8Kdnp0gSng0xW4LOnIebQomA= +cloud.google.com/go/oslogin v1.12.2/go.mod h1:CQ3V8Jvw4Qo4WRhNPF0o+HAM4DiLuE27Ul9CX9g2QdY= +cloud.google.com/go/phishingprotection v0.8.4/go.mod h1:6b3kNPAc2AQ6jZfFHioZKg9MQNybDg4ixFd4RPZZ2nE= +cloud.google.com/go/policytroubleshooter v1.10.2/go.mod h1:m4uF3f6LseVEnMV6nknlN2vYGRb+75ylQwJdnOXfnv0= +cloud.google.com/go/privatecatalog v0.9.4/go.mod h1:SOjm93f+5hp/U3PqMZAHTtBtluqLygrDrVO8X8tYtG0= +cloud.google.com/go/pubsub v1.33.0/go.mod h1:f+w71I33OMyxf9VpMVcZbnG5KSUkCOUHYpFd5U1GdRc= +cloud.google.com/go/pubsublite v1.8.1/go.mod h1:fOLdU4f5xldK4RGJrBMm+J7zMWNj/k4PxwEZXy39QS0= +cloud.google.com/go/recaptchaenterprise/v2 v2.8.3/go.mod h1:Dak54rw6lC2gBY8FBznpOCAR58wKf+R+ZSJRoeJok4w= +cloud.google.com/go/recommendationengine v0.8.4/go.mod h1:GEteCf1PATl5v5ZsQ60sTClUE0phbWmo3rQ1Js8louU= +cloud.google.com/go/recommender v1.11.3/go.mod h1:+FJosKKJSId1MBFeJ/TTyoGQZiEelQQIZMKYYD8ruK4= +cloud.google.com/go/redis v1.14.1/go.mod h1:MbmBxN8bEnQI4doZPC1BzADU4HGocHBk2de3SbgOkqs= +cloud.google.com/go/resourcemanager v1.9.4/go.mod h1:N1dhP9RFvo3lUfwtfLWVxfUWq8+KUQ+XLlHLH3BoFJ0= +cloud.google.com/go/resourcesettings v1.6.4/go.mod h1:pYTTkWdv2lmQcjsthbZLNBP4QW140cs7wqA3DuqErVI= +cloud.google.com/go/retail v1.14.4/go.mod h1:l/N7cMtY78yRnJqp5JW8emy7MB1nz8E4t2yfOmklYfg= +cloud.google.com/go/run v1.3.3/go.mod h1:WSM5pGyJ7cfYyYbONVQBN4buz42zFqwG67Q3ch07iK4= +cloud.google.com/go/scheduler v1.10.4/go.mod h1:MTuXcrJC9tqOHhixdbHDFSIuh7xZF2IysiINDuiq6NI= +cloud.google.com/go/secretmanager v1.11.4/go.mod h1:wreJlbS9Zdq21lMzWmJ0XhWW2ZxgPeahsqeV/vZoJ3w= +cloud.google.com/go/security v1.15.4/go.mod h1:oN7C2uIZKhxCLiAAijKUCuHLZbIt/ghYEo8MqwD/Ty4= +cloud.google.com/go/securitycenter v1.24.2/go.mod h1:l1XejOngggzqwr4Fa2Cn+iWZGf+aBLTXtB/vXjy5vXM= +cloud.google.com/go/servicedirectory v1.11.3/go.mod h1:LV+cHkomRLr67YoQy3Xq2tUXBGOs5z5bPofdq7qtiAw= +cloud.google.com/go/shell v1.7.4/go.mod h1:yLeXB8eKLxw0dpEmXQ/FjriYrBijNsONpwnWsdPqlKM= +cloud.google.com/go/spanner v1.51.0/go.mod h1:c5KNo5LQ1X5tJwma9rSQZsXNBDNvj4/n8BVc3LNahq0= +cloud.google.com/go/speech v1.20.1/go.mod h1:wwolycgONvfz2EDU8rKuHRW3+wc9ILPsAWoikBEWavY= cloud.google.com/go/storage v1.35.1 h1:B59ahL//eDfx2IIKFBeT5Atm9wnNmj3+8xG/W4WB//w= cloud.google.com/go/storage v1.35.1/go.mod h1:M6M/3V/D3KpzMTJyPOR/HU6n2Si5QdaXYEsng2xgOs8= +cloud.google.com/go/storagetransfer v1.10.3/go.mod h1:Up8LY2p6X68SZ+WToswpQbQHnJpOty/ACcMafuey8gc= +cloud.google.com/go/talent v1.6.5/go.mod h1:Mf5cma696HmE+P2BWJ/ZwYqeJXEeU0UqjHFXVLadEDI= +cloud.google.com/go/texttospeech v1.7.4/go.mod h1:vgv0002WvR4liGuSd5BJbWy4nDn5Ozco0uJymY5+U74= +cloud.google.com/go/tpu v1.6.4/go.mod h1:NAm9q3Rq2wIlGnOhpYICNI7+bpBebMJbh0yyp3aNw1Y= +cloud.google.com/go/trace v1.10.4/go.mod h1:Nso99EDIK8Mj5/zmB+iGr9dosS/bzWCJ8wGmE6TXNWY= +cloud.google.com/go/translate v1.9.3/go.mod h1:Kbq9RggWsbqZ9W5YpM94Q1Xv4dshw/gr/SHfsl5yCZ0= +cloud.google.com/go/video v1.20.3/go.mod h1:TnH/mNZKVHeNtpamsSPygSR0iHtvrR/cW1/GDjN5+GU= +cloud.google.com/go/videointelligence v1.11.4/go.mod h1:kPBMAYsTPFiQxMLmmjpcZUMklJp3nC9+ipJJtprccD8= +cloud.google.com/go/vision/v2 v2.7.5/go.mod h1:GcviprJLFfK9OLf0z8Gm6lQb6ZFUulvpZws+mm6yPLM= +cloud.google.com/go/vmmigration v1.7.4/go.mod h1:yBXCmiLaB99hEl/G9ZooNx2GyzgsjKnw5fWcINRgD70= +cloud.google.com/go/vmwareengine v1.0.3/go.mod h1:QSpdZ1stlbfKtyt6Iu19M6XRxjmXO+vb5a/R6Fvy2y4= +cloud.google.com/go/vpcaccess v1.7.4/go.mod h1:lA0KTvhtEOb/VOdnH/gwPuOzGgM+CWsmGu6bb4IoMKk= +cloud.google.com/go/webrisk v1.9.4/go.mod h1:w7m4Ib4C+OseSr2GL66m0zMBywdrVNTDKsdEsfMl7X0= +cloud.google.com/go/websecurityscanner v1.6.4/go.mod h1:mUiyMQ+dGpPPRkHgknIZeCzSHJ45+fY4F52nZFDHm2o= +cloud.google.com/go/workflows v1.12.3/go.mod h1:fmOUeeqEwPzIU81foMjTRQIdwQHADi/vEr1cx9R1m5g= contrib.go.opencensus.io/exporter/ocagent v0.7.1-0.20200907061046-05415f1de66d h1:LblfooH1lKOpp1hIhukktmSAxFkqMPFk9KR6iZ0MJNI= contrib.go.opencensus.io/exporter/ocagent v0.7.1-0.20200907061046-05415f1de66d/go.mod h1:IshRmMJBhDfFj5Y67nVhMYTTIze91RUeT73ipWKs/GY= contrib.go.opencensus.io/exporter/prometheus v0.4.2 h1:sqfsYl5GIY/L570iT+l93ehxaWJs2/OwXtiWwew3oAg= contrib.go.opencensus.io/exporter/prometheus v0.4.2/go.mod h1:dvEHbiKmgvbr5pjaF9fpw1KeYcjrnC1J8B+JKjsZyRQ= +contrib.go.opencensus.io/exporter/zipkin v0.1.2/go.mod h1:mP5xM3rrgOjpn79MM8fZbj3gsxcuytSqtH0dxSWW1RE= dario.cat/mergo v1.0.0 h1:AGCNq9Evsj31mOgNPcLyXc+4PNABt905YmuqPYYpBWk= dario.cat/mergo v1.0.0/go.mod h1:uNxQE+84aUszobStD9th8a29P2fMDhsBdgRYvZOxGmk= +github.com/Azure/azure-sdk-for-go v67.0.0+incompatible/go.mod h1:9XXNKU+eRnpl9moKnB4QOLf1HestfXbmab5FXxiDBjc= github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1 h1:UQHMgLO+TxOElx5B5HZ4hJQsoJ/PvUvKRhJHDQXO8P8= github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E= +github.com/Azure/go-autorest v14.2.0+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24= +github.com/Azure/go-autorest/autorest v0.11.28/go.mod h1:MrkzG3Y3AH668QyF9KRk5neJnGgmhQ6krbhR8Q5eMvA= +github.com/Azure/go-autorest/autorest/adal v0.9.21/go.mod h1:zua7mBUaCc5YnSLKYgGJR/w5ePdMDA6H56upLsHzA9U= +github.com/Azure/go-autorest/autorest/azure/auth v0.5.11/go.mod h1:84w/uV8E37feW2NCJ08uT9VBfjfUHpgLVnG2InYD6cg= +github.com/Azure/go-autorest/autorest/azure/cli v0.4.6/go.mod h1:piCfgPho7BiIDdEQ1+g4VmKyD5y+p/XtSNqE6Hc4QD0= +github.com/Azure/go-autorest/autorest/date v0.3.0/go.mod h1:BI0uouVdmngYNUzGWeSYnokU+TrmwEsOqdt8Y6sso74= +github.com/Azure/go-autorest/logger v0.2.1/go.mod h1:T9E3cAhj2VqvPOtCYAvby9aBXkZmbF5NWuPV8+WeEW8= +github.com/Azure/go-autorest/tracing v0.6.0/go.mod h1:+vhtPC754Xsa23ID7GlGsrdKBpUA79WCAKPPZVC2DeU= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= github.com/Microsoft/go-winio v0.6.1 h1:9/kr64B9VUZrLm5YYwbGtUJnMgqWVOdUAXu6Migciow= github.com/Microsoft/go-winio v0.6.1/go.mod h1:LRdKpFKfdobln8UmuiYcKPot9D2v6svN5+sAH+4kjUM= github.com/Microsoft/hcsshim v0.11.4 h1:68vKo2VN8DE9AdN4tnkWnmdhqdbpUFM8OF3Airm7fz8= github.com/Microsoft/hcsshim v0.11.4/go.mod h1:smjE4dvqPX9Zldna+t5FG3rnoHhaB7QYxPRqGcpAD9w= +github.com/NYTimes/gziphandler v1.1.1/go.mod h1:n/CVRwUEOgIxrgPvAQhUUr9oeUtvrhMomdKFjzJNB0c= +github.com/OneOfOne/xxhash v1.2.8/go.mod h1:eZbhyaAYD41SGSSsnmcpxVoRiQ/MPUTjUdIIOT9Um7Q= +github.com/PuerkitoBio/purell v1.1.1/go.mod h1:c11w/QuzBsJSee3cPx9rAFu61PvFxuPbtSwDGJws/X0= +github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578/go.mod h1:uGdkoq3SwY9Y+13GIhn11/XLaGBb4BfwItxLd5jeuXE= +github.com/XiaoMi/pegasus-go-client v0.0.0-20210427083443-f3b6b08bc4c2/go.mod h1:jNIx5ykW1MroBuaTja9+VpglmaJOUzezumfhLlER3oY= +github.com/agnivade/levenshtein v1.1.1/go.mod h1:veldBMzWxcCG2ZvUTKD2kJNRdCk5hVbJomOvKkmgYbo= +github.com/ahmetb/gen-crd-api-reference-docs v0.3.1-0.20210609063737-0067dc6dcea2/go.mod h1:TdjdkYhlOifCQWPs1UdTma97kQQMozf5h26hTuG70u8= +github.com/alecthomas/kingpin/v2 v2.3.2/go.mod h1:0gyi0zQnjuFk8xrkNKamJoyUo382HRL7ATRpFZCw6tE= +github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= +github.com/alecthomas/units v0.0.0-20151022065526-2efee857e7cf/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0= +github.com/alecthomas/units v0.0.0-20211218093645-b94a6e3cc137/go.mod h1:OMCwj8VM1Kc9e19TLln2VL61YJF0x1XFtfdL4JdbSyE= +github.com/antlr/antlr4/runtime/Go/antlr/v4 v4.0.0-20230305170008-8188dc5388df/go.mod h1:pSwJ0fSY5KhvocuWSx4fz3BA8OrA1bQn+K1Eli3BRwM= +github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5/go.mod h1:wHh0iHkYZB8zMSxRWpUBQtwG5a7fFgvEO+odwuTv2gs= +github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a/go.mod h1:lB+ZfQJz7igIIfQNfa7Ml4HSf2uFQQRzpGGRXenZAgY= +github.com/authzed/authzed-go v0.7.0/go.mod h1:bmjzzIQ34M0+z8NO9SLjf4oA0A9Ka9gUWVzeSbD0E7c= +github.com/authzed/grpcutil v0.0.0-20230109193425-40ce0530e048/go.mod h1:rqjY3zyK/YP7NID9+B2BdIRRkvnK+cdf9/qya/zaFZE= github.com/aws/aws-sdk-go v1.48.0 h1:1SeJ8agckRDQvnSCt1dGZYAwUaoD2Ixj6IaXB4LCv8Q= github.com/aws/aws-sdk-go v1.48.0/go.mod h1:LF8svs817+Nz+DmiMQKTO3ubZ/6IaTpq3TjupRn3Eqk= +github.com/aws/aws-sdk-go-v2 v1.16.16/go.mod h1:SwiyXi/1zTUZ6KIAmLK5V5ll8SiURNUYOqTerZPaF9k= +github.com/aws/aws-sdk-go-v2/config v1.17.8/go.mod h1:UkCI3kb0sCdvtjiXYiU4Zx5h07BOpgBTtkPu/49r+kA= +github.com/aws/aws-sdk-go-v2/credentials v1.12.21/go.mod h1:O+4XyAt4e+oBAoIwNUYkRg3CVMscaIJdmZBOcPgJ8D8= +github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.12.17/go.mod h1:yIkQcCDYNsZfXpd5UX2Cy+sWA1jPgIhGTw9cOBzfVnQ= +github.com/aws/aws-sdk-go-v2/internal/configsources v1.1.23/go.mod h1:2DFxAQ9pfIRy0imBCJv+vZ2X6RKxves6fbnEuSry6b4= +github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.4.17/go.mod h1:pRwaTYCJemADaqCbUAxltMoHKata7hmB5PjEXeu0kfg= +github.com/aws/aws-sdk-go-v2/internal/ini v1.3.24/go.mod h1:jULHjqqjDlbyTa7pfM7WICATnOv+iOhjletM3N0Xbu8= +github.com/aws/aws-sdk-go-v2/service/ecr v1.17.18/go.mod h1:DQtDYmexqR+z+B6HBCvY7zK/tuXKv6Zy/IwOXOK3eow= +github.com/aws/aws-sdk-go-v2/service/ecrpublic v1.13.17/go.mod h1:r1Vuka0kyzqN0sZm4lYTXf0Vhl+o/mTLq6vKpBBZYaQ= +github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.9.17/go.mod h1:4nYOrY41Lrbk2170/BGkcJKBhws9Pfn8MG3aGqjjeFI= +github.com/aws/aws-sdk-go-v2/service/sso v1.11.23/go.mod h1:/w0eg9IhFGjGyyncHIQrXtU8wvNsTJOP0R6PPj0wf80= +github.com/aws/aws-sdk-go-v2/service/ssooidc v1.13.6/go.mod h1:csZuQY65DAdFBt1oIjO5hhBR49kQqop4+lcuCjf2arA= +github.com/aws/aws-sdk-go-v2/service/sts v1.16.19/go.mod h1:h4J3oPZQbxLhzGnk+j9dfYHi5qIOVJ5kczZd658/ydM= +github.com/aws/smithy-go v1.13.3/go.mod h1:Tg+OJXh4MB2R/uN61Ko2f6hTZwB/ZYGOtib8J3gBHzA= +github.com/awslabs/amazon-ecr-credential-helper/ecr-login v0.0.0-20221004211355-a250ad2ca1e3/go.mod h1:m06KtrZgOloUaePAQMv+Ha8kRmTnKdozTHZrweepIrw= +github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q= +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/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/bradfitz/gomemcache v0.0.0-20190913173617-a41fca850d0b/go.mod h1:H0wQNHz2YrLsuXOZozoeDmnHXkNCRmMW0gwFWDfEZDA= +github.com/c2h5oh/datasize v0.0.0-20220606134207-859f65c6625b/go.mod h1:S/7n9copUssQ56c7aAgHqftWO4LTf4xY6CGWt8Bc+3M= github.com/cenkalti/backoff/v4 v4.2.1 h1:y4OZtCnogmCPw98Zjyt5a6+QwPLGkiQsYW5oUqylYbM= github.com/cenkalti/backoff/v4 v4.2.1/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= +github.com/certifi/gocertifi v0.0.0-20210507211836-431795d63e8d/go.mod h1:sGbDF6GwGcLpkNXPUTkMRoywsNa/ol15pxFe6ERfguA= +github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghfAqPWnc= github.com/cespare/xxhash/v2 v2.2.0 h1:DC2CZ1Ep5Y4k3ZQ899DldepgrayRUGE6BBZ/cd9Cj44= github.com/cespare/xxhash/v2 v2.2.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= +github.com/chrismellard/docker-credential-acr-env v0.0.0-20221002210726-e883f69e0206/go.mod h1:1UmFRnmMnVsHwD+ZntmLkoVBB1ZLa6V+XXEbF6hZCxU= github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= +github.com/cloudevents/sdk-go/v2 v2.14.0/go.mod h1:xDmKfzNjM8gBvjaF8ijFjM1VYOVUEeUfapHMUX1T5To= github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc= +github.com/cncf/udpa/go v0.0.0-20220112060539-c52dc94e7fbe/go.mod h1:6pvJx4me5XPnfI9Z40ddWsdw2W/uZgQLFXToKeRcDiI= +github.com/cncf/xds/go v0.0.0-20231109132714-523115ebc101/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= github.com/containerd/containerd v1.7.13 h1:wPYKIeGMN8vaggSKuV1X0wZulpMz4CrgEsZdaCyB6Is= github.com/containerd/containerd v1.7.13/go.mod h1:zT3up6yTRfEUa6+GsITYIJNgSVL9NQ4x4h1RPzk0Wu4= +github.com/containerd/fifo v1.1.0 h1:4I2mbh5stb1u6ycIABlBw9zgtlK8viPI9QkQNRQEEmY= +github.com/containerd/fifo v1.1.0/go.mod h1:bmC4NWMbXlt2EZ0Hc7Fx7QzTFxgPID13eH0Qu+MAb2o= github.com/containerd/log v0.1.0 h1:TCJt7ioM2cr/tfR8GPbGf9/VRAX8D2B4PjzCpfX540I= github.com/containerd/log v0.1.0/go.mod h1:VRRf09a7mHDIRezVKTRCrOq78v577GXq3bSa3EhrzVo= +github.com/containerd/stargz-snapshotter/estargz v0.14.3/go.mod h1:KY//uOCIkSuNAHhJogcZtrNHdKrA99/FCCRjE3HD36o= +github.com/coocood/freecache v1.1.1/go.mod h1:OKrEjkGVoxZhyWAJoeFi5BMLUJm2Tit0kpGkIr7NGYY= +github.com/coreos/go-oidc v2.2.1+incompatible/go.mod h1:CgnwVTmzoESiwO9qyAFEMiHoZ1nMCKZlZ9V6mm3/LKc= +github.com/coreos/go-semver v0.3.1/go.mod h1:irMmmIw/7yzSRPWryHsK7EYSg09caPQL03VsM8rvUec= +github.com/coreos/go-systemd/v22 v22.5.0/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc= github.com/cpuguy83/dockercfg v0.3.1 h1:/FpZ+JaygUR/lZP2NlFI2DVfrOEMAIKP5wWEJdoYe9E= github.com/cpuguy83/dockercfg v0.3.1/go.mod h1:sugsbF4//dDlL/i+S+rtpIWp+5h0BHJHfjj5/jFyUJc= +github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= +github.com/creack/pty v1.1.18/go.mod h1:MOBLtS5ELjhRRrroQr9kyvTxUAFNvYEK993ew/Vr4O4= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc h1:U9qPSI2PIWSS1VwoXQT9A3Wy9MM3WgvqSxFWenqJduM= github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= +github.com/deepmap/oapi-codegen v1.8.2/go.mod h1:YLgSKSDv/bZQB7N4ws6luhozi3cEdRktEqrX88CvjIw= +github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f/go.mod h1:cuUVRXasLTGF7a8hSLbxyZXjz+1KgoB3wDUb6vlszIc= +github.com/dimchansky/utfbom v1.1.1/go.mod h1:SxdoEBH5qIqFocHMyGOXVAybYJdr71b1Q/j0mACtrfE= +github.com/docker/cli v24.0.0+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8= github.com/docker/distribution v2.8.2+incompatible h1:T3de5rq0dB1j30rp0sA2rER+m322EBzniBPB6ZIzuh8= github.com/docker/distribution v2.8.2+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w= github.com/docker/docker v24.0.7+incompatible h1:Wo6l37AuwP3JaMnZa226lzVXGA3F9Ig1seQen0cKYlM= github.com/docker/docker v24.0.7+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= +github.com/docker/docker-credential-helpers v0.7.0/go.mod h1:rETQfLdHNT3foU5kuNkFR1R1V12OJRRO5lzt2D1b5X0= github.com/docker/go-connections v0.4.0 h1:El9xVISelRB7BuFusrZozjnkIM5YnzCViNKohAFqRJQ= github.com/docker/go-connections v0.4.0/go.mod h1:Gbd7IOopHjR8Iph03tsViu4nIes5XhDvyHbTtUxmeec= +github.com/docker/go-metrics v0.0.1 h1:AgB/0SvBxihN0X8OR4SjsblXkbMvalQ8cjmtKQ2rQV8= +github.com/docker/go-metrics v0.0.1/go.mod h1:cG1hvH2utMXtqgqqYE9plW6lDxS3/5ayHzueweSI3Vw= github.com/docker/go-units v0.5.0 h1:69rxXcBk27SvSaaxTtLh/8llcHD8vYHT7WSdRZ/jvr4= github.com/docker/go-units v0.5.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk= +github.com/dustin/go-humanize v1.0.1/go.mod h1:Mu1zIs6XwVuF/gI1OepvI0qD18qycQx+mFykh5fBlto= +github.com/eko/gocache v1.2.0/go.mod h1:6u8/2bnr+nOf87mRXWS710rqNNZUECF4CGsPNnsoJ78= github.com/emicklei/go-restful/v3 v3.11.0 h1:rAQeMHw1c7zTmncogyy8VvRZwtkmkZ4FxERmMY4rD+g= github.com/emicklei/go-restful/v3 v3.11.0/go.mod h1:6n3XBCmQQb25CM2LCACGz8ukIrRry+4bhvbpWn3mrbc= github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98= +github.com/envoyproxy/go-control-plane v0.11.1/go.mod h1:uhMcXKCQMEJHiAb0w+YGefQLaTEw+YhGluxZkrTmD0g= github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= +github.com/envoyproxy/protoc-gen-validate v1.0.2/go.mod h1:GpiZQP3dDbg4JouG/NNS7QWXpgx6x8QiMKdmN72jogE= github.com/evanphx/json-patch v5.7.0+incompatible h1:vgGkfT/9f8zE6tvSCe74nfpAVDQ2tG6yudJd8LBksgI= github.com/evanphx/json-patch v5.7.0+incompatible/go.mod h1:50XU6AFN0ol/bzJsmQLiYLvXMP4fmwYFNcr97nuDLSk= github.com/evanphx/json-patch/v5 v5.7.0 h1:nJqP7uwL84RJInrohHfW0Fx3awjbm8qZeFv0nW9SYGc= github.com/evanphx/json-patch/v5 v5.7.0/go.mod h1:VNkHZ/282BpEyt/tObQO8s5CMPmYYq14uClGH4abBuQ= +github.com/fatih/color v1.12.0/go.mod h1:ELkj/draVOlAH/xkhN6mQ50Qd0MPOk5AAr3maGEBuJM= +github.com/felixge/httpsnoop v1.0.3/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ= github.com/fsnotify/fsnotify v1.7.0 h1:8JEhPFa5W2WU7YfeZzPNqzMP6Lwt7L2715Ggo0nosvA= github.com/fsnotify/fsnotify v1.7.0/go.mod h1:40Bi/Hjc2AVfZrqy+aj+yEI+/bRxZnMJyTJwOpGvigM= +github.com/getkin/kin-openapi v0.120.0/go.mod h1:PCWw/lfBrJY4HcdqE3jj+QFkaFK8ABoqo7PvqVhXXqw= github.com/ghodss/yaml v1.0.0 h1:wQHKEahhL6wmXdzwWG11gIVCkOv05bNOh+Rxn0yngAk= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= +github.com/go-chi/chi/v5 v5.0.11/go.mod h1:DslCQbL2OYiznFReuXYUmQ2hGd1aDpCnlMNITLSKoi8= +github.com/go-chi/cors v1.2.1/go.mod h1:sSbTewc+6wYHBBCW7ytsFSn836hqM7JxpglAy2Vzc58= +github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= github.com/go-kit/log v0.2.1 h1:MRVx0/zhvdseW+Gza6N9rVzU/IVzaeE1SFI4raAhmBU= github.com/go-kit/log v0.2.1/go.mod h1:NwTd00d/i8cPZ3xOwwiv2PO5MOcx78fFErGNcVmBjv0= +github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE= +github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk= github.com/go-logfmt/logfmt v0.6.0 h1:wGYYu3uicYdqXVgoYbvnkrPVXkuLM1p1ifugDMEdRi4= github.com/go-logfmt/logfmt v0.6.0/go.mod h1:WYhtIu8zTZfxdn5+rREduYbwxfcBr/Vr6KEVveWlfTs= github.com/go-logr/logr v1.3.0 h1:2y3SDp0ZXuc6/cjLSZ+Q3ir+QB9T/iG5yYRXqsagWSY= github.com/go-logr/logr v1.3.0/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY= +github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE= github.com/go-logr/zapr v1.3.0 h1:XGdV8XW8zdwFiwOA2Dryh1gj2KRQyOOoNmBy4EplIcQ= github.com/go-logr/zapr v1.3.0/go.mod h1:YKepepNBd1u/oyhd/yQmtjVXmm9uML4IXUgMOwR8/Gg= github.com/go-ole/go-ole v1.2.6 h1:/Fpf6oFPoeFik9ty7siob0G6Ke8QvQEuVcuChpwXzpY= @@ -98,11 +292,21 @@ github.com/go-openapi/jsonreference v0.20.2/go.mod h1:Bl1zwGIM8/wsvqjsOQLJ/SH+En github.com/go-openapi/swag v0.22.3/go.mod h1:UzaqsxGiab7freDnrUUra0MwWfN/q7tE4j+VcZ0yl14= github.com/go-openapi/swag v0.22.4 h1:QLMzNJnMGPRNDCbySlcj1x01tzU8/9LTTL9hZZZogBU= github.com/go-openapi/swag v0.22.4/go.mod h1:UzaqsxGiab7freDnrUUra0MwWfN/q7tE4j+VcZ0yl14= +github.com/go-redis/redis/v8 v8.11.5/go.mod h1:gREzHqY1hg6oD9ngVRbLStwAWKhA0FEgq8Jd4h5lpwo= +github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= github.com/go-task/slim-sprig v0.0.0-20210107165309-348f09dbbbc0/go.mod h1:fyg7847qk6SyHyPtNmDHnmrv/HOrqktSC+C9fM+CJOE= github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572 h1:tfuBGBXKqDEevZMzYi5KSi8KkcZtzBcTgAUUtapy0OI= github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572/go.mod h1:9Pwr4B2jHnOSGXyyzV8ROjYa2ojvAY6HCGYYfMoC3Ls= +github.com/gobuffalo/flect v1.0.2/go.mod h1:A5msMlrHtLqh9umBSnvabjsMrCcCpAyzglnDvkbYKHs= +github.com/gobwas/glob v0.2.3/go.mod h1:d3Ez4x06l9bZtSvzIay5+Yzi0fmZzPgnTbPcKjJAkT8= +github.com/gofrs/flock v0.8.1/go.mod h1:F1TvTiK9OcQqauNUHlbJvyl9Qa1QvF/gOUDKA14jxHU= +github.com/gofrs/uuid/v5 v5.0.0/go.mod h1:CDOjlDMVAtN56jqyRUZh58JT31Tiw7/oQyEXZV+9bD8= +github.com/gogo/googleapis v1.4.0/go.mod h1:5YRNX2z1oM5gXdAkurHa942MDgEJyk02w4OecKY87+c= +github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= +github.com/golang-jwt/jwt v3.2.2+incompatible/go.mod h1:8pz2t5EyA70fFQQSrl6XZXzqecmYZeUEB8OUGHkxJ+I= +github.com/golang-jwt/jwt/v4 v4.5.0/go.mod h1:m21LjoU+eqJr34lmDMbreY2eSTRJ1cv77w39/MY0Ch0= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= github.com/golang/glog v1.2.0 h1:uCdmnmatrKCgMBlM4rMuJZWOkPDqdbZPnrMXDY4gI68= github.com/golang/glog v1.2.0/go.mod h1:6AhwSGph0fcJtXVM/PEHPqZlFeoLxhs7/t5UDAwmO+w= @@ -112,6 +316,7 @@ github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da/go.mod h1:cIg4er github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= github.com/golang/mock v1.2.0/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= github.com/golang/mock v1.3.1/go.mod h1:sBzyDLLjw3U8JLTeZvSv8jJB+tU5PVekmnlKIyFUx0Y= +github.com/golang/mock v1.6.0/go.mod h1:p6yTPP+5HYm5mzsMV8JkE6ZKdX+/wYM6Hr+LicevLPs= github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= @@ -122,8 +327,12 @@ github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaS github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= github.com/golang/protobuf v1.5.3 h1:KhyjKVUg7Usr/dYsdSqoFveMYd5ko72D+zANwlG1mmg= github.com/golang/protobuf v1.5.3/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= +github.com/golang/snappy v0.0.4/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= 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/btree v1.0.1/go.mod h1:xXMiIv4Fb/0kKde4SpL7qlzvu5cMJDRkFDxJfI9uaxA= +github.com/google/cel-go v0.16.1/go.mod h1:HXZKzB0LXqer5lHHgfWAnlYwJaQBDKMjxjulNQzhwhY= +github.com/google/gnostic v0.6.9/go.mod h1:Nm8234We1lq6iB9OmlgNv3nH91XLLVZHCDayfA3xq+E= github.com/google/gnostic-models v0.6.8 h1:yo/ABAfM5IMRsS1VnXjTBvUb61tFIHozhlYvRgGre9I= github.com/google/gnostic-models v0.6.8/go.mod h1:5n7qKqH0f5wFt+aWF8CW6pZLLNOfYuF5OpfBSENuI8U= github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M= @@ -137,9 +346,15 @@ github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/go-containerregistry v0.16.1 h1:rUEt426sR6nyrL3gt+18ibRcvYpKYdpsa5ZW7MA08dQ= github.com/google/go-containerregistry v0.16.1/go.mod h1:u0qB2l7mvtWVR5kNcbFIhFY1hLbf8eeGapA+vbFDCtQ= +github.com/google/go-containerregistry/pkg/authn/k8schain v0.0.0-20230209165335-3624968304fd/go.mod h1:x5fIlj5elU+/eYF60q4eASMQ9kDc+GMFa7UU9M3mFFw= +github.com/google/go-containerregistry/pkg/authn/kubernetes v0.0.0-20230209165335-3624968304fd/go.mod h1:6pjZpt+0dg+Z0kUEn53qLtD57raiZo/bqWzsuX6dDjo= +github.com/google/go-github/v27 v27.0.6/go.mod h1:/0Gr8pJ55COkmv+S/yPKCczSkUPIM/LnFyubufRNIS0= +github.com/google/go-pkcs11 v0.2.1-0.20230907215043-c6f79328ddf9/go.mod h1:6eQoGcuNJpa7jnd5pMGdkSaQpNDYvPlXWMcjXXThLlY= +github.com/google/go-querystring v1.0.0/go.mod h1:odCYkC5MyYFN7vkCjXpyrEuKhc/BUO6wN/zVPAxq5ck= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/gofuzz v1.2.0 h1:xRy4A+RhZaiKjJ1bPfwQ8sedCA+YS2YcCHW6ec7JMi0= github.com/google/gofuzz v1.2.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= +github.com/google/mako v0.0.0-20190821191249-122f8dcef9e3/go.mod h1:YzLcVlL+NqWnmUEPuhS1LxDDwGO9WNbVlEXaF4IH35g= github.com/google/martian v2.1.0+incompatible h1:/CP5g8u/VJHijgedC/Legn3BAbAaWPgecwXBIDzw5no= github.com/google/martian v2.1.0+incompatible/go.mod h1:9I4somxYTbIHy5NJKHRl3wXiIaQGbYVAs8BPL6v8lEs= github.com/google/martian/v3 v3.3.2 h1:IqNFLAmvJOgVlpdEBiQbDc2EwKW77amAycfTuWKdfvw= @@ -159,9 +374,16 @@ github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+ github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= github.com/googleapis/gax-go/v2 v2.12.0 h1:A+gCJKdRfqXkr+BIRGtZLibNXf0m1f9E4HG56etFpas= github.com/googleapis/gax-go/v2 v2.12.0/go.mod h1:y+aIqrI5eb1YGMVJfuV3185Ts/D7qKpsEkdD5+I6QGU= +github.com/googleapis/gnostic v0.5.5/go.mod h1:7+EbHbldMins07ALC74bsA81Ovc97DwqyJO1AENw9kA= github.com/googleapis/google-cloud-go-testing v0.0.0-20210719221736-1c9a4c676720 h1:zC34cGQu69FG7qzJ3WiKW244WfhDC3xxYMeNOX2gtUQ= github.com/googleapis/google-cloud-go-testing v0.0.0-20210719221736-1c9a4c676720/go.mod h1:dvDLG8qkwmyD9a/MJJN3XJcT3xFxOKAvTZGvuZmac9g= +github.com/gorilla/mux v1.8.0/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So= +github.com/gorilla/websocket v1.5.1/go.mod h1:x3kM2JMyaluk02fnUJpQuwD2dCS5NDG2ZHL0uE0tcaY= +github.com/gregjones/httpcache v0.0.0-20180305231024-9cad4c3443a7/go.mod h1:FecbI9+v66THATjSRHfNgh1IVFe/9kFxbXtjV0ctIMA= +github.com/grpc-ecosystem/go-grpc-middleware v1.3.0/go.mod h1:z0ButlSOZa5vEBq9m2m2hlwIgKw+rp3sdCBRoJY+30Y= +github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway v1.16.0 h1:gmcG1KaJ57LophUzW0Hy8NmPhnMZb4M0+kPpLofRdBo= +github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw= github.com/grpc-ecosystem/grpc-gateway/v2 v2.18.1 h1:6UKoz5ujsI55KNpsJH3UwCq3T8kKbZwNZBNPuTTje8U= github.com/grpc-ecosystem/grpc-gateway/v2 v2.18.1/go.mod h1:YvJ2f6MplWDhfxiUC3KpyTy76kYUZA4W3pTv/wdKQ9Y= github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4= @@ -171,22 +393,42 @@ github.com/hashicorp/go-multierror v1.1.1 h1:H5DkEtf6CXdFp0N0Em5UCwQpXMWke8IA0+l github.com/hashicorp/go-multierror v1.1.1/go.mod h1:iw975J/qwKPdAO1clOe2L8331t/9/fmwbPZ6JB6eMoM= github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= +github.com/hashicorp/golang-lru v1.0.2/go.mod h1:iADmTwqILo4mZ8BN3D2Q6+9jd8WM5uGBxy+E8yxSoD4= +github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ= github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= github.com/imdario/mergo v0.3.16 h1:wwQJbIsHYGMUyLSPrEq1CT16AhnhNJQ51+4fdHUnCl4= github.com/imdario/mergo v0.3.16/go.mod h1:WBLT9ZmE3lPoWsEzCh9LPo3TiwVN+ZKEjmz+hD27ysY= +github.com/inconshreveable/mousetrap v1.1.0/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= +github.com/influxdata/influxdb-client-go/v2 v2.9.0/go.mod h1:x7Jo5UHHl+w8wu8UnGiNobDDHygojXwJX4mx7rXGKMk= +github.com/influxdata/line-protocol v0.0.0-20200327222509-2487e7298839/go.mod h1:xaLFMmpvUxqXtVkUJfg9QmT88cDaCJ3ZKgdZ78oO8Qo= +github.com/influxdata/tdigest v0.0.1/go.mod h1:Z0kXnxzbTC2qrx4NaIzYkE1k66+6oEDQTvL95hQFh5Y= +github.com/insomniacslk/dhcp v0.0.0-20230516061539-49801966e6cb/go.mod h1:7474bZ1YNCvarT6WFKie4kEET6J0KYRDC4XJqqXzQW4= +github.com/invopop/yaml v0.2.0/go.mod h1:2XuRLgs/ouIrW3XNzuNj7J3Nvu/Dig5MXvbCEdiBN3Q= +github.com/jessevdk/go-flags v1.4.0/go.mod h1:4FA24M0QyGHXBuZZK/XkWh8h0e1EYbRYJSGM75WSRxI= github.com/jmespath/go-jmespath v0.4.0 h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9YPoQUg= github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo= github.com/jmespath/go-jmespath/internal/testify v1.5.1 h1:shLQSRRSCCPj3f2gpwzGwWFoC7ycTf1rcQZHOlsJ6N8= github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfCI6z80xFu9LTZmf1ZRjMHUOPmWr69U= +github.com/jonboulle/clockwork v0.2.2/go.mod h1:Pkfl5aHPm1nk2H9h0bjmnJD/BcgbGXUBGnn1kMkgxc8= github.com/josharian/intern v1.0.0 h1:vlS4z54oSdjm0bgjRigI+G1HpF+tI+9rE5LLzOg8HmY= github.com/josharian/intern v1.0.0/go.mod h1:5DoeVV0s6jJacbCEi61lwdGj/aVlrQvzHFFd8Hwg//Y= +github.com/josharian/native v1.1.0/go.mod h1:7X/raswPFr05uY3HiLlYeyQntB6OO7E/d2Cu7qoaN2w= +github.com/jpillora/backoff v1.0.0/go.mod h1:J/6gKK9jxlEcS3zixgDgUAsiuZ7yrSoa/FX5e0EB2j4= +github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= +github.com/json-iterator/go v1.1.7/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM= github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHmT4TnhNGBo= github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU= +github.com/julienschmidt/httprouter v1.2.0/go.mod h1:SYymIcj16QtmaHHD7aYtjjsJG7VTCxuUUipMqKk8s4w= +github.com/julienschmidt/httprouter v1.3.0/go.mod h1:JR6WtHb+2LUe8TCKY3cZOxFyyO8IZAc4RVcycCCAKdM= +github.com/jzelinskie/stringz v0.0.0-20210414224931-d6a8ce844a70/go.mod h1:hHYbgxJuNLRw91CmpuFsYEOyQqpDVFg8pvEh23vy4P0= +github.com/kelseyhightower/envconfig v1.4.0/go.mod h1:cccZRl6mQpaq41TPp5QxidR+Sa3axMbJDNb//FQX6Gg= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= github.com/klauspost/compress v1.17.0 h1:Rnbp4K9EjcDuVuHtd0dgA4qNuv9yKDYKK1ulpJwgrqM= github.com/klauspost/compress v1.17.0/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE= +github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= +github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc= github.com/kr/pretty v0.2.1/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI= github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= github.com/kr/pretty v0.3.1/go.mod h1:hoEshYVHaxMs3cyo3Yncou5ZscifuDolrwPKZanG3xk= @@ -204,23 +446,41 @@ github.com/magiconair/properties v1.8.7 h1:IeQXZAiQcpL9mgcAe1Nu6cX9LLw6ExEHKjN0V github.com/magiconair/properties v1.8.7/go.mod h1:Dhd985XPs7jluiymwWYZ0G4Z61jb3vdS329zhj2hYo0= github.com/mailru/easyjson v0.7.7 h1:UGYAvKxe3sBsEDzO8ZeWOSlIQfWFlxbzLZe7hwFURr0= github.com/mailru/easyjson v0.7.7/go.mod h1:xzfreul335JAWq5oZzymOObrkdz5UnU4kGfJJLY9Nlc= +github.com/maistra/xns-informer v0.0.0-20230111124621-73ee35e5f523/go.mod h1:2DP6ps5pmbxaazskTazVHwwLF+RiW+EtcJqQxLBaWH8= +github.com/mattn/go-colorable v0.1.8/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= +github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU= +github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= +github.com/matttproud/golang_protobuf_extensions v1.0.4/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4= github.com/matttproud/golang_protobuf_extensions/v2 v2.0.0 h1:jWpvCLoY8Z/e3VKvlsiIGKtc+UG6U5vzxaoagmhXfyg= github.com/matttproud/golang_protobuf_extensions/v2 v2.0.0/go.mod h1:QUyp042oQthUoa9bqDv0ER0wrtXnBruoNd7aNjkbP+k= +github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= +github.com/mitchellh/mapstructure v1.5.0/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= +github.com/moby/moby v27.0.0+incompatible h1:aIzs7Gdy6LB4ySNX939Q1poGmqINepve2jXm2mFcobs= +github.com/moby/moby v27.0.0+incompatible/go.mod h1:fDXVQ6+S340veQPv35CzDahGBmHsiclFwfEygB/TWMc= github.com/moby/patternmatcher v0.6.0 h1:GmP9lR19aU5GqSSFko+5pRqHi+Ohk1O69aFiKkVGiPk= github.com/moby/patternmatcher v0.6.0/go.mod h1:hDPoyOpDY7OrrMDLaYoY3hf52gNCR/YOUYxkhApJIxc= +github.com/moby/spdystream v0.2.0/go.mod h1:f7i0iNDQJ059oMTcWxx8MA/zKFIuD/lY+0GqbN2Wy8c= +github.com/moby/sys/mountinfo v0.6.2/go.mod h1:IJb6JQeOklcdMU9F5xQ8ZALD+CUr5VlGpwtX+VE0rpI= github.com/moby/sys/sequential v0.5.0 h1:OPvI35Lzn9K04PBbCLW0g4LcFAJgHsvXsRyewg5lXtc= github.com/moby/sys/sequential v0.5.0/go.mod h1:tH2cOOs5V9MlPiXcQzRC+eEyab644PWKGRYaaV5ZZlo= github.com/moby/term v0.5.0 h1:xt8Q1nalod/v7BqbG21f8mQPqH+xAaC9C3N3wfWbVP0= github.com/moby/term v0.5.0/go.mod h1:8FzsFHVUBGZdbDsJw/ot+X+d5HLUbvklYLJ9uGfcI3Y= +github.com/moby/vpnkit v0.5.0/go.mod h1:KyjUrL9cb6ZSNNAUwZfqRjhwwgJ3BJN+kXh0t43WTUQ= github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= +github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= +github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M= github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= +github.com/mohae/deepcopy v0.0.0-20170929034955-c48cc78d4826/go.mod h1:TaXosZuwdSHYgviHp1DAtfrULt5eUgsSMsZf+YrPgl8= github.com/morikuni/aec v1.0.0 h1:nP9CBfwrvYnBRgY6qfDQkygYDmYwOilePFkwzv4dU8A= github.com/morikuni/aec v1.0.0/go.mod h1:BbKIizmSmc5MMPqRYbxO4ZU0S0+P200+tUnFx7PXmsc= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 h1:C3w9PqII01/Oq1c1nUAm88MOHcQC9l5mIlSMApZMrHA= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ= +github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= +github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= +github.com/mxk/go-flowrate v0.0.0-20140419014527-cca7078d478f/go.mod h1:ZdcZmHo+o7JKHSa8/e818NopupXU1YMK5fe1lsApnBw= github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= github.com/nxadm/tail v1.4.8 h1:nPr65rt6Y5JFSKQO7qToXr7pePgD6Gwiw05lkbyAQTE= github.com/nxadm/tail v1.4.8/go.mod h1:+ncqLTQzXmGhMZNUePPaPqPvBxHAIsmXswZKocGu+AU= @@ -234,6 +494,7 @@ github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7J github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo= github.com/onsi/gomega v1.30.0 h1:hvMK7xYz4D3HapigLTeGdId/NcfQx1VHMJc60ew99+8= github.com/onsi/gomega v1.30.0/go.mod h1:9sxs+SwGrKI0+PWe4Fxa9tFQQBG5xSsSbMXOI8PPpoQ= +github.com/open-policy-agent/opa v0.52.0/go.mod h1:2n99s7WY/BXZUWUOq10JdTgK+G6XM4FYGoe7kQ5Vg0s= github.com/opencontainers/go-digest v1.0.0 h1:apOUWs51W5PlhuyGyz9FCeeBIOUDA/6nW8Oi/yOhh5U= github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM= github.com/opencontainers/image-spec v1.1.0-rc5 h1:Ygwkfw9bpDvs+c9E34SdgGOj41dX/cbdlwvlWt0pnFI= @@ -244,6 +505,13 @@ github.com/opendatahub-io/model-registry v0.1.1 h1:q5KJIRhOAwUarodz/SP1NDx25rUNc github.com/opendatahub-io/model-registry v0.1.1/go.mod h1:LlAAyLOh4Fn3AESXKXpgfERzQlBeTSyYex1vrDIgog0= github.com/openshift/api v3.9.0+incompatible h1:fJ/KsefYuZAjmrr3+5U9yZIZbTOpVkDDLDLFresAeYs= github.com/openshift/api v3.9.0+incompatible/go.mod h1:dh9o4Fs58gpFXGSYfnVxGR9PnV53I8TW84pQaJDdGiY= +github.com/openzipkin/zipkin-go v0.4.2/go.mod h1:ZeVkFjuuBiSy13y8vpSDCjMi9GoI3hPpCJSBx/EYFhY= +github.com/pegasus-kv/thrift v0.13.0/go.mod h1:Gl9NT/WHG6ABm6NsrbfE8LiJN0sAyneCrvB4qN4NPqQ= +github.com/pelletier/go-toml/v2 v2.1.0/go.mod h1:tJU2Z3ZkXwnxa4DPO899bsyIoywizdUvyaeZurnPPDc= +github.com/perimeterx/marshmallow v1.1.5/go.mod h1:dsXbUu8CRzfYP5a87xpp0xq9S3u0Vchtcl8we9tYaXw= +github.com/peterbourgon/diskv v2.0.1+incompatible/go.mod h1:uqqh8zWWbv1HBMNONnaR/tNboyR3/BZd58JJSHlUSCU= +github.com/pierrec/lz4/v4 v4.1.17/go.mod h1:gZWDp/Ze/IJXGXf23ltt2EXimqmTUXEy0GFuRQyBid4= +github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= @@ -252,39 +520,73 @@ github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 h1:Jamvg5psRI github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/power-devops/perfstat v0.0.0-20210106213030-5aafc221ea8c h1:ncq/mPwQF4JjgDlrVEn3C11VoGHZN7m8qihwgMEtzYw= github.com/power-devops/perfstat v0.0.0-20210106213030-5aafc221ea8c/go.mod h1:OmDBASR4679mdNQnz2pUhc2G8CO2JrUAVFDRBDP/hJE= +github.com/pquerna/cachecontrol v0.0.0-20201205024021-ac21108117ac/go.mod h1:hoLfEwdY11HjRfKFH6KqnPsfxlo3BP6bJehpDv8t6sQ= github.com/prometheus-operator/prometheus-operator/pkg/apis/monitoring v0.64.1 h1:bvntWler8vOjDJtxBwGDakGNC6srSZmgawGM9Jf7HC8= github.com/prometheus-operator/prometheus-operator/pkg/apis/monitoring v0.64.1/go.mod h1:cfNgxpCPGyIydmt3HcwDqKDt0nYdlGRhzftl+DZH7WA= +github.com/prometheus/client_golang v0.9.1/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw= +github.com/prometheus/client_golang v1.0.0/go.mod h1:db9x61etRT2tGnBNRi70OPL5FsnadC4Ky3P0J6CfImo= +github.com/prometheus/client_golang v1.1.0/go.mod h1:I1FGZT9+L76gKKOs5djB6ezCbFQP1xR9D75/vuwEF3g= github.com/prometheus/client_golang v1.17.0 h1:rl2sfwZMtSthVU752MqfjQozy7blglC+1SOtjMAMh+Q= github.com/prometheus/client_golang v1.17.0/go.mod h1:VeL+gMmOAxkS2IqfCq0ZmHSL+LjWfWDUmp1mBz9JgUY= +github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= +github.com/prometheus/client_model v0.0.0-20190129233127-fd36f4220a90/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/prometheus/client_model v0.5.0 h1:VQw1hfvPvk3Uv6Qf29VrPF32JB6rtbgI6cYPYQjL0Qw= github.com/prometheus/client_model v0.5.0/go.mod h1:dTiFglRmd66nLR9Pv9f0mZi7B7fk5Pm3gvsjB5tr+kI= +github.com/prometheus/common v0.4.1/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= +github.com/prometheus/common v0.6.0/go.mod h1:eBmuwkDJBwy6iBfxCBob6t6dR6ENT/y+J+Zk0j9GMYc= github.com/prometheus/common v0.45.0 h1:2BGz0eBc2hdMDLnO/8n0jeB3oPrt2D08CekT0lneoxM= github.com/prometheus/common v0.45.0/go.mod h1:YJmSTw9BoKxJplESWWxlbyttQR4uaEcGyv9MZjVOJsY= +github.com/prometheus/procfs v0.0.0-20181005140218-185b4288413d/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= +github.com/prometheus/procfs v0.0.2/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA= +github.com/prometheus/procfs v0.0.3/go.mod h1:4A/X28fw3Fc593LaREMrKMqOKvUAntwMDaekg4FpcdQ= github.com/prometheus/procfs v0.12.0 h1:jluTpSng7V9hY0O2R9DzzJHYb2xULk9VTR1V1R/k6Bo= github.com/prometheus/procfs v0.12.0/go.mod h1:pcuDEFsWDnvcgNzo4EEweacyhjeA9Zk3cnaOZAZEfOo= github.com/prometheus/statsd_exporter v0.25.0 h1:gpVF1TMf1UqMJmBDpzBYrEaGOFMpbMBYYYUDwM38Y/I= github.com/prometheus/statsd_exporter v0.25.0/go.mod h1:HwzfSvg6ehmb0Qg71ZuFrlgj5XQt9C+MGVLz5Gt5lqc= +github.com/rcrowley/go-metrics v0.0.0-20200313005456-10cdbea86bc0/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4= github.com/rogpeppe/go-internal v1.10.0 h1:TMyTOH3F/DB16zRVcYyreMH6GnZZrwQVAoYjRBZyWFQ= github.com/rogpeppe/go-internal v1.10.0/go.mod h1:UQnix2H7Ngw/k4C5ijL5+65zddjncjaFoBhdsK/akog= +github.com/rootless-containers/rootlesskit v1.1.1 h1:F5psKWoWY9/VjZ3ifVcaosjvFZJOagX85U22M0/EQZE= +github.com/rootless-containers/rootlesskit v1.1.1/go.mod h1:UD5GoA3dqKCJrnvnhVgQQnweMF2qZnf9KLw8EewcMZI= +github.com/rs/dnscache v0.0.0-20211102005908-e0241e321417/go.mod h1:qe5TWALJ8/a1Lqznoc5BDHpYX/8HU60Hm2AwRmqzxqA= +github.com/russross/blackfriday v1.6.0/go.mod h1:ti0ldHuxg49ri4ksnFxlkCfN+hvslNlmVHqNRXXJNAY= +github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= +github.com/sagikazarmark/locafero v0.4.0/go.mod h1:Pe1W6UlPYUk/+wc/6KFhbORCfqzgYEpgQ3O5fPuL3H4= +github.com/sagikazarmark/slog-shim v0.1.0/go.mod h1:SrcSrq8aKtyuqEI1uvTDTK1arOWRIczQRv+GVI1AkeQ= github.com/shirou/gopsutil/v3 v3.23.9 h1:ZI5bWVeu2ep4/DIxB4U9okeYJ7zp/QLTO4auRb/ty/E= github.com/shirou/gopsutil/v3 v3.23.9/go.mod h1:x/NWSb71eMcjFIO0vhyGW5nZ7oSIgVjrCnADckb85GA= github.com/shoenig/go-m1cpu v0.1.6 h1:nxdKQNcEB6vzgA2E2bvzKIYRuNj7XNJ4S/aRSwKzFtM= github.com/shoenig/go-m1cpu v0.1.6/go.mod h1:1JJMcUBvfNwpq05QDQVAnx3gUHr9IYF7GNg9SUEw2VQ= +github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= github.com/sirupsen/logrus v1.9.3 h1:dueUQJ1C2q9oE3F7wvmSGAaVtTmUizReu6fjN8uqzbQ= github.com/sirupsen/logrus v1.9.3/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= +github.com/soheilhy/cmux v0.1.5/go.mod h1:T7TcVDs9LWfQgPlPsdngu6I6QIoyIFZDDC6sNE1GqG0= +github.com/songgao/water v0.0.0-20200317203138-2b4b6d7c09d8/go.mod h1:P5HUIBuIWKbyjl083/loAegFkfbFNx5i2qEP4CNbm7E= +github.com/sourcegraph/conc v0.3.0/go.mod h1:Sdozi7LEKbFPqYX2/J+iBAM6HpqSLTASQIKqDmF7Mt0= +github.com/spaolacci/murmur3 v1.1.0/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= +github.com/spf13/afero v1.11.0/go.mod h1:GH9Y3pIexgf1MTIWtNGyogA5MwRIDXGUr+hbWNoBjkY= +github.com/spf13/cast v1.6.0/go.mod h1:ancEpBxwJDODSW/UG4rDrAqiKolqNNh2DX3mk86cAdo= +github.com/spf13/cobra v1.8.0/go.mod h1:WXLWApfZ71AjXPya3WOlMsY9yMs7YeiHhFVlvLyhcho= github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= +github.com/spf13/viper v1.18.2/go.mod h1:EKmWIqdnk5lOcmR72yw6hS+8OPYcwD0jteitLMVB+yk= +github.com/stoewer/go-strcase v1.2.0/go.mod h1:IBiWB2sKIp3wVVQ3Y035++gc+knqhUQag1KpM8ahLw8= 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= github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo= +github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA= +github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk= github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= +github.com/subosito/gotenv v1.6.0/go.mod h1:Dk4QP5c2W3ibzajGcXpNraDfq2IrhjMIvMSWPKKo0FU= +github.com/tchap/go-patricia/v2 v2.3.1/go.mod h1:VZRHKAb53DLaG+nA9EaYYiaEx6YztwDlLElMsnSHD4k= github.com/testcontainers/testcontainers-go v0.26.0 h1:uqcYdoOHBy1ca7gKODfBd9uTHVK3a7UL848z09MVZ0c= github.com/testcontainers/testcontainers-go v0.26.0/go.mod h1:ICriE9bLX5CLxL9OFQ2N+2N+f+803LNJ1utJb1+Inx0= github.com/tidwall/gjson v1.17.0 h1:/Jocvlh98kcTfpN2+JzGQWQcqrPQwDrVEMApx/M5ZwM= @@ -298,16 +600,50 @@ github.com/tklauser/go-sysconf v0.3.12 h1:0QaGUFOdQaIVdPgfITYzaTegZvdCjmYO52cSFA github.com/tklauser/go-sysconf v0.3.12/go.mod h1:Ho14jnntGE1fpdOqQEEaiKRpvIavV0hSfmBq8nJbHYI= github.com/tklauser/numcpus v0.6.1 h1:ng9scYS7az0Bk4OZLvrNXNSAO2Pxr1XXRAPyjhIx+Fk= github.com/tklauser/numcpus v0.6.1/go.mod h1:1XfjsgE2zo8GVw7POkMbHENHzVg3GzmoZ9fESEdAacY= +github.com/tmc/grpc-websocket-proxy v0.0.0-20220101234140-673ab2c3ae75/go.mod h1:KO6IkyS8Y3j8OdNO85qEYBsRPuteD+YciPomcXdrMnk= +github.com/tsenart/go-tsz v0.0.0-20180814235614-0bd30b3df1c3/go.mod h1:SWZznP1z5Ki7hDT2ioqiFKEse8K9tU2OUvaRI0NeGQo= +github.com/tsenart/vegeta/v12 v12.11.1/go.mod h1:swiFmrgpqj2llHURgHYFRFN0tfrIrlnspg01HjwOnSQ= +github.com/u-root/uio v0.0.0-20230305220412-3e8cd9d6bf63/go.mod h1:eLL9Nub3yfAho7qB0MzZizFhTU2QkLeoVsWdHtDW264= +github.com/urfave/cli/v2 v2.25.5/go.mod h1:GHupkWPMM0M/sj1a2b4wUrWBPzazNrIjouW6fmdJLxc= +github.com/vbatts/tar-split v0.11.3/go.mod h1:9QlHN18E+fEH7RdG+QAJJcuya3rqT7eXSTY7wGrAokY= +github.com/xeipuuv/gojsonpointer v0.0.0-20190905194746-02993c407bfb/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU= +github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415/go.mod h1:GwrjFmJcFw6At/Gs6z4yjiIwzuJ1/+UwLxMQDVQXShQ= +github.com/xeipuuv/gojsonschema v1.2.0/go.mod h1:anYRn/JVcOK2ZgGU+IjEV4nwlhoK5sQluxsYJ78Id3Y= +github.com/xhit/go-str2duration/v2 v2.1.0/go.mod h1:ohY8p+0f07DiV6Em5LKB0s2YpLtXVyJfNt1+BlmyAsU= +github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU= +github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673/go.mod h1:N3UwUGtsrSj3ccvlPHLoLsHnpR27oXr4ZE984MbSER8= +github.com/yashtewari/glob-intersection v0.1.0/go.mod h1:LK7pIC3piUjovexikBbJ26Yml7g8xa5bsjfx2v1fwok= github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= github.com/yusufpapurcu/wmi v1.2.3 h1:E1ctvB7uKFMOJw3fdOW32DwGE9I7t++CRUEMKvFoFiw= github.com/yusufpapurcu/wmi v1.2.3/go.mod h1:SBZ9tNy3G9/m5Oi98Zks0QjeHVDvuK0qfxQmPyzfmi0= +go.etcd.io/bbolt v1.3.7/go.mod h1:N9Mkw9X8x5fupy0IKsmuqVtoGDyxsaDlbk4Rd05IAQw= +go.etcd.io/etcd/api/v3 v3.5.9/go.mod h1:uyAal843mC8uUVSLWz6eHa/d971iDGnCRpmKd2Z+X8k= +go.etcd.io/etcd/client/pkg/v3 v3.5.9/go.mod h1:y+CzeSmkMpWN2Jyu1npecjB9BBnABxGM4pN8cGuJeL4= +go.etcd.io/etcd/client/v2 v2.305.9/go.mod h1:0NBdNx9wbxtEQLwAQtrDHwx58m02vXpDcgSYI2seohQ= +go.etcd.io/etcd/client/v3 v3.5.9/go.mod h1:i/Eo5LrZ5IKqpbtpPDuaUnDOUv471oDg8cjQaUr2MbA= +go.etcd.io/etcd/pkg/v3 v3.5.9/go.mod h1:BZl0SAShQFk0IpLWR78T/+pyt8AruMHhTNNX73hkNVY= +go.etcd.io/etcd/raft/v3 v3.5.9/go.mod h1:WnFkqzFdZua4LVlVXQEGhmooLeyS7mqzS4Pf4BCVqXg= +go.etcd.io/etcd/server/v3 v3.5.9/go.mod h1:GgI1fQClQCFIzuVjlvdbMxNbnISt90gdfYyqiAIt65g= go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU= go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8= go.opencensus.io v0.24.0 h1:y73uSU6J157QMP2kn2r30vwW1A2W2WFwSCGnAVxeaD0= go.opencensus.io v0.24.0/go.mod h1:vNK8G9p7aAivkbmorf4v+7Hgx+Zs0yY+0fOtgBfjQKo= +go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.40.0/go.mod h1:UMklln0+MRhZC4e3PwmN3pCtq4DyIadWw4yikh6bNrw= +go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.44.0/go.mod h1:SeQhzAEccGVZVEy7aH87Nh0km+utSpo1pTv6eMMop48= +go.opentelemetry.io/otel v1.14.0/go.mod h1:o4buv+dJzx8rohcUeRmWUZhqupFvzWis188WlggnNeU= +go.opentelemetry.io/otel/exporters/otlp/internal/retry v1.14.0/go.mod h1:UFG7EBMRdXyFstOwH028U0sVf+AvukSGhF0g8+dmNG8= +go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.14.0/go.mod h1:HrbCVv40OOLTABmOn1ZWty6CHXkU8DK/Urc43tHug70= +go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.14.0/go.mod h1:5w41DY6S9gZrbjuq6Y+753e96WfPha5IcsOSZTtullM= +go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp v1.14.0/go.mod h1:+N7zNjIJv4K+DeX67XXET0P+eIciESgaFDBqh+ZJFS4= +go.opentelemetry.io/otel/metric v0.37.0/go.mod h1:DmdaHfGt54iV6UKxsV9slj2bBRJcKC1B1uvDLIioc1s= +go.opentelemetry.io/otel/sdk v1.14.0/go.mod h1:bwIC5TjrNG6QDCHNWvW4HLHtUQ4I+VQDsnjhvyZCALM= +go.opentelemetry.io/otel/trace v1.14.0/go.mod h1:8avnQLK+CG77yNLUae4ea2JDQ6iT+gozhnZjy/rw9G8= +go.opentelemetry.io/proto/otlp v0.19.0/go.mod h1:H7XAot3MsfNsj7EXtrA2q5xSNQ10UqI405h3+duxN4U= go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= +go.uber.org/atomic v1.11.0/go.mod h1:LUxbIzbOniOlMKjJjyPfpl4v+PKK2cNJn91OQbhoJI0= +go.uber.org/automaxprocs v1.5.3/go.mod h1:eRbA25aqJrxAbsLO0xy5jVwPt7FQnRgjW+efnwa1WM0= go.uber.org/goleak v1.2.1 h1:NBol2c7O1ZokfZ0LEU9K6Whx/KnwvepVetCUhtKja4A= go.uber.org/goleak v1.2.1/go.mod h1:qlT2yGI9QafXHhZZLxlSuNsMw3FFLxBr+tBRlmO1xH4= go.uber.org/multierr v1.1.0/go.mod h1:wR5kodmAFQ0UK8QlbwjlSNy0Z68gJhDJUG5sjR94q/0= @@ -316,6 +652,7 @@ go.uber.org/multierr v1.11.0/go.mod h1:20+QtiLqy0Nd6FdQB9TLXag12DsQkrbs3htMFfDN8 go.uber.org/zap v1.10.0/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= go.uber.org/zap v1.26.0 h1:sI7k6L95XOKS281NhVKOFCUNIvv9e0w4BF8N3u+tCRo= go.uber.org/zap v1.26.0/go.mod h1:dtElttAiwGvoJ/vj4IwHBS/gXsEu/pZ50mUIRWuG0so= +golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= @@ -357,7 +694,9 @@ golang.org/x/sync v0.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.5.0 h1:60k92dhOjHxJkrqnwsfl8KuaHbn/5dl0lUPUklKo3qE= golang.org/x/sync v0.5.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sys v0.0.0-20181116152217-5ac8a444bdc5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -365,12 +704,14 @@ golang.org/x/sys v0.0.0-20190502145724-3ef323f4f1fd/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20190507160741-ecd444e8653b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20190801041406-cbf593c0f2f3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191120155948-bd437916bb0e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210112080510-489259a85091/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.18.0 h1:DBdB3niSjOA/O0blCZBqDefyWNYveAYMNF1Wum0DYQ4= @@ -441,6 +782,7 @@ google.golang.org/genproto v0.0.0-20231106174013-bbf56f31fb17 h1:wpZ8pe2x1Q3f2Ky google.golang.org/genproto v0.0.0-20231106174013-bbf56f31fb17/go.mod h1:J7XzRzVy1+IPwWHZUzoD0IccYZIrXILAQpc+Qy9CMhY= google.golang.org/genproto/googleapis/api v0.0.0-20231106174013-bbf56f31fb17 h1:JpwMPBpFN3uKhdaekDpiNlImDdkUAyiJ6ez/uxGaUSo= google.golang.org/genproto/googleapis/api v0.0.0-20231106174013-bbf56f31fb17/go.mod h1:0xJLfVdJqpAPl8tDg1ujOCGzx6LFLttXT5NhllGOXY4= +google.golang.org/genproto/googleapis/bytestream v0.0.0-20231030173426-d783a09b4405/go.mod h1:GRUCuLdzVqZte8+Dl/D4N25yLzcGqqWaYkeVOwulFqw= google.golang.org/genproto/googleapis/rpc v0.0.0-20231120223509-83a465c0220f h1:ultW7fxlIvee4HYrtnaRPon9HpEgFk5zYpmfMgtKB5I= google.golang.org/genproto/googleapis/rpc v0.0.0-20231120223509-83a465c0220f/go.mod h1:L9KNLi232K1/xB6f7AlSX692koaRnKaWSR0stBki0Yc= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= @@ -454,14 +796,20 @@ google.golang.org/grpc v1.61.0 h1:TOvOcuXn30kRao+gfcvsebNEa5iZIiLkisYEkf7R7o0= google.golang.org/grpc v1.61.0/go.mod h1:VUbo7IFqmF1QtCAstipjG0GIoq49KvMe9+h1jFLBNJs= google.golang.org/protobuf v1.33.0 h1:uNO2rsAINq/JlFpSdYEKIZ0uKD/R9cpdv0T+yoGwGmI= google.golang.org/protobuf v1.33.0/go.mod h1:c6P6GXX6sHbq/GpV6MGZEdwhWPcYBgnhAHhKbcUYpos= +gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys= gopkg.in/inf.v0 v0.9.1 h1:73M5CoZyi3ZLMOyDlQh031Cx6N9NDJ2Vvfl76EDAgDc= gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw= +gopkg.in/ini.v1 v1.67.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= +gopkg.in/natefinch/lumberjack.v2 v2.2.1/go.mod h1:YD8tP3GAjkrDg1eZH7EGmyESg/lsYskCTPBJVb9jqSc= +gopkg.in/square/go-jose.v2 v2.5.1/go.mod h1:M9dMgbHiYLoDGQrXy7OpJDJWiKiU//h+vD76mk0e1AI= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= +gopkg.in/tomb.v2 v2.0.0-20161208151619-d5d1b5820637/go.mod h1:BHsqpu/nsuzkT5BpiH1EMZPLyqSMM8JbIavyFACoFNk= +gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= @@ -473,6 +821,7 @@ gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gotest.tools v2.2.0+incompatible h1:VsBPFP1AI068pPrMxtb/S8Zkgf9xEmTLJjfM+P5UIEo= gotest.tools v2.2.0+incompatible/go.mod h1:DsYFclhRJ6vuDpmuTbkuFWG+y2sxOXAzmJt81HFBacw= +gotest.tools/v3 v3.4.0/go.mod h1:CtbdzLSsqVhDgMtKsx03ird5YTGB3ar27v0u/yKBW5g= honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190418001031-e561f6794a2a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= @@ -487,16 +836,23 @@ k8s.io/apiextensions-apiserver v0.28.4 h1:AZpKY/7wQ8n+ZYDtNHbAJBb+N4AXXJvyZx6ww6 k8s.io/apiextensions-apiserver v0.28.4/go.mod h1:pgQIZ1U8eJSMQcENew/0ShUTlePcSGFq6dxSxf2mwPM= k8s.io/apimachinery v0.28.4 h1:zOSJe1mc+GxuMnFzD4Z/U1wst50X28ZNsn5bhgIIao8= k8s.io/apimachinery v0.28.4/go.mod h1:wI37ncBvfAoswfq626yPTe6Bz1c22L7uaJ8dho83mgg= +k8s.io/apiserver v0.28.4/go.mod h1:Idq71oXugKZoVGUUL2wgBCTHbUR+FYTWa4rq9j4n23w= k8s.io/client-go v0.28.4 h1:Np5ocjlZcTrkyRJ3+T3PkXDpe4UpatQxj85+xjaD2wY= k8s.io/client-go v0.28.4/go.mod h1:0VDZFpgoZfelyP5Wqu0/r/TRYcLYuJ2U1KEeoaPa1N4= +k8s.io/code-generator v0.28.4/go.mod h1:OQAfl6bZikQ/tK6faJ18Vyzo54rUII2NmjurHyiN1g4= k8s.io/component-base v0.28.4 h1:c/iQLWPdUgI90O+T9TeECg8o7N3YJTiuz2sKxILYcYo= k8s.io/component-base v0.28.4/go.mod h1:m9hR0uvqXDybiGL2nf/3Lf0MerAfQXzkfWhUY58JUbU= +k8s.io/gengo v0.0.0-20230829151522-9cce18d56c01/go.mod h1:FiNAH4ZV3gBg2Kwh89tzAEV2be7d5xI0vBa/VySYy3E= +k8s.io/klog v1.0.0/go.mod h1:4Bi6QPql/J/LkTDqv7R/cd3hPo4k2DG6Ptcz060Ez5I= k8s.io/klog/v2 v2.110.1 h1:U/Af64HJf7FcwMcXyKm2RPM22WZzyR7OSpYj5tg3cL0= k8s.io/klog/v2 v2.110.1/go.mod h1:YGtd1984u+GgbuZ7e08/yBuAfKLSO0+uR1Fhi6ExXjo= +k8s.io/kms v0.28.4/go.mod h1:HL4/lR/bhjAJPbqycKtfhWiKh1Sp21cpHOL8P4oo87w= k8s.io/kube-openapi v0.0.0-20231113174909-778a5567bc1e h1:snPmy96t93RredGRjKfMFt+gvxuVAncqSAyBveJtr4Q= k8s.io/kube-openapi v0.0.0-20231113174909-778a5567bc1e/go.mod h1:AsvuZPBlUDVuCdzJ87iajxtXuR9oktsTctW/R9wwouA= k8s.io/utils v0.0.0-20230726121419-3b25d923346b h1:sgn3ZU783SCgtaSJjpcVVlRqd6GSnlTLKgpAAttJvpI= k8s.io/utils v0.0.0-20230726121419-3b25d923346b/go.mod h1:OLgZIPagt7ERELqWJFomSt595RzquPNLL48iOWgYOg0= +knative.dev/caching v0.0.0-20231017130712-54d0758671ef/go.mod h1:plGN+mIBKRtVxZ0vQeZ3Gt02RIaj0niwIMnQNkQHycw= +knative.dev/hack v0.0.0-20231109190034-5deaddeb51a7/go.mod h1:yk2OjGDsbEnQjfxdm0/HJKS2WqTLEFg/N6nUs6Rqx3Q= knative.dev/networking v0.0.0-20231115015815-3af9769712cd h1:VDtYz+hybqIAEp8NM2tAi2QV4D8Cc5DWLoXLi5IcZjE= knative.dev/networking v0.0.0-20231115015815-3af9769712cd/go.mod h1:HQ3rA7qrKVWvZUl6GGQefn/PzNXlX4e94KpbwBEjFcQ= knative.dev/pkg v0.0.0-20231115001034-97c7258e3a98 h1:uvOLwp5Ar7oJlaYEszh51CemuZc1sRRI14xzKhUEF3U= @@ -506,8 +862,10 @@ knative.dev/serving v0.39.3/go.mod h1:bWylSgwnRZeL659qy7m3/TZioYk25TIfusPUEeR695 maistra.io/api v0.0.0-20230417135504-0536f6c22b1c h1:WNBqA7R23P/TDkzP/wa3mfE4Bd9eM8NzWiwhcNyWAgk= maistra.io/api v0.0.0-20230417135504-0536f6c22b1c/go.mod h1:YdrOpeJBddUNHKIuhqlsNje9YUBFHl2pho7mhYwmsYs= rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= +sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.1.2/go.mod h1:+qG7ISXqCDVVcyO8hLn12AKVYYUjM7ftlqsqmrhMZE0= sigs.k8s.io/controller-runtime v0.16.3 h1:2TuvuokmfXvDUamSx1SuAOO3eTyye+47mJCigwG62c4= sigs.k8s.io/controller-runtime v0.16.3/go.mod h1:j7bialYoSn142nv9sCOJmQgDXQXxnroFU4VnX/brVJ0= +sigs.k8s.io/controller-tools v0.7.0/go.mod h1:bpBAo0VcSDDLuWt47evLhMLPxRPxMDInTEH/YbdeMK0= sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd h1:EDPBXCAspyGV4jQlpZSudPeMmr1bNJefnuqLsRAsHZo= sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd/go.mod h1:B8JuhiUyNFVKdsE8h686QcCxMaH6HrOAZj4vswFpcB0= sigs.k8s.io/structured-merge-diff/v4 v4.4.1 h1:150L+0vs/8DA78h1u02ooW1/fFq/Lwr+sGiqlzvrtq4= diff --git a/main.go b/main.go index 2e7f7b32..74949498 100644 --- a/main.go +++ b/main.go @@ -19,12 +19,14 @@ package main import ( "context" "flag" + "os" + "strconv" + "github.com/opendatahub-io/odh-model-controller/controllers/webhook" + corev1 "k8s.io/api/core/v1" knservingv1 "knative.dev/serving/pkg/apis/serving/v1" - "os" "sigs.k8s.io/controller-runtime/pkg/builder" "sigs.k8s.io/controller-runtime/pkg/metrics/server" - "strconv" // to ensure that exec-entrypoint and run can make use of them. // Import all Kubernetes client auth plugins (e.g. Azure, GCP, OIDC, etc.) @@ -59,8 +61,7 @@ func init() { //nolint:gochecknoinits //reason this way we ensure schemes are al // +kubebuilder:rbac:groups=serving.kserve.io,resources=servingruntimes/finalizers,verbs=get;list;watch;create;update;patch;delete // +kubebuilder:rbac:groups=networking.istio.io,resources=virtualservices,verbs=get;list;watch;create;update;patch;delete // +kubebuilder:rbac:groups=networking.istio.io,resources=virtualservices/finalizers,verbs=get;list;watch;create;update;patch;delete -// +kubebuilder:rbac:groups=networking.istio.io,resources=gateways,verbs=get;list;watch;create;update;patch;delete -// +kubebuilder:rbac:groups=networking.istio.io,resources=gateways/finalizers,verbs=get;list;watch;create;update;patch;delete +// +kubebuilder:rbac:groups=networking.istio.io,resources=gateways,verbs=get;list;watch;update;patch // +kubebuilder:rbac:groups=security.istio.io,resources=peerauthentications,verbs=get;list;watch;create;update;patch;delete // +kubebuilder:rbac:groups=security.istio.io,resources=authorizationpolicies,verbs=get;list // +kubebuilder:rbac:groups=telemetry.istio.io,resources=telemetries,verbs=get;list;watch;create;update;patch;delete @@ -198,6 +199,16 @@ func main() { setupLog.Error(err, "unable to setup Knative Service validating Webhook") os.Exit(1) } + + // Set up the mutating webhook using the builder + err = builder.WebhookManagedBy(mgr). + For(&corev1.Service{}). + WithDefaulter(webhook.NewKserveServiceMutator(mgr.GetClient())). + Complete() + if err != nil { + setupLog.Error(err, "unable to setup Kserve Service mutating Webhook") + os.Exit(1) + } } else { setupLog.Info("Skipping setup of Knative Service validating Webhook, because KServe Serverless setup seems to be disabled in the DataScienceCluster resource.") } From 69fa39e1080277c070f3cff09e5f490a8b2e6e3b Mon Sep 17 00:00:00 2001 From: jooho lee Date: Thu, 20 Jun 2024 19:09:15 -0400 Subject: [PATCH 06/13] gateway name change,unit test use eventually Signed-off-by: jooho lee --- ...kserve_inferenceservice_controller_test.go | 167 +++++++----------- .../kserve_isvc_gateway_reconciler.go | 70 +++----- .../kserve_isvc_service_cert_reconciler.go | 131 -------------- ..._serverless_inferenceservice_reconciler.go | 1 - 4 files changed, 87 insertions(+), 282 deletions(-) delete mode 100644 controllers/reconcilers/kserve_isvc_service_cert_reconciler.go diff --git a/controllers/kserve_inferenceservice_controller_test.go b/controllers/kserve_inferenceservice_controller_test.go index 29634568..4280c571 100644 --- a/controllers/kserve_inferenceservice_controller_test.go +++ b/controllers/kserve_inferenceservice_controller_test.go @@ -17,6 +17,7 @@ package controllers import ( "context" + "fmt" "time" "strings" @@ -104,49 +105,6 @@ var _ = Describe("The Openshift Kserve model controller", func() { }, timeout, interval).Should(Succeed()) }) - // It("With a new Kserve InferenceService, serving cert annotation should be added to the runtime Service object.", func() { - // // We need to stub the cluster state and indicate where is istio namespace (reusing authConfig test data) - // if dsciErr := createDSCI(DSCIWithoutAuthorization); dsciErr != nil && !errors.IsAlreadyExists(dsciErr) { - // Fail(dsciErr.Error()) - // } - // // Create a new InferenceService - // inferenceService := &kservev1beta1.InferenceService{} - // err := convertToStructuredResource(KserveInferenceServicePath1, inferenceService) - // Expect(err).NotTo(HaveOccurred()) - // inferenceService.SetNamespace(testNs) - // Expect(cli.Create(ctx, inferenceService)).Should(Succeed()) - - // // Update the URL of the InferenceService to indicate it is ready. - // deployedInferenceService := &kservev1beta1.InferenceService{} - // err = cli.Get(ctx, types.NamespacedName{Name: inferenceService.Name, Namespace: inferenceService.Namespace}, deployedInferenceService) - // Expect(err).NotTo(HaveOccurred()) - - // // url, err := apis.ParseURL("https://example-onnx-mnist-default.test.com") - // Expect(err).NotTo(HaveOccurred()) - // newAddress := &duckv1.Addressable{ - // URL: apis.HTTPS("example-onnx-mnist-default.test.com"), - // } - // deployedInferenceService.Status.Address = newAddress - - // err = cli.Status().Update(ctx, deployedInferenceService) - // Expect(err).NotTo(HaveOccurred()) - - // // Stub: Create a Kserve Service, which must be created by the KServe operator. - // svc := &corev1.Service{} - // err = convertToStructuredResource(testIsvcSvcPath, svc) - // Expect(err).NotTo(HaveOccurred()) - // svc.SetNamespace(inferenceService.Namespace) - // Expect(cli.Create(ctx, svc)).Should(Succeed()) - - // err = cli.Status().Update(ctx, deployedInferenceService) - // Expect(err).NotTo(HaveOccurred()) - - // isvcService, err := waitForService(cli, testNs, inferenceService.Name, 5, 2*time.Second) - // Expect(err).NotTo(HaveOccurred()) - - // Expect(isvcService.Annotations[constants.ServingCertAnnotationKey]).Should(Equal(inferenceService.Name)) - // }) - It("should create a secret for runtime and update kserve local gateway in the istio-system namespace", func() { // We need to stub the cluster state and indicate where is istio namespace (reusing authConfig test data) if dsciErr := createDSCI(DSCIWithoutAuthorization); dsciErr != nil && !errors.IsAlreadyExists(dsciErr) { @@ -187,14 +145,27 @@ var _ = Describe("The Openshift Kserve model controller", func() { Expect(err).NotTo(HaveOccurred()) // Verify that the certificate secret is created in the istio-system namespace. - _, err = waitForSecret(cli, constants.IstioNamespace, inferenceService.Name, 5, 5*time.Second) - Expect(err).NotTo(HaveOccurred()) + Eventually(func() error { + secret := &corev1.Secret{} + err := cli.Get(ctx, client.ObjectKey{Namespace: constants.IstioNamespace, Name: fmt.Sprintf("%s-%s", inferenceService.Name, inferenceService.Namespace)}, secret) + if err != nil { + return err + } + return nil + }, timeout, interval).Should(Succeed()) - gateway, err := waitForUpdatedGatewayCompletion(cli, "add", constants.IstioNamespace, constants.KServeGatewayName, inferenceService.Name, 5, 2*time.Second) - Expect(err).NotTo(HaveOccurred()) + // Verify that the gateway is updated in the istio-system namespace. + var gateway *istioclientv1beta1.Gateway + Eventually(func() error { + gateway, err = waitForUpdatedGatewayCompletion(cli, "add", constants.IstioNamespace, constants.KServeGatewayName, inferenceService.Name) + if err != nil { + return err + } + return nil + }, timeout, interval).Should(Succeed()) // Ensure that the server is successfully added to the KServe local gateway within the istio-system namespace. - targetServerExist := isServerExistFromGateway(gateway, inferenceService.Name) + targetServerExist := isServerExistFromGateway(gateway, fmt.Sprintf("%s-%s", "https", inferenceService.Name)) Expect(targetServerExist).Should(BeTrue()) }) @@ -291,14 +262,26 @@ var _ = Describe("The Openshift Kserve model controller", func() { Expect(err).NotTo(HaveOccurred()) // Verify that the certificate secret is created in the istio-system namespace. - _, err = waitForSecret(cli, constants.IstioNamespace, inferenceService.Name, 5, 2*time.Second) - Expect(err).NotTo(HaveOccurred()) - - gateway, err := waitForUpdatedGatewayCompletion(cli, "add", constants.IstioNamespace, constants.KServeGatewayName, inferenceService.Name, 5, 2*time.Second) - Expect(err).NotTo(HaveOccurred()) + Eventually(func() error { + secret := &corev1.Secret{} + err := cli.Get(ctx, client.ObjectKey{Namespace: constants.IstioNamespace, Name: fmt.Sprintf("%s-%s", inferenceService.Name, inferenceService.Namespace)}, secret) + if err != nil { + return err + } + return nil + }, timeout, interval).Should(Succeed()) + // Verify that the gateway is updated in the istio-system namespace. + var gateway *istioclientv1beta1.Gateway + Eventually(func() error { + gateway, err = waitForUpdatedGatewayCompletion(cli, "add", constants.IstioNamespace, constants.KServeGatewayName, inferenceService.Name) + if err != nil { + return err + } + return nil + }, timeout, interval).Should(Succeed()) // Ensure that the server is successfully added to the KServe local gateway within the istio-system namespace. - targetServerExist := isServerExistFromGateway(gateway, inferenceService.Name) + targetServerExist := isServerExistFromGateway(gateway, fmt.Sprintf("%s-%s", "https", inferenceService.Name)) Expect(targetServerExist).Should(BeTrue()) }) @@ -309,8 +292,15 @@ var _ = Describe("The Openshift Kserve model controller", func() { Expect(err).NotTo(HaveOccurred()) Expect(cli.Delete(ctx, deployedInferenceService)).Should(Succeed()) - gateway, err := waitForUpdatedGatewayCompletion(cli, "delete", constants.IstioNamespace, constants.KServeGatewayName, isvcName, 5, 2*time.Second) - Expect(err).NotTo(HaveOccurred()) + // Verify that the gateway is updated in the istio-system namespace. + var gateway *istioclientv1beta1.Gateway + Eventually(func() error { + gateway, err = waitForUpdatedGatewayCompletion(cli, "add", constants.IstioNamespace, constants.KServeGatewayName, isvcName) + if err != nil { + return err + } + return nil + }, timeout, interval).Should(Succeed()) // Ensure that the server is successfully removed from the KServe local gateway within the istio-system namespace. targetServerExist := isServerExistFromGateway(gateway, isvcName) @@ -352,61 +342,30 @@ func getKServeRouteName(isvc *kservev1beta1.InferenceService) string { return isvc.Name + "-" + isvc.Namespace } -func waitForService(cli client.Client, namespace, serviceName string, maxTries int, delay time.Duration) (*corev1.Service, error) { - time.Sleep(delay) - +func waitForUpdatedGatewayCompletion(cli client.Client, op string, namespace, gatewayName string, isvcName string) (*istioclientv1beta1.Gateway, error) { ctx := context.Background() - service := &corev1.Service{} - for try := 1; try <= maxTries; try++ { - err := cli.Get(ctx, client.ObjectKey{Namespace: namespace, Name: serviceName}, service) - if err == nil { - if service.GetAnnotations() == nil { - time.Sleep(1 * time.Second) - continue - } - return service, nil - } - if !errors.IsNotFound(err) { - continue - } + gateway := &istioclientv1beta1.Gateway{} - if try < maxTries { - time.Sleep(1 * time.Second) - return nil, err - } + // Get the Gateway resource + err := cli.Get(ctx, client.ObjectKey{Namespace: namespace, Name: gatewayName}, gateway) + if err != nil { + return nil, fmt.Errorf("failed to get Gateway: %w", err) } - return service, nil -} -// This function waits for the updated gateway completion after a specified delay. -// During the wait, it checks the gateway repeatedly until the specified operation (add or delete) is completed or the maximum number of tries is reached. -// If the maximum number of tries is exceeded, it returns an error. -func waitForUpdatedGatewayCompletion(cli client.Client, op string, namespace, gatewayName string, isvcName string, maxTries int, delay time.Duration) (*istioclientv1beta1.Gateway, error) { - time.Sleep(delay) - - ctx := context.Background() - gateway := &istioclientv1beta1.Gateway{} - for try := 1; try <= maxTries; try++ { - err := cli.Get(ctx, client.ObjectKey{Namespace: namespace, Name: gatewayName}, gateway) - if err == nil { - if op == "add" && !isServerExistFromGateway(gateway, isvcName) { - time.Sleep(1 * time.Second) - continue - } else if op == "delete" && isServerExistFromGateway(gateway, isvcName) { - time.Sleep(1 * time.Second) - continue - } - return gateway, nil + // Check conditions based on operation (op) + switch op { + case "add": + if !isServerExistFromGateway(gateway, fmt.Sprintf("%s-%s", "https", isvcName)) { + return nil, fmt.Errorf("server %s not found in Gateway %s", isvcName, gatewayName) } - if !errors.IsNotFound(err) { - continue - } - - if try < maxTries { - time.Sleep(1 * time.Second) - return nil, err + case "delete": + if isServerExistFromGateway(gateway, fmt.Sprintf("%s-%s", "https", isvcName)) { + return nil, fmt.Errorf("server %s still exists in Gateway %s", isvcName, gatewayName) } + default: + return nil, fmt.Errorf("unsupported operation: %s", op) } + return gateway, nil } diff --git a/controllers/reconcilers/kserve_isvc_gateway_reconciler.go b/controllers/reconcilers/kserve_isvc_gateway_reconciler.go index 7a9688a0..c1be4811 100644 --- a/controllers/reconcilers/kserve_isvc_gateway_reconciler.go +++ b/controllers/reconcilers/kserve_isvc_gateway_reconciler.go @@ -36,15 +36,11 @@ import ( istioclientv1beta1 "istio.io/client-go/pkg/apis/networking/v1beta1" ) -// const ( -// internalSerivceHostnameDomain = "svc.cluster.local" -// opendatahubManagedLabelName = "opendatahub.io/managed='true'" -// secretCheckInterval = 1 * time.Second -// maxSecretCheckAttempts = 5 -// ) - var _ SubResourceReconciler = (*KserveGatewayReconciler)(nil) var meshNamespace string +var destSecretName string +var srcSecretName string +var portName string type KserveGatewayReconciler struct { client client.Client @@ -64,12 +60,15 @@ func NewKserveGatewayReconciler(client client.Client) *KserveGatewayReconciler { func (r *KserveGatewayReconciler) Reconcile(ctx context.Context, log logr.Logger, isvc *kservev1beta1.InferenceService) error { log.V(1).Info("Reconciling KServe local gateway for Kserve InferenceService") - _, meshNamespace = utils.GetIstioControlPlaneName(ctx, r.client) log.V(1).Info("AAAAA1", "meshNamespace", meshNamespace) log.V(1).Info("AAAAA2", "isvc", isvc) + _, meshNamespace = utils.GetIstioControlPlaneName(ctx, r.client) + destSecretName = fmt.Sprintf("%s-%s", isvc.Name, isvc.Namespace) + portName = fmt.Sprintf("%s-%s", "https", isvc.Name) + // return if Address.URL is not set - if isvc.Status.Address == nil { + if isvc.Status.Address != nil && isvc.Status.Address.URL == nil { log.V(1).Info("Waiting for the URL as the Inference Service is not ready yet") return nil } @@ -84,7 +83,7 @@ func (r *KserveGatewayReconciler) Reconcile(ctx context.Context, log logr.Logger return err } // return if serving cert secret in the destination namespace is not created - _, err = r.secretHandler.Get(ctx, types.NamespacedName{Name: isvc.Name, Namespace: meshNamespace}) + _, err = r.secretHandler.Get(ctx, types.NamespacedName{Name: destSecretName, Namespace: meshNamespace}) if err != nil { if errors.IsNotFound(err) { if err := r.copyServingCertSecretFromIsvcNamespace(ctx, certSecret, isvc); err != nil { @@ -97,31 +96,6 @@ func (r *KserveGatewayReconciler) Reconcile(ctx context.Context, log logr.Logger return err } - // destinationSecretExist := true - // if _, err := r.secretHandler.Get(ctx, types.NamespacedName{Name: isvc.Name, Namespace: meshNamespace}); err != nil { - // if errors.IsNotFound(err) { - // destinationSecretExist = false - // } else { - // return err - // } - // } - - // if !destinationSecretExist { - // secret := &corev1.Secret{} - // for attempt := 1; attempt <= maxSecretCheckAttempts; attempt++ { - // getSecretErr := r.client.Get(ctx, types.NamespacedName{Name: isvc.Name, Namespace: isvc.Namespace}, secret) - // if getSecretErr == nil { - // break - // } - // if errors.IsNotFound(getSecretErr) { - // log.V(2).Info("The certificate secret is not created yet. Retrying...", "attempt_number", attempt) - // time.Sleep(secretCheckInterval) - // } else { - // log.Error(getSecretErr, "Failed to retrieve the certificate secret for the InferenceService (ISVC)") - // return getSecretErr - // } - // } - // Create Desired resource desiredResource, err := r.getDesiredResource(isvc) if err != nil { @@ -157,12 +131,12 @@ func (r *KserveGatewayReconciler) getDesiredResource(isvc *kservev1beta1.Inferen { Hosts: []string{hostname}, Port: &istiov1beta1.Port{ - Name: isvc.Name, + Name: portName, Number: 8445, Protocol: "HTTPS", }, Tls: &istiov1beta1.ServerTLSSettings{ - CredentialName: isvc.Name, + CredentialName: destSecretName, Mode: istiov1beta1.ServerTLSSettings_SIMPLE, }, }, @@ -178,16 +152,22 @@ func (r *KserveGatewayReconciler) getExistingResource(ctx context.Context) (*ist } func (r *KserveGatewayReconciler) Delete(ctx context.Context, log logr.Logger, isvc *kservev1beta1.InferenceService) error { - log.V(1).Info(fmt.Sprintf("Deleting serving cert secret(%s) in the namespace(%s)", isvc.Name, isvc.Namespace)) - if err := r.deleteServingCertSecretInIstioNamespace(ctx, isvc.Name); err != nil { + var errs []error + + log.V(1).Info(fmt.Sprintf("Deleting serving cert secret(%s) in the namespace(%s)", destSecretName, isvc.Namespace)) + if err := r.deleteServingCertSecretInIstioNamespace(ctx, destSecretName); err != nil { log.V(1).Error(err, "Failed to delete the copied serving cert secret in the namespace") - return err + errs = append(errs, err) } - log.V(1).Info(fmt.Sprintf("Deleting the Server(%s) from KServe local gateway in the istio-system namespace", isvc.Name)) - if err := r.removeServerFromGateway(ctx, log, isvc.Name); err != nil { + log.V(1).Info(fmt.Sprintf("Deleting the Server(%s) from KServe local gateway in the istio-system namespace", portName)) + if err := r.removeServerFromGateway(ctx, log, portName); err != nil { log.V(1).Error(err, "Failed to remove the server from KServe local gateway in the istio-system namespace") - return err + errs = append(errs, err) + } + + if len(errs) > 0 { + return fmt.Errorf("multiple errors: %v", errs) } return nil @@ -219,7 +199,6 @@ func (r *KserveGatewayReconciler) processDelta(ctx context.Context, log logr.Log } func (r *KserveGatewayReconciler) removeServerFromGateway(ctx context.Context, log logr.Logger, serverToRemove string) error { - gateway, err := r.gatewayHandler.Get(ctx, types.NamespacedName{Name: constants.KServeGatewayName, Namespace: meshNamespace}) if err != nil { log.V(1).Error(err, "Failed to retrieve KServe local gateway in istio-system namespace") @@ -243,10 +222,9 @@ func (r *KserveGatewayReconciler) removeServerFromGateway(ctx context.Context, l } func (r *KserveGatewayReconciler) copyServingCertSecretFromIsvcNamespace(ctx context.Context, sourceSecret *corev1.Secret, isvc *kservev1beta1.InferenceService) error { - fmt.Print("AAAAA2", "meshNamespace", meshNamespace) destinationSecret := &corev1.Secret{ ObjectMeta: metav1.ObjectMeta{ - Name: sourceSecret.Name, + Name: fmt.Sprintf("%s-%s", sourceSecret.Name, sourceSecret.Namespace), Namespace: meshNamespace, }, Data: sourceSecret.Data, diff --git a/controllers/reconcilers/kserve_isvc_service_cert_reconciler.go b/controllers/reconcilers/kserve_isvc_service_cert_reconciler.go deleted file mode 100644 index 119743ce..00000000 --- a/controllers/reconcilers/kserve_isvc_service_cert_reconciler.go +++ /dev/null @@ -1,131 +0,0 @@ -/* - -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 reconcilers - -import ( - "context" - - "github.com/go-logr/logr" - kservev1beta1 "github.com/kserve/kserve/pkg/apis/serving/v1beta1" - "github.com/opendatahub-io/odh-model-controller/controllers/constants" - "github.com/opendatahub-io/odh-model-controller/controllers/resources" - v1 "k8s.io/api/core/v1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/types" - "sigs.k8s.io/controller-runtime/pkg/client" -) - -var _ SubResourceReconciler = (*KserveIsvcServiceReconciler)(nil) - -type KserveIsvcServiceReconciler struct { - client client.Client - serviceHandler resources.ServiceHandler -} - -func NewKserveIsvcServiceReconciler(client client.Client) *KserveIsvcServiceReconciler { - return &KserveIsvcServiceReconciler{ - client: client, - serviceHandler: resources.NewServiceHandler(client), - } -} - -func (r *KserveIsvcServiceReconciler) Delete(ctx context.Context, log logr.Logger, isvc *kservev1beta1.InferenceService) error { - // NOOP - Resources are deleted along with the deletion of InferenceServices - return nil -} - -func (r *KserveIsvcServiceReconciler) Cleanup(_ context.Context, _ logr.Logger, _ string) error { - // NOOP - Resources are deleted along with the deletion of InferenceServices - return nil -} - -func (r *KserveIsvcServiceReconciler) Reconcile(ctx context.Context, log logr.Logger, isvc *kservev1beta1.InferenceService) error { - log.V(1).Info("Reconciling InferenceService Service serving cert") - - // // return if URL is not set - // if isvc.Status.URL == nil { - // log.V(1).Info("Waiting for the URL as the Inference Service is not ready yet", "reconcile", isvc) - // return nil - // } - - // // Create Desired resource - // desiredResource, err := r.createDesiredResource(isvc) - // if err != nil { - // return err - // } - - // // Get Existing resource - // existingResource, err := r.getExistingResource(ctx, log, isvc) - // if err != nil { - // return err - // } - - // // Process Delta - // if err = r.processDelta(ctx, log, desiredResource, existingResource); err != nil { - // return err - // } - return nil -} - -func (r *KserveIsvcServiceReconciler) createDesiredResource(isvc *kservev1beta1.InferenceService) (*v1.Service, error) { - service := &v1.Service{ - ObjectMeta: metav1.ObjectMeta{ - Name: "isvc-service", - Annotations: map[string]string{ - constants.ServingCertAnnotationKey: isvc.Name, - }, - }, - } - return service, nil -} - -func (r *KserveIsvcServiceReconciler) getExistingResource(ctx context.Context, log logr.Logger, isvc *kservev1beta1.InferenceService) (*v1.Service, error) { - return r.serviceHandler.FetchService(ctx, log, types.NamespacedName{Name: isvc.Name, Namespace: isvc.Namespace}) -} - -func (r *KserveIsvcServiceReconciler) processDelta(ctx context.Context, log logr.Logger, desiredService *v1.Service, existingService *v1.Service) (err error) { - if isUpdated(desiredService, existingService, log) { - log.V(1).Info("Delta found", "update", existingService.GetName()) - service := existingService.DeepCopy() - if service.Annotations == nil { - service.Annotations = make(map[string]string) - } - service.Annotations = desiredService.Annotations - - if err = r.client.Update(ctx, service); err != nil { - return err - } - } - return nil -} - -func isUpdated(desiredService *v1.Service, existingService *v1.Service, log logr.Logger) bool { - if existingService == nil { - log.Info("The service for the InferenceService has not been created yet") - return false - } - deployedAnnotations := existingService.GetAnnotations() - - if len(deployedAnnotations) != 0 { - if val, exists := existingService.Annotations[constants.ServingCertAnnotationKey]; exists { - if val == desiredService.Annotations[constants.ServingCertAnnotationKey] { - return false - } - } - } - - return true -} diff --git a/controllers/reconcilers/kserve_serverless_inferenceservice_reconciler.go b/controllers/reconcilers/kserve_serverless_inferenceservice_reconciler.go index 52bc4eba..0a5ccaa3 100644 --- a/controllers/reconcilers/kserve_serverless_inferenceservice_reconciler.go +++ b/controllers/reconcilers/kserve_serverless_inferenceservice_reconciler.go @@ -45,7 +45,6 @@ func NewKServeServerlessInferenceServiceReconciler(client client.Client) *Kserve NewKServeIstioPeerAuthenticationReconciler(client), NewKServeNetworkPolicyReconciler(client), NewKserveAuthConfigReconciler(client), - NewKserveIsvcServiceReconciler(client), NewKserveGatewayReconciler(client), } From 53907718937d52e319704f6431766e5fea40c9e2 Mon Sep 17 00:00:00 2001 From: jooho lee Date: Fri, 21 Jun 2024 10:07:05 -0400 Subject: [PATCH 07/13] add cert rotate test Signed-off-by: jooho lee --- controllers/inferenceservice_controller.go | 17 --- ...kserve_inferenceservice_controller_test.go | 113 +++++++++++++----- .../kserve_isvc_gateway_reconciler.go | 55 +++++---- 3 files changed, 113 insertions(+), 72 deletions(-) diff --git a/controllers/inferenceservice_controller.go b/controllers/inferenceservice_controller.go index 29f03953..6f39659a 100644 --- a/controllers/inferenceservice_controller.go +++ b/controllers/inferenceservice_controller.go @@ -149,23 +149,6 @@ func (r *OpenshiftInferenceServiceReconciler) SetupWithManager(mgr ctrl.Manager) } return reconcileRequests })). - Watches(&corev1.Service{}, - handler.EnqueueRequestsFromMapFunc(func(ctx context.Context, o client.Object) []reconcile.Request { - r.log.Info("Reconcile event triggered by Service: " + o.GetName()) - isvc := &kservev1beta1.InferenceService{} - err := r.client.Get(ctx, types.NamespacedName{Name: o.GetName(), Namespace: o.GetNamespace()}, isvc) - if err != nil { - if apierrs.IsNotFound(err) { - return []reconcile.Request{} - } - r.log.Error(err, "Error getting the inferenceService", "name", o.GetName()) - return []reconcile.Request{} - } - - return []reconcile.Request{ - {NamespacedName: types.NamespacedName{Name: o.GetName(), Namespace: o.GetNamespace()}}, - } - })). Watches(&corev1.Secret{}, handler.EnqueueRequestsFromMapFunc(func(ctx context.Context, o client.Object) []reconcile.Request { r.log.Info("Reconcile event triggered by Secret: " + o.GetName()) diff --git a/controllers/kserve_inferenceservice_controller_test.go b/controllers/kserve_inferenceservice_controller_test.go index 4280c571..0aa1e54e 100644 --- a/controllers/kserve_inferenceservice_controller_test.go +++ b/controllers/kserve_inferenceservice_controller_test.go @@ -18,7 +18,6 @@ package controllers import ( "context" "fmt" - "time" "strings" @@ -165,7 +164,7 @@ var _ = Describe("The Openshift Kserve model controller", func() { }, timeout, interval).Should(Succeed()) // Ensure that the server is successfully added to the KServe local gateway within the istio-system namespace. - targetServerExist := isServerExistFromGateway(gateway, fmt.Sprintf("%s-%s", "https", inferenceService.Name)) + targetServerExist := hasServerFromGateway(gateway, fmt.Sprintf("%s-%s", "https", inferenceService.Name)) Expect(targetServerExist).Should(BeTrue()) }) @@ -197,7 +196,7 @@ var _ = Describe("The Openshift Kserve model controller", func() { }) }) - Context("when deleting a Kserve InferenceService", func() { + Context("when there is a existing inferenceService", func() { var testNs string var isvcName string @@ -280,36 +279,83 @@ var _ = Describe("The Openshift Kserve model controller", func() { } return nil }, timeout, interval).Should(Succeed()) + // Ensure that the server is successfully added to the KServe local gateway within the istio-system namespace. - targetServerExist := isServerExistFromGateway(gateway, fmt.Sprintf("%s-%s", "https", inferenceService.Name)) + targetServerExist := hasServerFromGateway(gateway, fmt.Sprintf("%s-%s", "https", inferenceService.Name)) Expect(targetServerExist).Should(BeTrue()) }) - It("should remove the Server from the kserve local gateway in istio-system and delete the created Secret", func() { - // Delete the existing ISVC - deployedInferenceService := &kservev1beta1.InferenceService{} - err := cli.Get(ctx, types.NamespacedName{Name: isvcName, Namespace: testNs}, deployedInferenceService) - Expect(err).NotTo(HaveOccurred()) - Expect(cli.Delete(ctx, deployedInferenceService)).Should(Succeed()) + When("serving cert Secret is rotated", func() { + It("should re-sync serving cert Secret to istio-system", func() { + deployedInferenceService := &kservev1beta1.InferenceService{} + err := cli.Get(ctx, types.NamespacedName{Name: isvcName, Namespace: testNs}, deployedInferenceService) + Expect(err).NotTo(HaveOccurred()) + + // Get source secret + srcSecret := &corev1.Secret{} + err = cli.Get(ctx, client.ObjectKey{Namespace: testNs, Name: deployedInferenceService.Name}, srcSecret) + Expect(err).NotTo(HaveOccurred()) + + // Update source secret + updatedDataString := "updateData" + srcSecret.Data["tls.crt"] = []byte(updatedDataString) + srcSecret.Data["tls.key"] = []byte(updatedDataString) + Expect(cli.Update(ctx, srcSecret)).Should(Succeed()) + + // Get destination secret + err = cli.Get(ctx, client.ObjectKey{Namespace: testNs, Name: deployedInferenceService.Name}, srcSecret) + Expect(err).NotTo(HaveOccurred()) + + // Verify that the certificate secret in the istio-system namespace is updated. + destSecret := &corev1.Secret{} + Eventually(func() error { + err := cli.Get(ctx, client.ObjectKey{Namespace: constants.IstioNamespace, Name: fmt.Sprintf("%s-%s", deployedInferenceService.Name, deployedInferenceService.Namespace)}, destSecret) + if err != nil { + return err + } + + if string(destSecret.Data["tls.crt"]) != updatedDataString { + return fmt.Errorf("destSecret is not updated yet") + } + return nil + }, timeout, interval).Should(Succeed()) + + Expect(destSecret.Data).To(Equal(srcSecret.Data)) + }) + }) - // Verify that the gateway is updated in the istio-system namespace. - var gateway *istioclientv1beta1.Gateway - Eventually(func() error { - gateway, err = waitForUpdatedGatewayCompletion(cli, "add", constants.IstioNamespace, constants.KServeGatewayName, isvcName) - if err != nil { + When("infereceService is deleted", func() { + It("should remove the Server from the kserve local gateway in istio-system and delete the created Secret", func() { + // Delete the existing ISVC + deployedInferenceService := &kservev1beta1.InferenceService{} + err := cli.Get(ctx, types.NamespacedName{Name: isvcName, Namespace: testNs}, deployedInferenceService) + Expect(err).NotTo(HaveOccurred()) + Expect(cli.Delete(ctx, deployedInferenceService)).Should(Succeed()) + + // Verify that the gateway is updated in the istio-system namespace. + var gateway *istioclientv1beta1.Gateway + Eventually(func() error { + gateway, err = waitForUpdatedGatewayCompletion(cli, "delete", constants.IstioNamespace, constants.KServeGatewayName, isvcName) + if err != nil { + return err + } + return nil + }, timeout, interval).Should(Succeed()) + + // Ensure that the server is successfully removed from the KServe local gateway within the istio-system namespace. + targetServerExist := hasServerFromGateway(gateway, isvcName) + Expect(targetServerExist).Should(BeFalse()) + + // Ensure that the synced Secret is successfully deleted within the istio-system namespace. + secret := &corev1.Secret{} + Eventually(func() error { + err := cli.Get(ctx, client.ObjectKey{Namespace: constants.IstioNamespace, Name: fmt.Sprintf("%s-%s", isvcName, constants.IstioNamespace)}, secret) + if err != nil && errors.IsNotFound(err) { + return nil + } return err - } - return nil - }, timeout, interval).Should(Succeed()) - - // Ensure that the server is successfully removed from the KServe local gateway within the istio-system namespace. - targetServerExist := isServerExistFromGateway(gateway, isvcName) - Expect(targetServerExist).Should(BeFalse()) - - // Ensure that the created Secret is successfully deleted within the istio-system namespace. - secret, err := waitForSecret(cli, constants.IstioNamespace, isvcName, 5, 2*time.Second) - Expect(err).To(HaveOccurred()) - Expect(secret).Should(BeNil()) + }, timeout, interval).Should(Succeed()) + }) }) }) @@ -344,6 +390,7 @@ func getKServeRouteName(isvc *kservev1beta1.InferenceService) string { func waitForUpdatedGatewayCompletion(cli client.Client, op string, namespace, gatewayName string, isvcName string) (*istioclientv1beta1.Gateway, error) { ctx := context.Background() + portName := fmt.Sprintf("%s-%s", "https", isvcName) gateway := &istioclientv1beta1.Gateway{} // Get the Gateway resource @@ -355,12 +402,12 @@ func waitForUpdatedGatewayCompletion(cli client.Client, op string, namespace, ga // Check conditions based on operation (op) switch op { case "add": - if !isServerExistFromGateway(gateway, fmt.Sprintf("%s-%s", "https", isvcName)) { - return nil, fmt.Errorf("server %s not found in Gateway %s", isvcName, gatewayName) + if !hasServerFromGateway(gateway, portName) { + return nil, fmt.Errorf("server %s not found in Gateway %s", portName, gatewayName) } case "delete": - if isServerExistFromGateway(gateway, fmt.Sprintf("%s-%s", "https", isvcName)) { - return nil, fmt.Errorf("server %s still exists in Gateway %s", isvcName, gatewayName) + if hasServerFromGateway(gateway, portName) { + return nil, fmt.Errorf("server %s still exists in Gateway %s", portName, gatewayName) } default: return nil, fmt.Errorf("unsupported operation: %s", op) @@ -370,10 +417,10 @@ func waitForUpdatedGatewayCompletion(cli client.Client, op string, namespace, ga } // checks if the server exists for the given gateway -func isServerExistFromGateway(gateway *istioclientv1beta1.Gateway, inferenceServiceName string) bool { +func hasServerFromGateway(gateway *istioclientv1beta1.Gateway, portName string) bool { targetServerExist := false for _, server := range gateway.Spec.Servers { - if server.Port.Name == inferenceServiceName { + if server.Port.Name == portName { targetServerExist = true break } diff --git a/controllers/reconcilers/kserve_isvc_gateway_reconciler.go b/controllers/reconcilers/kserve_isvc_gateway_reconciler.go index c1be4811..461e0124 100644 --- a/controllers/reconcilers/kserve_isvc_gateway_reconciler.go +++ b/controllers/reconcilers/kserve_isvc_gateway_reconciler.go @@ -18,6 +18,7 @@ package reconcilers import ( "context" "fmt" + "reflect" "github.com/go-logr/logr" kservev1beta1 "github.com/kserve/kserve/pkg/apis/serving/v1beta1" @@ -39,7 +40,6 @@ import ( var _ SubResourceReconciler = (*KserveGatewayReconciler)(nil) var meshNamespace string var destSecretName string -var srcSecretName string var portName string type KserveGatewayReconciler struct { @@ -60,8 +60,6 @@ func NewKserveGatewayReconciler(client client.Client) *KserveGatewayReconciler { func (r *KserveGatewayReconciler) Reconcile(ctx context.Context, log logr.Logger, isvc *kservev1beta1.InferenceService) error { log.V(1).Info("Reconciling KServe local gateway for Kserve InferenceService") - log.V(1).Info("AAAAA1", "meshNamespace", meshNamespace) - log.V(1).Info("AAAAA2", "isvc", isvc) _, meshNamespace = utils.GetIstioControlPlaneName(ctx, r.client) destSecretName = fmt.Sprintf("%s-%s", isvc.Name, isvc.Namespace) @@ -69,33 +67,41 @@ func (r *KserveGatewayReconciler) Reconcile(ctx context.Context, log logr.Logger // return if Address.URL is not set if isvc.Status.Address != nil && isvc.Status.Address.URL == nil { - log.V(1).Info("Waiting for the URL as the Inference Service is not ready yet") + log.V(1).Info("Waiting for the URL as the InferenceService is not ready yet") return nil } - // return if serving cert secret in the destination namespace is not created - certSecret, err := r.secretHandler.Get(ctx, types.NamespacedName{Name: isvc.Name, Namespace: isvc.Namespace}) + // return if serving cert secret in the source namespace is not created + srcCertSecret, err := r.secretHandler.Get(ctx, types.NamespacedName{Name: isvc.Name, Namespace: isvc.Namespace}) if err != nil { if errors.IsNotFound(err) { - log.V(1).Info("Waiting for creating serving cert secret in the inference service namespace") + log.V(1).Info(fmt.Sprintf("Waiting for the creation of the serving certificate Secret(%s) in %s namespace", isvc.Name, isvc.Namespace)) return nil } return err } - // return if serving cert secret in the destination namespace is not created - _, err = r.secretHandler.Get(ctx, types.NamespacedName{Name: destSecretName, Namespace: meshNamespace}) + + // Copy src secret to destination namespace when there is not the synced secret. + copiedCertSecret, err := r.secretHandler.Get(ctx, types.NamespacedName{Name: destSecretName, Namespace: meshNamespace}) if err != nil { if errors.IsNotFound(err) { - if err := r.copyServingCertSecretFromIsvcNamespace(ctx, certSecret, isvc); err != nil { - log.V(1).Error(err, "Failed to copy the Secret for InferenceService in the istio-system namespace") + if err := r.copyServingCertSecretFromIsvcNamespace(ctx, srcCertSecret, nil); err != nil { + log.V(1).Error(err, fmt.Sprintf("Failed to copy the serving certificate Secret(%s) for InferenceService in %s namespace", srcCertSecret.Name, meshNamespace)) return err } - log.V(1).Info("Waiting for creating serving cert secret in the inference service namespace") - return nil } return err } + // Recreate copied secrt when src secret is updated + if !reflect.DeepEqual(srcCertSecret.Data, copiedCertSecret.Data) { + log.V(1).Info(fmt.Sprintf("Recreating for serving certificate Secret(%s) in %s namespace", copiedCertSecret.Name, meshNamespace)) + if err := r.copyServingCertSecretFromIsvcNamespace(ctx, srcCertSecret, copiedCertSecret); err != nil { + log.V(1).Error(err, fmt.Sprintf("Failed to copy the Secret(%s) for InferenceService in %s namespace", copiedCertSecret.Name, meshNamespace)) + return err + } + } + // Create Desired resource desiredResource, err := r.getDesiredResource(isvc) if err != nil { @@ -106,7 +112,7 @@ func (r *KserveGatewayReconciler) Reconcile(ctx context.Context, log logr.Logger existingResource, err := r.getExistingResource(ctx) if err != nil { if errors.IsNotFound(err) { - log.Error(err, "Failed to find KServe local gateway in istio-system namespace") + log.Error(err, fmt.Sprintf("Failed to find KServe local gateway in %s namespace", meshNamespace)) } return err } @@ -154,15 +160,15 @@ func (r *KserveGatewayReconciler) getExistingResource(ctx context.Context) (*ist func (r *KserveGatewayReconciler) Delete(ctx context.Context, log logr.Logger, isvc *kservev1beta1.InferenceService) error { var errs []error - log.V(1).Info(fmt.Sprintf("Deleting serving cert secret(%s) in the namespace(%s)", destSecretName, isvc.Namespace)) + log.V(1).Info(fmt.Sprintf("Deleting serving certificate Secret(%s) in %s namespace", destSecretName, isvc.Namespace)) if err := r.deleteServingCertSecretInIstioNamespace(ctx, destSecretName); err != nil { - log.V(1).Error(err, "Failed to delete the copied serving cert secret in the namespace") + log.V(1).Error(err, fmt.Sprintf("Failed to delete the copied serving certificate Secret(%s) in %s namespace", destSecretName, isvc.Namespace)) errs = append(errs, err) } - log.V(1).Info(fmt.Sprintf("Deleting the Server(%s) from KServe local gateway in the istio-system namespace", portName)) + log.V(1).Info(fmt.Sprintf("Deleting the Server(%s) from KServe local gateway in the %s namespace", portName, meshNamespace)) if err := r.removeServerFromGateway(ctx, log, portName); err != nil { - log.V(1).Error(err, "Failed to remove the server from KServe local gateway in the istio-system namespace") + log.V(1).Error(err, fmt.Sprintf("Failed to remove the Server(%s) from KServe local gateway in the %s namespace", portName, meshNamespace)) errs = append(errs, err) } @@ -191,10 +197,8 @@ func (r *KserveGatewayReconciler) processDelta(ctx context.Context, log logr.Log log.V(1).Error(err, fmt.Sprintf("Failed to add the Server(%s) from KServe local gateway in the istio-system namespace", desiredGateway.Spec.Servers[0].Port.Name)) return err } - return nil } - return nil } @@ -221,16 +225,23 @@ func (r *KserveGatewayReconciler) removeServerFromGateway(ctx context.Context, l return nil } -func (r *KserveGatewayReconciler) copyServingCertSecretFromIsvcNamespace(ctx context.Context, sourceSecret *corev1.Secret, isvc *kservev1beta1.InferenceService) error { +func (r *KserveGatewayReconciler) copyServingCertSecretFromIsvcNamespace(ctx context.Context, sourceSecret *corev1.Secret, preDestSecret *corev1.Secret) error { destinationSecret := &corev1.Secret{ ObjectMeta: metav1.ObjectMeta{ - Name: fmt.Sprintf("%s-%s", sourceSecret.Name, sourceSecret.Namespace), + Name: destSecretName, Namespace: meshNamespace, }, Data: sourceSecret.Data, Type: sourceSecret.Type, } + // Remove old secret if src secret is updated + if preDestSecret != nil { + if err := r.client.Delete(ctx, preDestSecret); err != nil { + return err + } + } + if err := r.client.Create(ctx, destinationSecret); err != nil { return err } From d87ed6da875ce5cb86e4e4f6543c043d1d7dc122 Mon Sep 17 00:00:00 2001 From: jooho lee Date: Fri, 21 Jun 2024 10:54:39 -0400 Subject: [PATCH 08/13] fix merging conflict Signed-off-by: jooho lee --- main.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/main.go b/main.go index 5d5b1ca3..3972d118 100644 --- a/main.go +++ b/main.go @@ -132,7 +132,7 @@ func main() { }, Cache: cache.Options{ ByObject: map[client.Object]cache.ByObject{ - &v1.Secret{}: { + &corev1.Secret{}: { Label: labels.SelectorFromSet(labels.Set{ "opendatahub.io/managed": "true", }), From 572b8f856b74dde09c080cbe514560625ab6e516 Mon Sep 17 00:00:00 2001 From: jooho lee Date: Fri, 21 Jun 2024 22:42:04 -0400 Subject: [PATCH 09/13] fix merging main branch conflict Signed-off-by: jooho lee --- main.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/main.go b/main.go index 5d37b22e..104bd8ba 100644 --- a/main.go +++ b/main.go @@ -137,7 +137,7 @@ func main() { "opendatahub.io/managed": "true", }), }, - &v1.ConfigMap{}: { + &corev1.ConfigMap{}: { Label: labels.SelectorFromSet(labels.Set{ "app.opendatahub.io/kserve": "true", }), From de1451cb5d827c8efd124c642bf272fc50aa82ca Mon Sep 17 00:00:00 2001 From: jooho lee Date: Sat, 22 Jun 2024 00:35:20 -0400 Subject: [PATCH 10/13] follow up comments Signed-off-by: jooho lee --- config/webhook/kustomization.yaml | 14 +++- config/webhook/mutator_field_patch.yaml | 3 + config/webhook/mutator_webhook_patch.yaml | 11 ++++ config/webhook/webhook_patch.yaml | 1 - controllers/inferenceservice_controller.go | 31 ++++++++- .../kserve_isvc_gateway_reconciler.go | 24 +++---- controllers/webhook/kserve_service_mutator.go | 29 +++++---- .../webhook_kserve_service_mutator_test.go | 12 +++- go.mod | 13 ---- go.sum | 64 +------------------ 10 files changed, 94 insertions(+), 108 deletions(-) create mode 100644 config/webhook/mutator_field_patch.yaml create mode 100644 config/webhook/mutator_webhook_patch.yaml diff --git a/config/webhook/kustomization.yaml b/config/webhook/kustomization.yaml index ed4d980b..caee75d1 100644 --- a/config/webhook/kustomization.yaml +++ b/config/webhook/kustomization.yaml @@ -5,7 +5,6 @@ resources: - manifests.yaml - service.yaml - patches: - path: webhook_patch.yaml target: @@ -13,10 +12,21 @@ patches: kind: ValidatingWebhookConfiguration name: validating-webhook-configuration version: v1 + - path: mutator_webhook_patch.yaml + target: + group: admissionregistration.k8s.io + kind: MutatingWebhookConfiguration + name: mutating-webhook-configuration + version: v1 - path: field_patch.yaml target: group: admissionregistration.k8s.io kind: ValidatingWebhookConfiguration name: validating-webhook-configuration version: v1 - + - path: mutator_field_patch.yaml + target: + group: admissionregistration.k8s.io + kind: MutatingWebhookConfiguration + name: mutating-webhook-configuration + version: v1 diff --git a/config/webhook/mutator_field_patch.yaml b/config/webhook/mutator_field_patch.yaml new file mode 100644 index 00000000..a876ef77 --- /dev/null +++ b/config/webhook/mutator_field_patch.yaml @@ -0,0 +1,3 @@ +- op: replace + path: /metadata/name + value: mutating.odh-model-controller.opendatahub.io diff --git a/config/webhook/mutator_webhook_patch.yaml b/config/webhook/mutator_webhook_patch.yaml new file mode 100644 index 00000000..94fbcb9a --- /dev/null +++ b/config/webhook/mutator_webhook_patch.yaml @@ -0,0 +1,11 @@ +apiVersion: admissionregistration.k8s.io/v1 +kind: MutatingWebhookConfiguration +metadata: + name: mutating.odh-model-controller.opendatahub.io + annotations: + service.beta.openshift.io/inject-cabundle: true +webhooks: + - name: mutating.kserve-service.odh-model-controller.opendatahub.io + clientConfig: + service: + name: odh-model-controller-webhook-service diff --git a/config/webhook/webhook_patch.yaml b/config/webhook/webhook_patch.yaml index 1837a784..e545697f 100644 --- a/config/webhook/webhook_patch.yaml +++ b/config/webhook/webhook_patch.yaml @@ -13,4 +13,3 @@ webhooks: matchExpressions: - key: serving.kserve.io/inferenceservice operator: Exists - diff --git a/controllers/inferenceservice_controller.go b/controllers/inferenceservice_controller.go index 4967abad..f3309768 100644 --- a/controllers/inferenceservice_controller.go +++ b/controllers/inferenceservice_controller.go @@ -32,8 +32,11 @@ import ( apierrs "k8s.io/apimachinery/pkg/api/errors" "k8s.io/apimachinery/pkg/types" ctrl "sigs.k8s.io/controller-runtime" + "sigs.k8s.io/controller-runtime/pkg/builder" "sigs.k8s.io/controller-runtime/pkg/client" + "sigs.k8s.io/controller-runtime/pkg/event" "sigs.k8s.io/controller-runtime/pkg/handler" + "sigs.k8s.io/controller-runtime/pkg/predicate" "sigs.k8s.io/controller-runtime/pkg/reconcile" ) @@ -106,6 +109,32 @@ func (r *OpenshiftInferenceServiceReconciler) Reconcile(ctx context.Context, req return ctrl.Result{}, err } +var certSecretPredicate = predicate.Funcs{ + UpdateFunc: func(e event.UpdateEvent) bool { + return hasInferenceServiceOwner(e.ObjectNew) + }, + CreateFunc: func(e event.CreateEvent) bool { + return hasInferenceServiceOwner(e.Object) + }, + DeleteFunc: func(e event.DeleteEvent) bool { + return hasInferenceServiceOwner(e.Object) + }, + GenericFunc: func(e event.GenericEvent) bool { + return hasInferenceServiceOwner(e.Object) + }, +} + +// check if the src secret has ownerReferences for InferenceService +func hasInferenceServiceOwner(obj client.Object) bool { + ownerReferences := obj.GetOwnerReferences() + for _, ownerReference := range ownerReferences { + if ownerReference.Kind == "InferenceService" { + return true + } + } + return false +} + // SetupWithManager sets up the controller with the Manager. func (r *OpenshiftInferenceServiceReconciler) SetupWithManager(mgr ctrl.Manager) error { builder := ctrl.NewControllerManagedBy(mgr). @@ -166,7 +195,7 @@ func (r *OpenshiftInferenceServiceReconciler) SetupWithManager(mgr ctrl.Manager) return []reconcile.Request{ {NamespacedName: types.NamespacedName{Name: o.GetName(), Namespace: o.GetNamespace()}}, } - })) + }), builder.WithPredicates(certSecretPredicate)) kserveWithMeshEnabled, kserveWithMeshEnabledErr := utils.VerifyIfComponentIsEnabled(context.Background(), mgr.GetClient(), utils.KServeWithServiceMeshComponent) if kserveWithMeshEnabledErr != nil { diff --git a/controllers/reconcilers/kserve_isvc_gateway_reconciler.go b/controllers/reconcilers/kserve_isvc_gateway_reconciler.go index 461e0124..5350491f 100644 --- a/controllers/reconcilers/kserve_isvc_gateway_reconciler.go +++ b/controllers/reconcilers/kserve_isvc_gateway_reconciler.go @@ -39,8 +39,6 @@ import ( var _ SubResourceReconciler = (*KserveGatewayReconciler)(nil) var meshNamespace string -var destSecretName string -var portName string type KserveGatewayReconciler struct { client client.Client @@ -62,8 +60,6 @@ func (r *KserveGatewayReconciler) Reconcile(ctx context.Context, log logr.Logger log.V(1).Info("Reconciling KServe local gateway for Kserve InferenceService") _, meshNamespace = utils.GetIstioControlPlaneName(ctx, r.client) - destSecretName = fmt.Sprintf("%s-%s", isvc.Name, isvc.Namespace) - portName = fmt.Sprintf("%s-%s", "https", isvc.Name) // return if Address.URL is not set if isvc.Status.Address != nil && isvc.Status.Address.URL == nil { @@ -82,7 +78,7 @@ func (r *KserveGatewayReconciler) Reconcile(ctx context.Context, log logr.Logger } // Copy src secret to destination namespace when there is not the synced secret. - copiedCertSecret, err := r.secretHandler.Get(ctx, types.NamespacedName{Name: destSecretName, Namespace: meshNamespace}) + copiedCertSecret, err := r.secretHandler.Get(ctx, types.NamespacedName{Name: fmt.Sprintf("%s-%s", isvc.Name, isvc.Namespace), Namespace: meshNamespace}) if err != nil { if errors.IsNotFound(err) { if err := r.copyServingCertSecretFromIsvcNamespace(ctx, srcCertSecret, nil); err != nil { @@ -137,12 +133,12 @@ func (r *KserveGatewayReconciler) getDesiredResource(isvc *kservev1beta1.Inferen { Hosts: []string{hostname}, Port: &istiov1beta1.Port{ - Name: portName, + Name: fmt.Sprintf("%s-%s", "https", isvc.Name), Number: 8445, Protocol: "HTTPS", }, Tls: &istiov1beta1.ServerTLSSettings{ - CredentialName: destSecretName, + CredentialName: fmt.Sprintf("%s-%s", isvc.Name, isvc.Namespace), Mode: istiov1beta1.ServerTLSSettings_SIMPLE, }, }, @@ -160,15 +156,15 @@ func (r *KserveGatewayReconciler) getExistingResource(ctx context.Context) (*ist func (r *KserveGatewayReconciler) Delete(ctx context.Context, log logr.Logger, isvc *kservev1beta1.InferenceService) error { var errs []error - log.V(1).Info(fmt.Sprintf("Deleting serving certificate Secret(%s) in %s namespace", destSecretName, isvc.Namespace)) - if err := r.deleteServingCertSecretInIstioNamespace(ctx, destSecretName); err != nil { - log.V(1).Error(err, fmt.Sprintf("Failed to delete the copied serving certificate Secret(%s) in %s namespace", destSecretName, isvc.Namespace)) + log.V(1).Info(fmt.Sprintf("Deleting serving certificate Secret(%s) in %s namespace", fmt.Sprintf("%s-%s", isvc.Name, isvc.Namespace), isvc.Namespace)) + if err := r.deleteServingCertSecretInIstioNamespace(ctx, fmt.Sprintf("%s-%s", isvc.Name, isvc.Namespace)); err != nil { + log.V(1).Error(err, fmt.Sprintf("Failed to delete the copied serving certificate Secret(%s) in %s namespace", fmt.Sprintf("%s-%s", isvc.Name, isvc.Namespace), isvc.Namespace)) errs = append(errs, err) } - log.V(1).Info(fmt.Sprintf("Deleting the Server(%s) from KServe local gateway in the %s namespace", portName, meshNamespace)) - if err := r.removeServerFromGateway(ctx, log, portName); err != nil { - log.V(1).Error(err, fmt.Sprintf("Failed to remove the Server(%s) from KServe local gateway in the %s namespace", portName, meshNamespace)) + log.V(1).Info(fmt.Sprintf("Deleting the Server(%s) from KServe local gateway in the %s namespace", fmt.Sprintf("%s-%s", "https", isvc.Name), meshNamespace)) + if err := r.removeServerFromGateway(ctx, log, fmt.Sprintf("%s-%s", "https", isvc.Name)); err != nil { + log.V(1).Error(err, fmt.Sprintf("Failed to remove the Server(%s) from KServe local gateway in the %s namespace", fmt.Sprintf("%s-%s", "https", isvc.Name), meshNamespace)) errs = append(errs, err) } @@ -228,7 +224,7 @@ func (r *KserveGatewayReconciler) removeServerFromGateway(ctx context.Context, l func (r *KserveGatewayReconciler) copyServingCertSecretFromIsvcNamespace(ctx context.Context, sourceSecret *corev1.Secret, preDestSecret *corev1.Secret) error { destinationSecret := &corev1.Secret{ ObjectMeta: metav1.ObjectMeta{ - Name: destSecretName, + Name: fmt.Sprintf("%s-%s", sourceSecret.Name, sourceSecret.Namespace), Namespace: meshNamespace, }, Data: sourceSecret.Data, diff --git a/controllers/webhook/kserve_service_mutator.go b/controllers/webhook/kserve_service_mutator.go index 06aea89f..933bc39c 100644 --- a/controllers/webhook/kserve_service_mutator.go +++ b/controllers/webhook/kserve_service_mutator.go @@ -4,9 +4,7 @@ import ( "context" "fmt" - kservev1beta1 "github.com/kserve/kserve/pkg/apis/serving/v1beta1" corev1 "k8s.io/api/core/v1" - apierrors "k8s.io/apimachinery/pkg/api/errors" "k8s.io/apimachinery/pkg/runtime" "sigs.k8s.io/controller-runtime/pkg/client" logf "sigs.k8s.io/controller-runtime/pkg/log" @@ -27,28 +25,24 @@ func NewKserveServiceMutator(client client.Client) *kserveServiceMutator { // Default implements the admission.Defaulter interface to mutate the resources func (m *kserveServiceMutator) Default(ctx context.Context, obj runtime.Object) error { log := logf.FromContext(ctx).WithName("KserviceServiceMutateWebhook") + log.Info("AAAAAAAAAAAAAAAAAAA - mutatingwebhook Called") svc, ok := obj.(*corev1.Service) if !ok { return fmt.Errorf("unexpected object type") } - // Retrieve the InferenceService directly by name - var isvc kservev1beta1.InferenceService - err := m.client.Get(ctx, client.ObjectKey{Name: svc.Name, Namespace: svc.Namespace}, &isvc) - if err != nil { - if apierrors.IsNotFound(err) { - // If InferenceService is not found, return without error - return nil - } - return fmt.Errorf("failed to get InferenceService: %w", err) + log.Info("AAAAAAAAAAAAAAAAAAA1 - before checking") + if !hasInferenceServiceOwner(svc) { + return nil } + log.Info("AAAAAAAAAAAAAAAAAAA1 - after checking") // Add the annotation if a matching InferenceService is found if svc.Annotations == nil { svc.Annotations = make(map[string]string) } - svc.Annotations["service.beta.openshift.io/serving-cert-secret-name"] = isvc.Name + svc.Annotations["service.beta.openshift.io/serving-cert-secret-name"] = svc.Name log.Info("Added annotation to Service", "ServiceName", svc.Name, "Annotation", svc.Annotations["service.beta.openshift.io/serving-cert-secret-name"]) return nil @@ -59,3 +53,14 @@ func (m *kserveServiceMutator) InjectDecoder(d *admission.Decoder) error { m.Decoder = d return nil } + +// check if the src secret has ownerReferences for InferenceService +func hasInferenceServiceOwner(obj client.Object) bool { + ownerReferences := obj.GetOwnerReferences() + for _, ownerReference := range ownerReferences { + if ownerReference.Kind == "InferenceService" { + return true + } + } + return false +} diff --git a/controllers/webhook_kserve_service_mutator_test.go b/controllers/webhook_kserve_service_mutator_test.go index c3543da0..d7e85d76 100644 --- a/controllers/webhook_kserve_service_mutator_test.go +++ b/controllers/webhook_kserve_service_mutator_test.go @@ -19,6 +19,13 @@ var _ = Describe("KServe Service mutator webhook", func() { ObjectMeta: metav1.ObjectMeta{ Name: defaultIsvcName, Namespace: "default", + OwnerReferences: []metav1.OwnerReference{ + { + APIVersion: "serving.kserve.io/v1beta1", + Kind: "InferenceService", + Name: "sklearn-example-isvc-iris-v2-rest", + }, + }, }, } } @@ -28,7 +35,7 @@ var _ = Describe("KServe Service mutator webhook", func() { }) - It("adds serving cert annotation if Service name matches InferenceService name", func() { + It("adds serving cert annotation when Service have InferenceService ownerReference", func() { // Create a new InferenceService inferenceService := &kservev1beta1.InferenceService{ ObjectMeta: metav1.ObjectMeta{ @@ -48,10 +55,11 @@ var _ = Describe("KServe Service mutator webhook", func() { Expect(kserveService.Annotations["service.beta.openshift.io/serving-cert-secret-name"]).To(Equal(defaultIsvcName)) }) - It("skips adding annotation when Service name does not match InferenceService name", func() { + It("skips adding annotation when Service does not have InferenceService ownerReference", func() { kserveServiceName := "different-name" kserveService := createServiceOwnedKserve() kserveService.SetName(kserveServiceName) + kserveService.SetOwnerReferences([]metav1.OwnerReference{}) err := mutator.Default(ctx, kserveService) Expect(err).ShouldNot(HaveOccurred()) diff --git a/go.mod b/go.mod index 58457df7..c71d0843 100644 --- a/go.mod +++ b/go.mod @@ -7,7 +7,6 @@ require ( github.com/hashicorp/go-multierror v1.1.1 github.com/kserve/kserve v0.12.1 github.com/kuadrant/authorino v0.15.0 - github.com/moby/moby v27.0.0+incompatible github.com/onsi/ginkgo v1.16.5 github.com/onsi/gomega v1.30.0 github.com/opendatahub-io/model-registry v0.1.1 @@ -40,14 +39,7 @@ require ( github.com/beorn7/perks v1.0.1 // indirect github.com/blendle/zapdriver v1.3.1 // indirect github.com/cespare/xxhash/v2 v2.2.0 // indirect - github.com/containerd/fifo v1.1.0 // indirect - github.com/containerd/log v0.1.0 // indirect github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect - github.com/docker/distribution v2.8.2+incompatible // indirect - github.com/docker/docker v24.0.7+incompatible // indirect - github.com/docker/go-connections v0.4.0 // indirect - github.com/docker/go-metrics v0.0.1 // indirect - github.com/docker/go-units v0.5.0 // indirect github.com/emicklei/go-restful/v3 v3.11.0 // indirect github.com/evanphx/json-patch/v5 v5.7.0 // indirect github.com/fsnotify/fsnotify v1.7.0 // indirect @@ -75,21 +67,16 @@ require ( github.com/json-iterator/go v1.1.12 // indirect github.com/mailru/easyjson v0.7.7 // indirect github.com/matttproud/golang_protobuf_extensions/v2 v2.0.0 // indirect - github.com/moby/term v0.5.0 // indirect github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect github.com/modern-go/reflect2 v1.0.2 // indirect - github.com/morikuni/aec v1.0.0 // indirect github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect github.com/nxadm/tail v1.4.8 // indirect github.com/opencontainers/go-digest v1.0.0 // indirect - github.com/opencontainers/image-spec v1.1.0-rc5 // indirect github.com/pkg/errors v0.9.1 // indirect github.com/prometheus/client_golang v1.17.0 // indirect github.com/prometheus/client_model v0.5.0 // indirect github.com/prometheus/common v0.45.0 // indirect github.com/prometheus/procfs v0.12.0 // indirect - github.com/rootless-containers/rootlesskit v1.1.1 // indirect - github.com/sirupsen/logrus v1.9.3 // indirect github.com/spf13/pflag v1.0.5 // indirect github.com/tidwall/match v1.1.1 // indirect github.com/tidwall/pretty v1.2.1 // indirect diff --git a/go.sum b/go.sum index f50e18af..a3e825af 100644 --- a/go.sum +++ b/go.sum @@ -161,8 +161,6 @@ github.com/XiaoMi/pegasus-go-client v0.0.0-20210427083443-f3b6b08bc4c2/go.mod h1 github.com/agnivade/levenshtein v1.1.1/go.mod h1:veldBMzWxcCG2ZvUTKD2kJNRdCk5hVbJomOvKkmgYbo= github.com/ahmetb/gen-crd-api-reference-docs v0.3.1-0.20210609063737-0067dc6dcea2/go.mod h1:TdjdkYhlOifCQWPs1UdTma97kQQMozf5h26hTuG70u8= github.com/alecthomas/kingpin/v2 v2.3.2/go.mod h1:0gyi0zQnjuFk8xrkNKamJoyUo382HRL7ATRpFZCw6tE= -github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= -github.com/alecthomas/units v0.0.0-20151022065526-2efee857e7cf/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0= github.com/alecthomas/units v0.0.0-20211218093645-b94a6e3cc137/go.mod h1:OMCwj8VM1Kc9e19TLln2VL61YJF0x1XFtfdL4JdbSyE= github.com/antlr/antlr4/runtime/Go/antlr/v4 v4.0.0-20230305170008-8188dc5388df/go.mod h1:pSwJ0fSY5KhvocuWSx4fz3BA8OrA1bQn+K1Eli3BRwM= github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5/go.mod h1:wHh0iHkYZB8zMSxRWpUBQtwG5a7fFgvEO+odwuTv2gs= @@ -186,8 +184,6 @@ github.com/aws/aws-sdk-go-v2/service/ssooidc v1.13.6/go.mod h1:csZuQY65DAdFBt1oI github.com/aws/aws-sdk-go-v2/service/sts v1.16.19/go.mod h1:h4J3oPZQbxLhzGnk+j9dfYHi5qIOVJ5kczZd658/ydM= github.com/aws/smithy-go v1.13.3/go.mod h1:Tg+OJXh4MB2R/uN61Ko2f6hTZwB/ZYGOtib8J3gBHzA= github.com/awslabs/amazon-ecr-credential-helper/ecr-login v0.0.0-20221004211355-a250ad2ca1e3/go.mod h1:m06KtrZgOloUaePAQMv+Ha8kRmTnKdozTHZrweepIrw= -github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q= -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/go.mod h1:IbckMUScFkM3pff0VJDNKRiT6TG/YpiHIM2yvyW5YoQ= @@ -212,8 +208,6 @@ github.com/cncf/udpa/go v0.0.0-20220112060539-c52dc94e7fbe/go.mod h1:6pvJx4me5XP github.com/cncf/xds/go v0.0.0-20231109132714-523115ebc101/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= github.com/containerd/containerd v1.7.13 h1:wPYKIeGMN8vaggSKuV1X0wZulpMz4CrgEsZdaCyB6Is= github.com/containerd/containerd v1.7.13/go.mod h1:zT3up6yTRfEUa6+GsITYIJNgSVL9NQ4x4h1RPzk0Wu4= -github.com/containerd/fifo v1.1.0 h1:4I2mbh5stb1u6ycIABlBw9zgtlK8viPI9QkQNRQEEmY= -github.com/containerd/fifo v1.1.0/go.mod h1:bmC4NWMbXlt2EZ0Hc7Fx7QzTFxgPID13eH0Qu+MAb2o= github.com/containerd/log v0.1.0 h1:TCJt7ioM2cr/tfR8GPbGf9/VRAX8D2B4PjzCpfX540I= github.com/containerd/log v0.1.0/go.mod h1:VRRf09a7mHDIRezVKTRCrOq78v577GXq3bSa3EhrzVo= github.com/containerd/stargz-snapshotter/estargz v0.14.3/go.mod h1:KY//uOCIkSuNAHhJogcZtrNHdKrA99/FCCRjE3HD36o= @@ -225,7 +219,6 @@ github.com/cpuguy83/dockercfg v0.3.1 h1:/FpZ+JaygUR/lZP2NlFI2DVfrOEMAIKP5wWEJdoY github.com/cpuguy83/dockercfg v0.3.1/go.mod h1:sugsbF4//dDlL/i+S+rtpIWp+5h0BHJHfjj5/jFyUJc= github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= -github.com/creack/pty v1.1.18/go.mod h1:MOBLtS5ELjhRRrroQr9kyvTxUAFNvYEK993ew/Vr4O4= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc h1:U9qPSI2PIWSS1VwoXQT9A3Wy9MM3WgvqSxFWenqJduM= @@ -241,8 +234,6 @@ github.com/docker/docker v24.0.7+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bc github.com/docker/docker-credential-helpers v0.7.0/go.mod h1:rETQfLdHNT3foU5kuNkFR1R1V12OJRRO5lzt2D1b5X0= github.com/docker/go-connections v0.4.0 h1:El9xVISelRB7BuFusrZozjnkIM5YnzCViNKohAFqRJQ= github.com/docker/go-connections v0.4.0/go.mod h1:Gbd7IOopHjR8Iph03tsViu4nIes5XhDvyHbTtUxmeec= -github.com/docker/go-metrics v0.0.1 h1:AgB/0SvBxihN0X8OR4SjsblXkbMvalQ8cjmtKQ2rQV8= -github.com/docker/go-metrics v0.0.1/go.mod h1:cG1hvH2utMXtqgqqYE9plW6lDxS3/5ayHzueweSI3Vw= github.com/docker/go-units v0.5.0 h1:69rxXcBk27SvSaaxTtLh/8llcHD8vYHT7WSdRZ/jvr4= github.com/docker/go-units v0.5.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk= github.com/dustin/go-humanize v1.0.1/go.mod h1:Mu1zIs6XwVuF/gI1OepvI0qD18qycQx+mFykh5fBlto= @@ -270,11 +261,8 @@ github.com/ghodss/yaml v1.0.0 h1:wQHKEahhL6wmXdzwWG11gIVCkOv05bNOh+Rxn0yngAk= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= github.com/go-chi/chi/v5 v5.0.11/go.mod h1:DslCQbL2OYiznFReuXYUmQ2hGd1aDpCnlMNITLSKoi8= github.com/go-chi/cors v1.2.1/go.mod h1:sSbTewc+6wYHBBCW7ytsFSn836hqM7JxpglAy2Vzc58= -github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= github.com/go-kit/log v0.2.1 h1:MRVx0/zhvdseW+Gza6N9rVzU/IVzaeE1SFI4raAhmBU= github.com/go-kit/log v0.2.1/go.mod h1:NwTd00d/i8cPZ3xOwwiv2PO5MOcx78fFErGNcVmBjv0= -github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE= -github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk= github.com/go-logfmt/logfmt v0.6.0 h1:wGYYu3uicYdqXVgoYbvnkrPVXkuLM1p1ifugDMEdRi4= github.com/go-logfmt/logfmt v0.6.0/go.mod h1:WYhtIu8zTZfxdn5+rREduYbwxfcBr/Vr6KEVveWlfTs= github.com/go-logr/logr v1.3.0 h1:2y3SDp0ZXuc6/cjLSZ+Q3ir+QB9T/iG5yYRXqsagWSY= @@ -293,16 +281,13 @@ github.com/go-openapi/swag v0.22.3/go.mod h1:UzaqsxGiab7freDnrUUra0MwWfN/q7tE4j+ github.com/go-openapi/swag v0.22.4 h1:QLMzNJnMGPRNDCbySlcj1x01tzU8/9LTTL9hZZZogBU= github.com/go-openapi/swag v0.22.4/go.mod h1:UzaqsxGiab7freDnrUUra0MwWfN/q7tE4j+VcZ0yl14= github.com/go-redis/redis/v8 v8.11.5/go.mod h1:gREzHqY1hg6oD9ngVRbLStwAWKhA0FEgq8Jd4h5lpwo= -github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= github.com/go-task/slim-sprig v0.0.0-20210107165309-348f09dbbbc0/go.mod h1:fyg7847qk6SyHyPtNmDHnmrv/HOrqktSC+C9fM+CJOE= github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572 h1:tfuBGBXKqDEevZMzYi5KSi8KkcZtzBcTgAUUtapy0OI= github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572/go.mod h1:9Pwr4B2jHnOSGXyyzV8ROjYa2ojvAY6HCGYYfMoC3Ls= github.com/gobuffalo/flect v1.0.2/go.mod h1:A5msMlrHtLqh9umBSnvabjsMrCcCpAyzglnDvkbYKHs= github.com/gobwas/glob v0.2.3/go.mod h1:d3Ez4x06l9bZtSvzIay5+Yzi0fmZzPgnTbPcKjJAkT8= -github.com/gofrs/flock v0.8.1/go.mod h1:F1TvTiK9OcQqauNUHlbJvyl9Qa1QvF/gOUDKA14jxHU= github.com/gofrs/uuid/v5 v5.0.0/go.mod h1:CDOjlDMVAtN56jqyRUZh58JT31Tiw7/oQyEXZV+9bD8= github.com/gogo/googleapis v1.4.0/go.mod h1:5YRNX2z1oM5gXdAkurHa942MDgEJyk02w4OecKY87+c= -github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= github.com/golang-jwt/jwt v3.2.2+incompatible/go.mod h1:8pz2t5EyA70fFQQSrl6XZXzqecmYZeUEB8OUGHkxJ+I= @@ -377,7 +362,6 @@ github.com/googleapis/gax-go/v2 v2.12.0/go.mod h1:y+aIqrI5eb1YGMVJfuV3185Ts/D7qK github.com/googleapis/gnostic v0.5.5/go.mod h1:7+EbHbldMins07ALC74bsA81Ovc97DwqyJO1AENw9kA= github.com/googleapis/google-cloud-go-testing v0.0.0-20210719221736-1c9a4c676720 h1:zC34cGQu69FG7qzJ3WiKW244WfhDC3xxYMeNOX2gtUQ= github.com/googleapis/google-cloud-go-testing v0.0.0-20210719221736-1c9a4c676720/go.mod h1:dvDLG8qkwmyD9a/MJJN3XJcT3xFxOKAvTZGvuZmac9g= -github.com/gorilla/mux v1.8.0/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So= github.com/gorilla/websocket v1.5.1/go.mod h1:x3kM2JMyaluk02fnUJpQuwD2dCS5NDG2ZHL0uE0tcaY= github.com/gregjones/httpcache v0.0.0-20180305231024-9cad4c3443a7/go.mod h1:FecbI9+v66THATjSRHfNgh1IVFe/9kFxbXtjV0ctIMA= github.com/grpc-ecosystem/go-grpc-middleware v1.3.0/go.mod h1:z0ButlSOZa5vEBq9m2m2hlwIgKw+rp3sdCBRoJY+30Y= @@ -402,7 +386,6 @@ github.com/inconshreveable/mousetrap v1.1.0/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLf github.com/influxdata/influxdb-client-go/v2 v2.9.0/go.mod h1:x7Jo5UHHl+w8wu8UnGiNobDDHygojXwJX4mx7rXGKMk= github.com/influxdata/line-protocol v0.0.0-20200327222509-2487e7298839/go.mod h1:xaLFMmpvUxqXtVkUJfg9QmT88cDaCJ3ZKgdZ78oO8Qo= github.com/influxdata/tdigest v0.0.1/go.mod h1:Z0kXnxzbTC2qrx4NaIzYkE1k66+6oEDQTvL95hQFh5Y= -github.com/insomniacslk/dhcp v0.0.0-20230516061539-49801966e6cb/go.mod h1:7474bZ1YNCvarT6WFKie4kEET6J0KYRDC4XJqqXzQW4= github.com/invopop/yaml v0.2.0/go.mod h1:2XuRLgs/ouIrW3XNzuNj7J3Nvu/Dig5MXvbCEdiBN3Q= github.com/jessevdk/go-flags v1.4.0/go.mod h1:4FA24M0QyGHXBuZZK/XkWh8h0e1EYbRYJSGM75WSRxI= github.com/jmespath/go-jmespath v0.4.0 h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9YPoQUg= @@ -412,14 +395,10 @@ github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfC github.com/jonboulle/clockwork v0.2.2/go.mod h1:Pkfl5aHPm1nk2H9h0bjmnJD/BcgbGXUBGnn1kMkgxc8= github.com/josharian/intern v1.0.0 h1:vlS4z54oSdjm0bgjRigI+G1HpF+tI+9rE5LLzOg8HmY= github.com/josharian/intern v1.0.0/go.mod h1:5DoeVV0s6jJacbCEi61lwdGj/aVlrQvzHFFd8Hwg//Y= -github.com/josharian/native v1.1.0/go.mod h1:7X/raswPFr05uY3HiLlYeyQntB6OO7E/d2Cu7qoaN2w= github.com/jpillora/backoff v1.0.0/go.mod h1:J/6gKK9jxlEcS3zixgDgUAsiuZ7yrSoa/FX5e0EB2j4= -github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= -github.com/json-iterator/go v1.1.7/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM= github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHmT4TnhNGBo= github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU= -github.com/julienschmidt/httprouter v1.2.0/go.mod h1:SYymIcj16QtmaHHD7aYtjjsJG7VTCxuUUipMqKk8s4w= github.com/julienschmidt/httprouter v1.3.0/go.mod h1:JR6WtHb+2LUe8TCKY3cZOxFyyO8IZAc4RVcycCCAKdM= github.com/jzelinskie/stringz v0.0.0-20210414224931-d6a8ce844a70/go.mod h1:hHYbgxJuNLRw91CmpuFsYEOyQqpDVFg8pvEh23vy4P0= github.com/kelseyhightower/envconfig v1.4.0/go.mod h1:cccZRl6mQpaq41TPp5QxidR+Sa3axMbJDNb//FQX6Gg= @@ -427,8 +406,6 @@ github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= github.com/klauspost/compress v1.17.0 h1:Rnbp4K9EjcDuVuHtd0dgA4qNuv9yKDYKK1ulpJwgrqM= github.com/klauspost/compress v1.17.0/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE= -github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= -github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc= github.com/kr/pretty v0.2.1/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI= github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= github.com/kr/pretty v0.3.1/go.mod h1:hoEshYVHaxMs3cyo3Yncou5ZscifuDolrwPKZanG3xk= @@ -449,28 +426,21 @@ github.com/mailru/easyjson v0.7.7/go.mod h1:xzfreul335JAWq5oZzymOObrkdz5UnU4kGfJ github.com/maistra/xns-informer v0.0.0-20230111124621-73ee35e5f523/go.mod h1:2DP6ps5pmbxaazskTazVHwwLF+RiW+EtcJqQxLBaWH8= github.com/mattn/go-colorable v0.1.8/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU= -github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= github.com/matttproud/golang_protobuf_extensions v1.0.4/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4= github.com/matttproud/golang_protobuf_extensions/v2 v2.0.0 h1:jWpvCLoY8Z/e3VKvlsiIGKtc+UG6U5vzxaoagmhXfyg= github.com/matttproud/golang_protobuf_extensions/v2 v2.0.0/go.mod h1:QUyp042oQthUoa9bqDv0ER0wrtXnBruoNd7aNjkbP+k= github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= github.com/mitchellh/mapstructure v1.5.0/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= -github.com/moby/moby v27.0.0+incompatible h1:aIzs7Gdy6LB4ySNX939Q1poGmqINepve2jXm2mFcobs= -github.com/moby/moby v27.0.0+incompatible/go.mod h1:fDXVQ6+S340veQPv35CzDahGBmHsiclFwfEygB/TWMc= github.com/moby/patternmatcher v0.6.0 h1:GmP9lR19aU5GqSSFko+5pRqHi+Ohk1O69aFiKkVGiPk= github.com/moby/patternmatcher v0.6.0/go.mod h1:hDPoyOpDY7OrrMDLaYoY3hf52gNCR/YOUYxkhApJIxc= github.com/moby/spdystream v0.2.0/go.mod h1:f7i0iNDQJ059oMTcWxx8MA/zKFIuD/lY+0GqbN2Wy8c= -github.com/moby/sys/mountinfo v0.6.2/go.mod h1:IJb6JQeOklcdMU9F5xQ8ZALD+CUr5VlGpwtX+VE0rpI= github.com/moby/sys/sequential v0.5.0 h1:OPvI35Lzn9K04PBbCLW0g4LcFAJgHsvXsRyewg5lXtc= github.com/moby/sys/sequential v0.5.0/go.mod h1:tH2cOOs5V9MlPiXcQzRC+eEyab644PWKGRYaaV5ZZlo= github.com/moby/term v0.5.0 h1:xt8Q1nalod/v7BqbG21f8mQPqH+xAaC9C3N3wfWbVP0= github.com/moby/term v0.5.0/go.mod h1:8FzsFHVUBGZdbDsJw/ot+X+d5HLUbvklYLJ9uGfcI3Y= -github.com/moby/vpnkit v0.5.0/go.mod h1:KyjUrL9cb6ZSNNAUwZfqRjhwwgJ3BJN+kXh0t43WTUQ= github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= -github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= -github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M= github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= github.com/mohae/deepcopy v0.0.0-20170929034955-c48cc78d4826/go.mod h1:TaXosZuwdSHYgviHp1DAtfrULt5eUgsSMsZf+YrPgl8= @@ -478,7 +448,6 @@ github.com/morikuni/aec v1.0.0 h1:nP9CBfwrvYnBRgY6qfDQkygYDmYwOilePFkwzv4dU8A= github.com/morikuni/aec v1.0.0/go.mod h1:BbKIizmSmc5MMPqRYbxO4ZU0S0+P200+tUnFx7PXmsc= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 h1:C3w9PqII01/Oq1c1nUAm88MOHcQC9l5mIlSMApZMrHA= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ= -github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= github.com/mxk/go-flowrate v0.0.0-20140419014527-cca7078d478f/go.mod h1:ZdcZmHo+o7JKHSa8/e818NopupXU1YMK5fe1lsApnBw= github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= @@ -510,8 +479,6 @@ github.com/pegasus-kv/thrift v0.13.0/go.mod h1:Gl9NT/WHG6ABm6NsrbfE8LiJN0sAyneCr github.com/pelletier/go-toml/v2 v2.1.0/go.mod h1:tJU2Z3ZkXwnxa4DPO899bsyIoywizdUvyaeZurnPPDc= github.com/perimeterx/marshmallow v1.1.5/go.mod h1:dsXbUu8CRzfYP5a87xpp0xq9S3u0Vchtcl8we9tYaXw= github.com/peterbourgon/diskv v2.0.1+incompatible/go.mod h1:uqqh8zWWbv1HBMNONnaR/tNboyR3/BZd58JJSHlUSCU= -github.com/pierrec/lz4/v4 v4.1.17/go.mod h1:gZWDp/Ze/IJXGXf23ltt2EXimqmTUXEy0GFuRQyBid4= -github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= @@ -523,23 +490,13 @@ github.com/power-devops/perfstat v0.0.0-20210106213030-5aafc221ea8c/go.mod h1:Om github.com/pquerna/cachecontrol v0.0.0-20201205024021-ac21108117ac/go.mod h1:hoLfEwdY11HjRfKFH6KqnPsfxlo3BP6bJehpDv8t6sQ= github.com/prometheus-operator/prometheus-operator/pkg/apis/monitoring v0.64.1 h1:bvntWler8vOjDJtxBwGDakGNC6srSZmgawGM9Jf7HC8= github.com/prometheus-operator/prometheus-operator/pkg/apis/monitoring v0.64.1/go.mod h1:cfNgxpCPGyIydmt3HcwDqKDt0nYdlGRhzftl+DZH7WA= -github.com/prometheus/client_golang v0.9.1/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw= -github.com/prometheus/client_golang v1.0.0/go.mod h1:db9x61etRT2tGnBNRi70OPL5FsnadC4Ky3P0J6CfImo= -github.com/prometheus/client_golang v1.1.0/go.mod h1:I1FGZT9+L76gKKOs5djB6ezCbFQP1xR9D75/vuwEF3g= github.com/prometheus/client_golang v1.17.0 h1:rl2sfwZMtSthVU752MqfjQozy7blglC+1SOtjMAMh+Q= github.com/prometheus/client_golang v1.17.0/go.mod h1:VeL+gMmOAxkS2IqfCq0ZmHSL+LjWfWDUmp1mBz9JgUY= -github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= -github.com/prometheus/client_model v0.0.0-20190129233127-fd36f4220a90/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/prometheus/client_model v0.5.0 h1:VQw1hfvPvk3Uv6Qf29VrPF32JB6rtbgI6cYPYQjL0Qw= github.com/prometheus/client_model v0.5.0/go.mod h1:dTiFglRmd66nLR9Pv9f0mZi7B7fk5Pm3gvsjB5tr+kI= -github.com/prometheus/common v0.4.1/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= -github.com/prometheus/common v0.6.0/go.mod h1:eBmuwkDJBwy6iBfxCBob6t6dR6ENT/y+J+Zk0j9GMYc= github.com/prometheus/common v0.45.0 h1:2BGz0eBc2hdMDLnO/8n0jeB3oPrt2D08CekT0lneoxM= github.com/prometheus/common v0.45.0/go.mod h1:YJmSTw9BoKxJplESWWxlbyttQR4uaEcGyv9MZjVOJsY= -github.com/prometheus/procfs v0.0.0-20181005140218-185b4288413d/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= -github.com/prometheus/procfs v0.0.2/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA= -github.com/prometheus/procfs v0.0.3/go.mod h1:4A/X28fw3Fc593LaREMrKMqOKvUAntwMDaekg4FpcdQ= github.com/prometheus/procfs v0.12.0 h1:jluTpSng7V9hY0O2R9DzzJHYb2xULk9VTR1V1R/k6Bo= github.com/prometheus/procfs v0.12.0/go.mod h1:pcuDEFsWDnvcgNzo4EEweacyhjeA9Zk3cnaOZAZEfOo= github.com/prometheus/statsd_exporter v0.25.0 h1:gpVF1TMf1UqMJmBDpzBYrEaGOFMpbMBYYYUDwM38Y/I= @@ -547,10 +504,7 @@ github.com/prometheus/statsd_exporter v0.25.0/go.mod h1:HwzfSvg6ehmb0Qg71ZuFrlgj github.com/rcrowley/go-metrics v0.0.0-20200313005456-10cdbea86bc0/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4= github.com/rogpeppe/go-internal v1.10.0 h1:TMyTOH3F/DB16zRVcYyreMH6GnZZrwQVAoYjRBZyWFQ= github.com/rogpeppe/go-internal v1.10.0/go.mod h1:UQnix2H7Ngw/k4C5ijL5+65zddjncjaFoBhdsK/akog= -github.com/rootless-containers/rootlesskit v1.1.1 h1:F5psKWoWY9/VjZ3ifVcaosjvFZJOagX85U22M0/EQZE= -github.com/rootless-containers/rootlesskit v1.1.1/go.mod h1:UD5GoA3dqKCJrnvnhVgQQnweMF2qZnf9KLw8EewcMZI= github.com/rs/dnscache v0.0.0-20211102005908-e0241e321417/go.mod h1:qe5TWALJ8/a1Lqznoc5BDHpYX/8HU60Hm2AwRmqzxqA= -github.com/russross/blackfriday v1.6.0/go.mod h1:ti0ldHuxg49ri4ksnFxlkCfN+hvslNlmVHqNRXXJNAY= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/sagikazarmark/locafero v0.4.0/go.mod h1:Pe1W6UlPYUk/+wc/6KFhbORCfqzgYEpgQ3O5fPuL3H4= github.com/sagikazarmark/slog-shim v0.1.0/go.mod h1:SrcSrq8aKtyuqEI1uvTDTK1arOWRIczQRv+GVI1AkeQ= @@ -558,11 +512,9 @@ github.com/shirou/gopsutil/v3 v3.23.9 h1:ZI5bWVeu2ep4/DIxB4U9okeYJ7zp/QLTO4auRb/ github.com/shirou/gopsutil/v3 v3.23.9/go.mod h1:x/NWSb71eMcjFIO0vhyGW5nZ7oSIgVjrCnADckb85GA= github.com/shoenig/go-m1cpu v0.1.6 h1:nxdKQNcEB6vzgA2E2bvzKIYRuNj7XNJ4S/aRSwKzFtM= github.com/shoenig/go-m1cpu v0.1.6/go.mod h1:1JJMcUBvfNwpq05QDQVAnx3gUHr9IYF7GNg9SUEw2VQ= -github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= github.com/sirupsen/logrus v1.9.3 h1:dueUQJ1C2q9oE3F7wvmSGAaVtTmUizReu6fjN8uqzbQ= github.com/sirupsen/logrus v1.9.3/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= github.com/soheilhy/cmux v0.1.5/go.mod h1:T7TcVDs9LWfQgPlPsdngu6I6QIoyIFZDDC6sNE1GqG0= -github.com/songgao/water v0.0.0-20200317203138-2b4b6d7c09d8/go.mod h1:P5HUIBuIWKbyjl083/loAegFkfbFNx5i2qEP4CNbm7E= github.com/sourcegraph/conc v0.3.0/go.mod h1:Sdozi7LEKbFPqYX2/J+iBAM6HpqSLTASQIKqDmF7Mt0= github.com/spaolacci/murmur3 v1.1.0/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= github.com/spf13/afero v1.11.0/go.mod h1:GH9Y3pIexgf1MTIWtNGyogA5MwRIDXGUr+hbWNoBjkY= @@ -573,13 +525,10 @@ github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An github.com/spf13/viper v1.18.2/go.mod h1:EKmWIqdnk5lOcmR72yw6hS+8OPYcwD0jteitLMVB+yk= github.com/stoewer/go-strcase v1.2.0/go.mod h1:IBiWB2sKIp3wVVQ3Y035++gc+knqhUQag1KpM8ahLw8= 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= github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo= -github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA= -github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= @@ -603,15 +552,11 @@ github.com/tklauser/numcpus v0.6.1/go.mod h1:1XfjsgE2zo8GVw7POkMbHENHzVg3GzmoZ9f github.com/tmc/grpc-websocket-proxy v0.0.0-20220101234140-673ab2c3ae75/go.mod h1:KO6IkyS8Y3j8OdNO85qEYBsRPuteD+YciPomcXdrMnk= github.com/tsenart/go-tsz v0.0.0-20180814235614-0bd30b3df1c3/go.mod h1:SWZznP1z5Ki7hDT2ioqiFKEse8K9tU2OUvaRI0NeGQo= github.com/tsenart/vegeta/v12 v12.11.1/go.mod h1:swiFmrgpqj2llHURgHYFRFN0tfrIrlnspg01HjwOnSQ= -github.com/u-root/uio v0.0.0-20230305220412-3e8cd9d6bf63/go.mod h1:eLL9Nub3yfAho7qB0MzZizFhTU2QkLeoVsWdHtDW264= -github.com/urfave/cli/v2 v2.25.5/go.mod h1:GHupkWPMM0M/sj1a2b4wUrWBPzazNrIjouW6fmdJLxc= github.com/vbatts/tar-split v0.11.3/go.mod h1:9QlHN18E+fEH7RdG+QAJJcuya3rqT7eXSTY7wGrAokY= github.com/xeipuuv/gojsonpointer v0.0.0-20190905194746-02993c407bfb/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU= github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415/go.mod h1:GwrjFmJcFw6At/Gs6z4yjiIwzuJ1/+UwLxMQDVQXShQ= -github.com/xeipuuv/gojsonschema v1.2.0/go.mod h1:anYRn/JVcOK2ZgGU+IjEV4nwlhoK5sQluxsYJ78Id3Y= github.com/xhit/go-str2duration/v2 v2.1.0/go.mod h1:ohY8p+0f07DiV6Em5LKB0s2YpLtXVyJfNt1+BlmyAsU= github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU= -github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673/go.mod h1:N3UwUGtsrSj3ccvlPHLoLsHnpR27oXr4ZE984MbSER8= github.com/yashtewari/glob-intersection v0.1.0/go.mod h1:LK7pIC3piUjovexikBbJ26Yml7g8xa5bsjfx2v1fwok= github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= @@ -652,7 +597,6 @@ go.uber.org/multierr v1.11.0/go.mod h1:20+QtiLqy0Nd6FdQB9TLXag12DsQkrbs3htMFfDN8 go.uber.org/zap v1.10.0/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= go.uber.org/zap v1.26.0 h1:sI7k6L95XOKS281NhVKOFCUNIvv9e0w4BF8N3u+tCRo= go.uber.org/zap v1.26.0/go.mod h1:dtElttAiwGvoJ/vj4IwHBS/gXsEu/pZ50mUIRWuG0so= -golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= @@ -694,9 +638,7 @@ golang.org/x/sync v0.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.5.0 h1:60k92dhOjHxJkrqnwsfl8KuaHbn/5dl0lUPUklKo3qE= golang.org/x/sync v0.5.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20181116152217-5ac8a444bdc5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -704,14 +646,12 @@ golang.org/x/sys v0.0.0-20190502145724-3ef323f4f1fd/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20190507160741-ecd444e8653b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190801041406-cbf593c0f2f3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191120155948-bd437916bb0e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210112080510-489259a85091/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.18.0 h1:DBdB3niSjOA/O0blCZBqDefyWNYveAYMNF1Wum0DYQ4= @@ -796,7 +736,6 @@ google.golang.org/grpc v1.61.0 h1:TOvOcuXn30kRao+gfcvsebNEa5iZIiLkisYEkf7R7o0= google.golang.org/grpc v1.61.0/go.mod h1:VUbo7IFqmF1QtCAstipjG0GIoq49KvMe9+h1jFLBNJs= google.golang.org/protobuf v1.33.0 h1:uNO2rsAINq/JlFpSdYEKIZ0uKD/R9cpdv0T+yoGwGmI= google.golang.org/protobuf v1.33.0/go.mod h1:c6P6GXX6sHbq/GpV6MGZEdwhWPcYBgnhAHhKbcUYpos= -gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= @@ -809,7 +748,6 @@ gopkg.in/square/go-jose.v2 v2.5.1/go.mod h1:M9dMgbHiYLoDGQrXy7OpJDJWiKiU//h+vD76 gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= gopkg.in/tomb.v2 v2.0.0-20161208151619-d5d1b5820637/go.mod h1:BHsqpu/nsuzkT5BpiH1EMZPLyqSMM8JbIavyFACoFNk= -gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= @@ -821,7 +759,7 @@ gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gotest.tools v2.2.0+incompatible h1:VsBPFP1AI068pPrMxtb/S8Zkgf9xEmTLJjfM+P5UIEo= gotest.tools v2.2.0+incompatible/go.mod h1:DsYFclhRJ6vuDpmuTbkuFWG+y2sxOXAzmJt81HFBacw= -gotest.tools/v3 v3.4.0/go.mod h1:CtbdzLSsqVhDgMtKsx03ird5YTGB3ar27v0u/yKBW5g= +gotest.tools/v3 v3.0.3/go.mod h1:Z7Lb0S5l+klDB31fvDQX8ss/FlKDxtlFlw3Oa8Ymbl8= honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190418001031-e561f6794a2a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= From 1de88b00bfb8450b2e3b519b0958c4a4c8b2b465 Mon Sep 17 00:00:00 2001 From: jooho lee Date: Sat, 22 Jun 2024 08:26:00 -0400 Subject: [PATCH 11/13] remove webhook and add the isvc_service_cert_reconciler again Signed-off-by: jooho lee --- config/webhook/kustomization.yaml | 12 -- config/webhook/manifests.yaml | 25 ---- config/webhook/mutator_field_patch.yaml | 3 - config/webhook/mutator_webhook_patch.yaml | 11 -- controllers/inferenceservice_controller.go | 24 +++- ...kserve_inferenceservice_controller_test.go | 49 +++++++ .../kserve_isvc_service_cert_reconciler.go | 131 ++++++++++++++++++ ..._serverless_inferenceservice_reconciler.go | 1 + controllers/webhook/kserve_service_mutator.go | 66 --------- .../webhook_kserve_service_mutator_test.go | 70 ---------- main.go | 11 +- 11 files changed, 203 insertions(+), 200 deletions(-) delete mode 100644 config/webhook/mutator_field_patch.yaml delete mode 100644 config/webhook/mutator_webhook_patch.yaml create mode 100644 controllers/reconcilers/kserve_isvc_service_cert_reconciler.go delete mode 100644 controllers/webhook/kserve_service_mutator.go delete mode 100644 controllers/webhook_kserve_service_mutator_test.go diff --git a/config/webhook/kustomization.yaml b/config/webhook/kustomization.yaml index caee75d1..f8a9664b 100644 --- a/config/webhook/kustomization.yaml +++ b/config/webhook/kustomization.yaml @@ -12,21 +12,9 @@ patches: kind: ValidatingWebhookConfiguration name: validating-webhook-configuration version: v1 - - path: mutator_webhook_patch.yaml - target: - group: admissionregistration.k8s.io - kind: MutatingWebhookConfiguration - name: mutating-webhook-configuration - version: v1 - path: field_patch.yaml target: group: admissionregistration.k8s.io kind: ValidatingWebhookConfiguration name: validating-webhook-configuration version: v1 - - path: mutator_field_patch.yaml - target: - group: admissionregistration.k8s.io - kind: MutatingWebhookConfiguration - name: mutating-webhook-configuration - version: v1 diff --git a/config/webhook/manifests.yaml b/config/webhook/manifests.yaml index 01d11ca7..26d90b5f 100644 --- a/config/webhook/manifests.yaml +++ b/config/webhook/manifests.yaml @@ -1,30 +1,5 @@ --- apiVersion: admissionregistration.k8s.io/v1 -kind: MutatingWebhookConfiguration -metadata: - name: mutating-webhook-configuration -webhooks: -- admissionReviewVersions: - - v1 - clientConfig: - service: - name: webhook-service - namespace: system - path: /mutate-serving-kserve-service - failurePolicy: Fail - name: mutating.kserve-service.odh-model-controller.opendatahub.io - rules: - - apiGroups: - - "" - apiVersions: - - v1 - operations: - - CREATE - resources: - - services - sideEffects: None ---- -apiVersion: admissionregistration.k8s.io/v1 kind: ValidatingWebhookConfiguration metadata: name: validating-webhook-configuration diff --git a/config/webhook/mutator_field_patch.yaml b/config/webhook/mutator_field_patch.yaml deleted file mode 100644 index a876ef77..00000000 --- a/config/webhook/mutator_field_patch.yaml +++ /dev/null @@ -1,3 +0,0 @@ -- op: replace - path: /metadata/name - value: mutating.odh-model-controller.opendatahub.io diff --git a/config/webhook/mutator_webhook_patch.yaml b/config/webhook/mutator_webhook_patch.yaml deleted file mode 100644 index 94fbcb9a..00000000 --- a/config/webhook/mutator_webhook_patch.yaml +++ /dev/null @@ -1,11 +0,0 @@ -apiVersion: admissionregistration.k8s.io/v1 -kind: MutatingWebhookConfiguration -metadata: - name: mutating.odh-model-controller.opendatahub.io - annotations: - service.beta.openshift.io/inject-cabundle: true -webhooks: - - name: mutating.kserve-service.odh-model-controller.opendatahub.io - clientConfig: - service: - name: odh-model-controller-webhook-service diff --git a/controllers/inferenceservice_controller.go b/controllers/inferenceservice_controller.go index f3309768..742323ec 100644 --- a/controllers/inferenceservice_controller.go +++ b/controllers/inferenceservice_controller.go @@ -32,7 +32,7 @@ import ( apierrs "k8s.io/apimachinery/pkg/api/errors" "k8s.io/apimachinery/pkg/types" ctrl "sigs.k8s.io/controller-runtime" - "sigs.k8s.io/controller-runtime/pkg/builder" + // "sigs.k8s.io/controller-runtime/pkg/builder" "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/controller-runtime/pkg/event" "sigs.k8s.io/controller-runtime/pkg/handler" @@ -126,9 +126,10 @@ var certSecretPredicate = predicate.Funcs{ // check if the src secret has ownerReferences for InferenceService func hasInferenceServiceOwner(obj client.Object) bool { + ownerReferences := obj.GetOwnerReferences() for _, ownerReference := range ownerReferences { - if ownerReference.Kind == "InferenceService" { + if ownerReference.Kind == "Service" { return true } } @@ -195,8 +196,25 @@ func (r *OpenshiftInferenceServiceReconciler) SetupWithManager(mgr ctrl.Manager) return []reconcile.Request{ {NamespacedName: types.NamespacedName{Name: o.GetName(), Namespace: o.GetNamespace()}}, } - }), builder.WithPredicates(certSecretPredicate)) + })) + + // Watches(&corev1.Secret{}, + // handler.EnqueueRequestsFromMapFunc(func(ctx context.Context, o client.Object) []reconcile.Request { + // r.log.Info("Reconcile event triggered by Secret: " + o.GetName()) + // isvc := &kservev1beta1.InferenceService{} + // err := r.client.Get(ctx, types.NamespacedName{Name: o.GetName(), Namespace: o.GetNamespace()}, isvc) + // if err != nil { + // if apierrs.IsNotFound(err) { + // return []reconcile.Request{} + // } + // r.log.Error(err, "Error getting the inferenceService", "name", o.GetName()) + // return []reconcile.Request{} + // } + // return []reconcile.Request{ + // {NamespacedName: types.NamespacedName{Name: o.GetName(), Namespace: o.GetNamespace()}}, + // } + // }), builder.WithPredicates(certSecretPredicate)) kserveWithMeshEnabled, kserveWithMeshEnabledErr := utils.VerifyIfComponentIsEnabled(context.Background(), mgr.GetClient(), utils.KServeWithServiceMeshComponent) if kserveWithMeshEnabledErr != nil { r.log.V(1).Error(kserveWithMeshEnabledErr, "could not determine if kserve have service mesh enabled") diff --git a/controllers/kserve_inferenceservice_controller_test.go b/controllers/kserve_inferenceservice_controller_test.go index 0aa1e54e..48f2dab1 100644 --- a/controllers/kserve_inferenceservice_controller_test.go +++ b/controllers/kserve_inferenceservice_controller_test.go @@ -103,6 +103,55 @@ var _ = Describe("The Openshift Kserve model controller", func() { return err }, timeout, interval).Should(Succeed()) }) + It("With a new Kserve InferenceService, serving cert annotation should be added to the runtime Service object.", func() { + // We need to stub the cluster state and indicate where is istio namespace (reusing authConfig test data) + if dsciErr := createDSCI(DSCIWithoutAuthorization); dsciErr != nil && !errors.IsAlreadyExists(dsciErr) { + Fail(dsciErr.Error()) + } + // Create a new InferenceService + inferenceService := &kservev1beta1.InferenceService{} + err := convertToStructuredResource(KserveInferenceServicePath1, inferenceService) + Expect(err).NotTo(HaveOccurred()) + inferenceService.SetNamespace(testNs) + Expect(cli.Create(ctx, inferenceService)).Should(Succeed()) + // Update the URL of the InferenceService to indicate it is ready. + deployedInferenceService := &kservev1beta1.InferenceService{} + err = cli.Get(ctx, types.NamespacedName{Name: inferenceService.Name, Namespace: inferenceService.Namespace}, deployedInferenceService) + Expect(err).NotTo(HaveOccurred()) + // url, err := apis.ParseURL("https://example-onnx-mnist-default.test.com") + Expect(err).NotTo(HaveOccurred()) + newAddress := &duckv1.Addressable{ + URL: apis.HTTPS("example-onnx-mnist-default.test.com"), + } + deployedInferenceService.Status.Address = newAddress + err = cli.Status().Update(ctx, deployedInferenceService) + Expect(err).NotTo(HaveOccurred()) + // Stub: Create a Kserve Service, which must be created by the KServe operator. + svc := &corev1.Service{} + err = convertToStructuredResource(testIsvcSvcPath, svc) + Expect(err).NotTo(HaveOccurred()) + svc.SetNamespace(inferenceService.Namespace) + Expect(cli.Create(ctx, svc)).Should(Succeed()) + err = cli.Status().Update(ctx, deployedInferenceService) + Expect(err).NotTo(HaveOccurred()) + // isvcService, err := waitForService(cli, testNs, inferenceService.Name, 5, 2*time.Second) + // Expect(err).NotTo(HaveOccurred()) + + isvcService := &corev1.Service{} + Eventually(func() error { + err := cli.Get(ctx, client.ObjectKey{Namespace: inferenceService.Namespace, Name: inferenceService.Name}, isvcService) + if err != nil { + return err + } + if isvcService.Annotations == nil || isvcService.Annotations[constants.ServingCertAnnotationKey] == "" { + + return fmt.Errorf("Annotation[constants.ServingCertAnnotationKey] is not added yet") + } + return nil + }, timeout, interval).Should(Succeed()) + + Expect(isvcService.Annotations[constants.ServingCertAnnotationKey]).Should(Equal(inferenceService.Name)) + }) It("should create a secret for runtime and update kserve local gateway in the istio-system namespace", func() { // We need to stub the cluster state and indicate where is istio namespace (reusing authConfig test data) diff --git a/controllers/reconcilers/kserve_isvc_service_cert_reconciler.go b/controllers/reconcilers/kserve_isvc_service_cert_reconciler.go new file mode 100644 index 00000000..adff32b5 --- /dev/null +++ b/controllers/reconcilers/kserve_isvc_service_cert_reconciler.go @@ -0,0 +1,131 @@ +/* + +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 reconcilers + +import ( + "context" + + "github.com/go-logr/logr" + kservev1beta1 "github.com/kserve/kserve/pkg/apis/serving/v1beta1" + "github.com/opendatahub-io/odh-model-controller/controllers/constants" + "github.com/opendatahub-io/odh-model-controller/controllers/resources" + v1 "k8s.io/api/core/v1" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/types" + "sigs.k8s.io/controller-runtime/pkg/client" +) + +var _ SubResourceReconciler = (*KserveIsvcServiceReconciler)(nil) + +type KserveIsvcServiceReconciler struct { + client client.Client + serviceHandler resources.ServiceHandler +} + +func NewKserveIsvcServiceReconciler(client client.Client) *KserveIsvcServiceReconciler { + return &KserveIsvcServiceReconciler{ + client: client, + serviceHandler: resources.NewServiceHandler(client), + } +} + +func (r *KserveIsvcServiceReconciler) Delete(ctx context.Context, log logr.Logger, isvc *kservev1beta1.InferenceService) error { + // NOOP - Resources are deleted along with the deletion of InferenceServices + return nil +} + +func (r *KserveIsvcServiceReconciler) Cleanup(_ context.Context, _ logr.Logger, _ string) error { + // NOOP - Resources are deleted along with the deletion of InferenceServices + return nil +} + +func (r *KserveIsvcServiceReconciler) Reconcile(ctx context.Context, log logr.Logger, isvc *kservev1beta1.InferenceService) error { + log.V(1).Info("Reconciling InferenceService Service serving cert") + + // return if Address.URL is not set + if isvc.Status.Address != nil && isvc.Status.Address.URL == nil { + log.V(1).Info("Waiting for the URL as the InferenceService is not ready yet") + return nil + } + + // Create Desired resource + desiredResource, err := r.createDesiredResource(isvc) + if err != nil { + return err + } + + // Get Existing resource + existingResource, err := r.getExistingResource(ctx, log, isvc) + if err != nil { + return err + } + + // Process Delta + if err = r.processDelta(ctx, log, desiredResource, existingResource); err != nil { + return err + } + return nil +} + +func (r *KserveIsvcServiceReconciler) createDesiredResource(isvc *kservev1beta1.InferenceService) (*v1.Service, error) { + service := &v1.Service{ + ObjectMeta: metav1.ObjectMeta{ + Name: "isvc-service", + Annotations: map[string]string{ + constants.ServingCertAnnotationKey: isvc.Name, + }, + }, + } + return service, nil +} + +func (r *KserveIsvcServiceReconciler) getExistingResource(ctx context.Context, log logr.Logger, isvc *kservev1beta1.InferenceService) (*v1.Service, error) { + return r.serviceHandler.FetchService(ctx, log, types.NamespacedName{Name: isvc.Name, Namespace: isvc.Namespace}) +} + +func (r *KserveIsvcServiceReconciler) processDelta(ctx context.Context, log logr.Logger, desiredService *v1.Service, existingService *v1.Service) (err error) { + if isUpdated(desiredService, existingService, log) { + log.V(1).Info("Delta found", "update", existingService.GetName()) + service := existingService.DeepCopy() + if service.Annotations == nil { + service.Annotations = make(map[string]string) + } + service.Annotations = desiredService.Annotations + + if err = r.client.Update(ctx, service); err != nil { + return err + } + } + return nil +} + +func isUpdated(desiredService *v1.Service, existingService *v1.Service, log logr.Logger) bool { + if existingService == nil { + log.Info("The service for the InferenceService has not been created yet") + return false + } + deployedAnnotations := existingService.GetAnnotations() + + if len(deployedAnnotations) != 0 { + if val, exists := existingService.Annotations[constants.ServingCertAnnotationKey]; exists { + if val == desiredService.Annotations[constants.ServingCertAnnotationKey] { + return false + } + } + } + + return true +} diff --git a/controllers/reconcilers/kserve_serverless_inferenceservice_reconciler.go b/controllers/reconcilers/kserve_serverless_inferenceservice_reconciler.go index 94e6b3f4..38388008 100644 --- a/controllers/reconcilers/kserve_serverless_inferenceservice_reconciler.go +++ b/controllers/reconcilers/kserve_serverless_inferenceservice_reconciler.go @@ -46,6 +46,7 @@ func NewKServeServerlessInferenceServiceReconciler(client client.Client) *Kserve NewKServeIstioPeerAuthenticationReconciler(client), NewKServeNetworkPolicyReconciler(client), NewKserveAuthConfigReconciler(client), + NewKserveIsvcServiceReconciler(client), NewKserveGatewayReconciler(client), NewKserveMetricsDashboardReconciler(client), } diff --git a/controllers/webhook/kserve_service_mutator.go b/controllers/webhook/kserve_service_mutator.go deleted file mode 100644 index 933bc39c..00000000 --- a/controllers/webhook/kserve_service_mutator.go +++ /dev/null @@ -1,66 +0,0 @@ -package webhook - -import ( - "context" - "fmt" - - corev1 "k8s.io/api/core/v1" - "k8s.io/apimachinery/pkg/runtime" - "sigs.k8s.io/controller-runtime/pkg/client" - logf "sigs.k8s.io/controller-runtime/pkg/log" - "sigs.k8s.io/controller-runtime/pkg/webhook/admission" -) - -// +kubebuilder:webhook:admissionReviewVersions=v1,path=/mutate-serving-kserve-service,mutating=true,failurePolicy=fail,groups="",resources=services,verbs=create,versions=v1,name=mutating.kserve-service.odh-model-controller.opendatahub.io,sideEffects=None - -type kserveServiceMutator struct { - client client.Client - Decoder *admission.Decoder -} - -func NewKserveServiceMutator(client client.Client) *kserveServiceMutator { - return &kserveServiceMutator{client: client} -} - -// Default implements the admission.Defaulter interface to mutate the resources -func (m *kserveServiceMutator) Default(ctx context.Context, obj runtime.Object) error { - log := logf.FromContext(ctx).WithName("KserviceServiceMutateWebhook") - log.Info("AAAAAAAAAAAAAAAAAAA - mutatingwebhook Called") - - svc, ok := obj.(*corev1.Service) - if !ok { - return fmt.Errorf("unexpected object type") - } - - log.Info("AAAAAAAAAAAAAAAAAAA1 - before checking") - if !hasInferenceServiceOwner(svc) { - return nil - } - log.Info("AAAAAAAAAAAAAAAAAAA1 - after checking") - - // Add the annotation if a matching InferenceService is found - if svc.Annotations == nil { - svc.Annotations = make(map[string]string) - } - svc.Annotations["service.beta.openshift.io/serving-cert-secret-name"] = svc.Name - log.Info("Added annotation to Service", "ServiceName", svc.Name, "Annotation", svc.Annotations["service.beta.openshift.io/serving-cert-secret-name"]) - - return nil -} - -// InjectDecoder injects the decoder into the KserveServiceMutator -func (m *kserveServiceMutator) InjectDecoder(d *admission.Decoder) error { - m.Decoder = d - return nil -} - -// check if the src secret has ownerReferences for InferenceService -func hasInferenceServiceOwner(obj client.Object) bool { - ownerReferences := obj.GetOwnerReferences() - for _, ownerReference := range ownerReferences { - if ownerReference.Kind == "InferenceService" { - return true - } - } - return false -} diff --git a/controllers/webhook_kserve_service_mutator_test.go b/controllers/webhook_kserve_service_mutator_test.go deleted file mode 100644 index d7e85d76..00000000 --- a/controllers/webhook_kserve_service_mutator_test.go +++ /dev/null @@ -1,70 +0,0 @@ -package controllers - -import ( - kservev1beta1 "github.com/kserve/kserve/pkg/apis/serving/v1beta1" - . "github.com/onsi/ginkgo" - . "github.com/onsi/gomega" - "github.com/opendatahub-io/odh-model-controller/controllers/webhook" - corev1 "k8s.io/api/core/v1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "sigs.k8s.io/controller-runtime/pkg/webhook/admission" -) - -var _ = Describe("KServe Service mutator webhook", func() { - var mutator admission.CustomDefaulter - defaultIsvcName := "isvc-name" - defaultNsName := "default" - createServiceOwnedKserve := func() *corev1.Service { - return &corev1.Service{ - ObjectMeta: metav1.ObjectMeta{ - Name: defaultIsvcName, - Namespace: "default", - OwnerReferences: []metav1.OwnerReference{ - { - APIVersion: "serving.kserve.io/v1beta1", - Kind: "InferenceService", - Name: "sklearn-example-isvc-iris-v2-rest", - }, - }, - }, - } - } - - BeforeEach(func() { - mutator = webhook.NewKserveServiceMutator(cli) - - }) - - It("adds serving cert annotation when Service have InferenceService ownerReference", func() { - // Create a new InferenceService - inferenceService := &kservev1beta1.InferenceService{ - ObjectMeta: metav1.ObjectMeta{ - Name: defaultIsvcName, - Namespace: defaultNsName, - }, - } - Expect(cli.Create(ctx, inferenceService)).Should(Succeed()) - - kserveService := createServiceOwnedKserve() - - err := mutator.Default(ctx, kserveService) - Expect(err).ShouldNot(HaveOccurred()) - - // Verify that serving cert annoation is set - Expect(kserveService.Annotations).To(HaveKey("service.beta.openshift.io/serving-cert-secret-name")) - Expect(kserveService.Annotations["service.beta.openshift.io/serving-cert-secret-name"]).To(Equal(defaultIsvcName)) - }) - - It("skips adding annotation when Service does not have InferenceService ownerReference", func() { - kserveServiceName := "different-name" - kserveService := createServiceOwnedKserve() - kserveService.SetName(kserveServiceName) - kserveService.SetOwnerReferences([]metav1.OwnerReference{}) - - err := mutator.Default(ctx, kserveService) - Expect(err).ShouldNot(HaveOccurred()) - - // Verify that serving cert annoation is NOT set - Expect(kserveService.Annotations).NotTo(HaveKey("service.beta.openshift.io/serving-cert-secret-name")) - }) -}) diff --git a/main.go b/main.go index 104bd8ba..ca95fc53 100644 --- a/main.go +++ b/main.go @@ -216,17 +216,8 @@ func main() { os.Exit(1) } - // Set up the mutating webhook using the builder - err = builder.WebhookManagedBy(mgr). - For(&corev1.Service{}). - WithDefaulter(webhook.NewKserveServiceMutator(mgr.GetClient())). - Complete() - if err != nil { - setupLog.Error(err, "unable to setup Kserve Service mutating Webhook") - os.Exit(1) - } } else { - setupLog.Info("Skipping setup of Knative Service validating Webhook, because KServe Serverless setup seems to be disabled in the DataScienceCluster resource.") + setupLog.Info("Skipping setup of Knative Service validating/mutating Webhook, because KServe Serverless setup seems to be disabled in the DataScienceCluster resource.") } //+kubebuilder:scaffold:builder From 13b5def25042a1e9f524ad5319c511c0f3ab4779 Mon Sep 17 00:00:00 2001 From: jooho lee Date: Sat, 22 Jun 2024 10:28:46 -0400 Subject: [PATCH 12/13] remove watches and use clientset to get a secret that is not cached Signed-off-by: jooho lee --- controllers/inferenceservice_controller.go | 66 +------------------ .../kserve_isvc_gateway_reconciler.go | 43 ++++++++++-- 2 files changed, 41 insertions(+), 68 deletions(-) diff --git a/controllers/inferenceservice_controller.go b/controllers/inferenceservice_controller.go index 742323ec..aab63db0 100644 --- a/controllers/inferenceservice_controller.go +++ b/controllers/inferenceservice_controller.go @@ -32,11 +32,10 @@ import ( apierrs "k8s.io/apimachinery/pkg/api/errors" "k8s.io/apimachinery/pkg/types" ctrl "sigs.k8s.io/controller-runtime" + // "sigs.k8s.io/controller-runtime/pkg/builder" "sigs.k8s.io/controller-runtime/pkg/client" - "sigs.k8s.io/controller-runtime/pkg/event" "sigs.k8s.io/controller-runtime/pkg/handler" - "sigs.k8s.io/controller-runtime/pkg/predicate" "sigs.k8s.io/controller-runtime/pkg/reconcile" ) @@ -109,33 +108,6 @@ func (r *OpenshiftInferenceServiceReconciler) Reconcile(ctx context.Context, req return ctrl.Result{}, err } -var certSecretPredicate = predicate.Funcs{ - UpdateFunc: func(e event.UpdateEvent) bool { - return hasInferenceServiceOwner(e.ObjectNew) - }, - CreateFunc: func(e event.CreateEvent) bool { - return hasInferenceServiceOwner(e.Object) - }, - DeleteFunc: func(e event.DeleteEvent) bool { - return hasInferenceServiceOwner(e.Object) - }, - GenericFunc: func(e event.GenericEvent) bool { - return hasInferenceServiceOwner(e.Object) - }, -} - -// check if the src secret has ownerReferences for InferenceService -func hasInferenceServiceOwner(obj client.Object) bool { - - ownerReferences := obj.GetOwnerReferences() - for _, ownerReference := range ownerReferences { - if ownerReference.Kind == "Service" { - return true - } - } - return false -} - // SetupWithManager sets up the controller with the Manager. func (r *OpenshiftInferenceServiceReconciler) SetupWithManager(mgr ctrl.Manager) error { builder := ctrl.NewControllerManagedBy(mgr). @@ -179,42 +151,8 @@ func (r *OpenshiftInferenceServiceReconciler) SetupWithManager(mgr ctrl.Manager) }) } return reconcileRequests - })). - Watches(&corev1.Secret{}, - handler.EnqueueRequestsFromMapFunc(func(ctx context.Context, o client.Object) []reconcile.Request { - r.log.Info("Reconcile event triggered by Secret: " + o.GetName()) - isvc := &kservev1beta1.InferenceService{} - err := r.client.Get(ctx, types.NamespacedName{Name: o.GetName(), Namespace: o.GetNamespace()}, isvc) - if err != nil { - if apierrs.IsNotFound(err) { - return []reconcile.Request{} - } - r.log.Error(err, "Error getting the inferenceService", "name", o.GetName()) - return []reconcile.Request{} - } - - return []reconcile.Request{ - {NamespacedName: types.NamespacedName{Name: o.GetName(), Namespace: o.GetNamespace()}}, - } })) - - // Watches(&corev1.Secret{}, - // handler.EnqueueRequestsFromMapFunc(func(ctx context.Context, o client.Object) []reconcile.Request { - // r.log.Info("Reconcile event triggered by Secret: " + o.GetName()) - // isvc := &kservev1beta1.InferenceService{} - // err := r.client.Get(ctx, types.NamespacedName{Name: o.GetName(), Namespace: o.GetNamespace()}, isvc) - // if err != nil { - // if apierrs.IsNotFound(err) { - // return []reconcile.Request{} - // } - // r.log.Error(err, "Error getting the inferenceService", "name", o.GetName()) - // return []reconcile.Request{} - // } - - // return []reconcile.Request{ - // {NamespacedName: types.NamespacedName{Name: o.GetName(), Namespace: o.GetNamespace()}}, - // } - // }), builder.WithPredicates(certSecretPredicate)) + kserveWithMeshEnabled, kserveWithMeshEnabledErr := utils.VerifyIfComponentIsEnabled(context.Background(), mgr.GetClient(), utils.KServeWithServiceMeshComponent) if kserveWithMeshEnabledErr != nil { r.log.V(1).Error(kserveWithMeshEnabledErr, "could not determine if kserve have service mesh enabled") diff --git a/controllers/reconcilers/kserve_isvc_gateway_reconciler.go b/controllers/reconcilers/kserve_isvc_gateway_reconciler.go index 5350491f..b2b0aa47 100644 --- a/controllers/reconcilers/kserve_isvc_gateway_reconciler.go +++ b/controllers/reconcilers/kserve_isvc_gateway_reconciler.go @@ -18,6 +18,7 @@ package reconcilers import ( "context" "fmt" + "net/url" "reflect" "github.com/go-logr/logr" @@ -31,10 +32,12 @@ import ( "k8s.io/apimachinery/pkg/api/errors" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/types" + "k8s.io/client-go/kubernetes" "sigs.k8s.io/controller-runtime/pkg/client" istiov1beta1 "istio.io/api/networking/v1beta1" istioclientv1beta1 "istio.io/client-go/pkg/apis/networking/v1beta1" + "k8s.io/client-go/rest" ) var _ SubResourceReconciler = (*KserveGatewayReconciler)(nil) @@ -42,14 +45,29 @@ var meshNamespace string type KserveGatewayReconciler struct { client client.Client + clientset *kubernetes.Clientset secretHandler resources.SecretHandler gatewayHandler resources.GatewayHandler deltaProcessor processors.DeltaProcessor } func NewKserveGatewayReconciler(client client.Client) *KserveGatewayReconciler { + config, err := rest.InClusterConfig() + if err != nil { + config, err = rest.InClusterConfig() + if err != nil { + panic(err.Error()) + } + } + + clientset, err := kubernetes.NewForConfig(config) + if err != nil { + panic(err.Error()) + } + return &KserveGatewayReconciler{ client: client, + clientset: clientset, secretHandler: resources.NewSecretHandler(client), gatewayHandler: resources.NewGatewayHandler(client), deltaProcessor: processors.NewDeltaProcessor(), @@ -68,7 +86,8 @@ func (r *KserveGatewayReconciler) Reconcile(ctx context.Context, log logr.Logger } // return if serving cert secret in the source namespace is not created - srcCertSecret, err := r.secretHandler.Get(ctx, types.NamespacedName{Name: isvc.Name, Namespace: isvc.Namespace}) + // srcCertSecret, err := r.secretHandler.Get(ctx, types.NamespacedName{Name: isvc.Name, Namespace: isvc.Namespace}) + srcCertSecret, err := r.clientset.CoreV1().Secrets(isvc.Namespace).Get(ctx, isvc.Name, metav1.GetOptions{}) if err != nil { if errors.IsNotFound(err) { log.V(1).Info(fmt.Sprintf("Waiting for the creation of the serving certificate Secret(%s) in %s namespace", isvc.Name, isvc.Namespace)) @@ -78,11 +97,12 @@ func (r *KserveGatewayReconciler) Reconcile(ctx context.Context, log logr.Logger } // Copy src secret to destination namespace when there is not the synced secret. - copiedCertSecret, err := r.secretHandler.Get(ctx, types.NamespacedName{Name: fmt.Sprintf("%s-%s", isvc.Name, isvc.Namespace), Namespace: meshNamespace}) + // copiedCertSecret, err := r.secretHandler.Get(ctx, types.NamespacedName{Name: fmt.Sprintf("%s-%s", isvc.Name, isvc.Namespace), Namespace: meshNamespace}) + copiedCertSecret, err := r.clientset.CoreV1().Secrets(meshNamespace).Get(ctx, fmt.Sprintf("%s-%s", isvc.Name, isvc.Namespace), metav1.GetOptions{}) if err != nil { if errors.IsNotFound(err) { if err := r.copyServingCertSecretFromIsvcNamespace(ctx, srcCertSecret, nil); err != nil { - log.V(1).Error(err, fmt.Sprintf("Failed to copy the serving certificate Secret(%s) for InferenceService in %s namespace", srcCertSecret.Name, meshNamespace)) + log.V(1).Error(err, fmt.Sprintf("Failed to copy the serving certificate Secret(%s) to %s namespace", srcCertSecret.Name, meshNamespace)) return err } } @@ -121,7 +141,10 @@ func (r *KserveGatewayReconciler) Reconcile(ctx context.Context, log logr.Logger } func (r *KserveGatewayReconciler) getDesiredResource(isvc *kservev1beta1.InferenceService) (*istioclientv1beta1.Gateway, error) { - hostname := isvc.Status.Address.URL.String() + hostname,err := getURLWithoutScheme(isvc) + if err != nil{ + return nil, err + } desiredGateway := &istioclientv1beta1.Gateway{ ObjectMeta: metav1.ObjectMeta{ @@ -226,6 +249,9 @@ func (r *KserveGatewayReconciler) copyServingCertSecretFromIsvcNamespace(ctx con ObjectMeta: metav1.ObjectMeta{ Name: fmt.Sprintf("%s-%s", sourceSecret.Name, sourceSecret.Namespace), Namespace: meshNamespace, + Labels: map[string]string{ + "opendatahub.io/managed": "true", + }, }, Data: sourceSecret.Data, Type: sourceSecret.Type, @@ -255,3 +281,12 @@ func (r *KserveGatewayReconciler) deleteServingCertSecretInIstioNamespace(ctx co } return nil } + +func getURLWithoutScheme(isvc *kservev1beta1.InferenceService) (string, error) { + parsedURL, err := url.Parse(isvc.Status.Address.URL.String()) + if err != nil { + return "", err + } + + return parsedURL.Host + parsedURL.Path, nil +} From ca3d22424614ff1028a5d330248aa6a7997a815e Mon Sep 17 00:00:00 2001 From: jooho lee Date: Tue, 25 Jun 2024 05:02:47 -0400 Subject: [PATCH 13/13] Add clientReader to get a secret that is not cached by manager Signed-off-by: jooho lee --- controllers/inferenceservice_controller.go | 8 +- ...kserve_inferenceservice_controller_test.go | 11 +- .../kserve_isvc_gateway_reconciler.go | 35 +-- .../kserve_isvc_service_cert_reconciler.go | 1 + ..._serverless_inferenceservice_reconciler.go | 5 +- controllers/suite_test.go | 7 + go.mod | 1 + go.sum | 296 ------------------ main.go | 3 + 9 files changed, 40 insertions(+), 327 deletions(-) diff --git a/controllers/inferenceservice_controller.go b/controllers/inferenceservice_controller.go index aab63db0..7ad0f6dc 100644 --- a/controllers/inferenceservice_controller.go +++ b/controllers/inferenceservice_controller.go @@ -42,6 +42,7 @@ import ( // OpenshiftInferenceServiceReconciler holds the controller configuration. type OpenshiftInferenceServiceReconciler struct { client client.Client + clientReader client.Reader log logr.Logger MeshDisabled bool mmISVCReconciler *reconcilers.ModelMeshInferenceServiceReconciler @@ -49,13 +50,14 @@ type OpenshiftInferenceServiceReconciler struct { kserveRawISVCReconciler *reconcilers.KserveRawInferenceServiceReconciler } -func NewOpenshiftInferenceServiceReconciler(client client.Client, log logr.Logger, meshDisabled bool) *OpenshiftInferenceServiceReconciler { +func NewOpenshiftInferenceServiceReconciler(client client.Client, clientReader client.Reader, log logr.Logger, meshDisabled bool) *OpenshiftInferenceServiceReconciler { return &OpenshiftInferenceServiceReconciler{ client: client, + clientReader: clientReader, log: log, MeshDisabled: meshDisabled, mmISVCReconciler: reconcilers.NewModelMeshInferenceServiceReconciler(client), - kserveServerlessISVCReconciler: reconcilers.NewKServeServerlessInferenceServiceReconciler(client), + kserveServerlessISVCReconciler: reconcilers.NewKServeServerlessInferenceServiceReconciler(client, clientReader), kserveRawISVCReconciler: reconcilers.NewKServeRawInferenceServiceReconciler(client), } } @@ -152,7 +154,7 @@ func (r *OpenshiftInferenceServiceReconciler) SetupWithManager(mgr ctrl.Manager) } return reconcileRequests })) - + kserveWithMeshEnabled, kserveWithMeshEnabledErr := utils.VerifyIfComponentIsEnabled(context.Background(), mgr.GetClient(), utils.KServeWithServiceMeshComponent) if kserveWithMeshEnabledErr != nil { r.log.V(1).Error(kserveWithMeshEnabledErr, "could not determine if kserve have service mesh enabled") diff --git a/controllers/kserve_inferenceservice_controller_test.go b/controllers/kserve_inferenceservice_controller_test.go index 48f2dab1..dc7ab604 100644 --- a/controllers/kserve_inferenceservice_controller_test.go +++ b/controllers/kserve_inferenceservice_controller_test.go @@ -275,7 +275,6 @@ var _ = Describe("The Openshift Kserve model controller", func() { kserveLocalGateway := &istioclientv1beta1.Gateway{} err := convertToStructuredResource(kserveLocalGatewayPath, kserveLocalGateway) Expect(err).NotTo(HaveOccurred()) - Expect(cli.Create(ctx, kserveLocalGateway)).Should(Succeed()) // Stub: Create a certificate Secret, which must be created by the openshift service-ca operator. @@ -312,7 +311,15 @@ var _ = Describe("The Openshift Kserve model controller", func() { // Verify that the certificate secret is created in the istio-system namespace. Eventually(func() error { secret := &corev1.Secret{} - err := cli.Get(ctx, client.ObjectKey{Namespace: constants.IstioNamespace, Name: fmt.Sprintf("%s-%s", inferenceService.Name, inferenceService.Namespace)}, secret) + err := cli.Get(ctx, types.NamespacedName{Name: inferenceService.Name, Namespace: inferenceService.Namespace}, secret) + if err != nil { + return err + } + return nil + }, timeout, interval).Should(Succeed()) + + Eventually(func() error { + err = cli.Get(ctx, client.ObjectKey{Namespace: constants.IstioNamespace, Name: fmt.Sprintf("%s-%s", inferenceService.Name, inferenceService.Namespace)}, secret) if err != nil { return err } diff --git a/controllers/reconcilers/kserve_isvc_gateway_reconciler.go b/controllers/reconcilers/kserve_isvc_gateway_reconciler.go index b2b0aa47..98013195 100644 --- a/controllers/reconcilers/kserve_isvc_gateway_reconciler.go +++ b/controllers/reconcilers/kserve_isvc_gateway_reconciler.go @@ -32,12 +32,10 @@ import ( "k8s.io/apimachinery/pkg/api/errors" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/types" - "k8s.io/client-go/kubernetes" "sigs.k8s.io/controller-runtime/pkg/client" istiov1beta1 "istio.io/api/networking/v1beta1" istioclientv1beta1 "istio.io/client-go/pkg/apis/networking/v1beta1" - "k8s.io/client-go/rest" ) var _ SubResourceReconciler = (*KserveGatewayReconciler)(nil) @@ -45,29 +43,17 @@ var meshNamespace string type KserveGatewayReconciler struct { client client.Client - clientset *kubernetes.Clientset + clientReader client.Reader secretHandler resources.SecretHandler gatewayHandler resources.GatewayHandler deltaProcessor processors.DeltaProcessor } - -func NewKserveGatewayReconciler(client client.Client) *KserveGatewayReconciler { - config, err := rest.InClusterConfig() - if err != nil { - config, err = rest.InClusterConfig() - if err != nil { - panic(err.Error()) - } - } - - clientset, err := kubernetes.NewForConfig(config) - if err != nil { - panic(err.Error()) - } +// The clientReader uses the API server to retrieve Secrets that are not cached. By default, only Secrets with the specific label "opendatahub.io/managed: true" are cached. +func NewKserveGatewayReconciler(client client.Client, clientReader client.Reader) *KserveGatewayReconciler { return &KserveGatewayReconciler{ client: client, - clientset: clientset, + clientReader: clientReader, secretHandler: resources.NewSecretHandler(client), gatewayHandler: resources.NewGatewayHandler(client), deltaProcessor: processors.NewDeltaProcessor(), @@ -86,8 +72,8 @@ func (r *KserveGatewayReconciler) Reconcile(ctx context.Context, log logr.Logger } // return if serving cert secret in the source namespace is not created - // srcCertSecret, err := r.secretHandler.Get(ctx, types.NamespacedName{Name: isvc.Name, Namespace: isvc.Namespace}) - srcCertSecret, err := r.clientset.CoreV1().Secrets(isvc.Namespace).Get(ctx, isvc.Name, metav1.GetOptions{}) + srcCertSecret := &corev1.Secret{} + err := r.clientReader.Get(ctx, types.NamespacedName{Name: isvc.Name, Namespace: isvc.Namespace}, srcCertSecret) if err != nil { if errors.IsNotFound(err) { log.V(1).Info(fmt.Sprintf("Waiting for the creation of the serving certificate Secret(%s) in %s namespace", isvc.Name, isvc.Namespace)) @@ -97,8 +83,9 @@ func (r *KserveGatewayReconciler) Reconcile(ctx context.Context, log logr.Logger } // Copy src secret to destination namespace when there is not the synced secret. - // copiedCertSecret, err := r.secretHandler.Get(ctx, types.NamespacedName{Name: fmt.Sprintf("%s-%s", isvc.Name, isvc.Namespace), Namespace: meshNamespace}) - copiedCertSecret, err := r.clientset.CoreV1().Secrets(meshNamespace).Get(ctx, fmt.Sprintf("%s-%s", isvc.Name, isvc.Namespace), metav1.GetOptions{}) + // This use clientReader because the secret that it looks for is not cached. + copiedCertSecret := &corev1.Secret{} + err = r.clientReader.Get(ctx, types.NamespacedName{Name: fmt.Sprintf("%s-%s", isvc.Name, isvc.Namespace), Namespace: meshNamespace}, copiedCertSecret) if err != nil { if errors.IsNotFound(err) { if err := r.copyServingCertSecretFromIsvcNamespace(ctx, srcCertSecret, nil); err != nil { @@ -141,8 +128,8 @@ func (r *KserveGatewayReconciler) Reconcile(ctx context.Context, log logr.Logger } func (r *KserveGatewayReconciler) getDesiredResource(isvc *kservev1beta1.InferenceService) (*istioclientv1beta1.Gateway, error) { - hostname,err := getURLWithoutScheme(isvc) - if err != nil{ + hostname, err := getURLWithoutScheme(isvc) + if err != nil { return nil, err } diff --git a/controllers/reconcilers/kserve_isvc_service_cert_reconciler.go b/controllers/reconcilers/kserve_isvc_service_cert_reconciler.go index adff32b5..902bde7f 100644 --- a/controllers/reconcilers/kserve_isvc_service_cert_reconciler.go +++ b/controllers/reconcilers/kserve_isvc_service_cert_reconciler.go @@ -52,6 +52,7 @@ func (r *KserveIsvcServiceReconciler) Cleanup(_ context.Context, _ logr.Logger, return nil } +//To support KServe local gateway using HTTPS, each InferenceService (ISVC) needs a certificate. This reconciliation process helps add a serving certificate annotation to the ISVC service. func (r *KserveIsvcServiceReconciler) Reconcile(ctx context.Context, log logr.Logger, isvc *kservev1beta1.InferenceService) error { log.V(1).Info("Reconciling InferenceService Service serving cert") diff --git a/controllers/reconcilers/kserve_serverless_inferenceservice_reconciler.go b/controllers/reconcilers/kserve_serverless_inferenceservice_reconciler.go index 38388008..00365f0d 100644 --- a/controllers/reconcilers/kserve_serverless_inferenceservice_reconciler.go +++ b/controllers/reconcilers/kserve_serverless_inferenceservice_reconciler.go @@ -33,7 +33,8 @@ type KserveServerlessInferenceServiceReconciler struct { subResourceReconcilers []SubResourceReconciler } -func NewKServeServerlessInferenceServiceReconciler(client client.Client) *KserveServerlessInferenceServiceReconciler { +func NewKServeServerlessInferenceServiceReconciler(client client.Client, clientReader client.Reader) *KserveServerlessInferenceServiceReconciler { + subResourceReconciler := []SubResourceReconciler{ NewKserveServiceMeshMemberReconciler(client), NewKserveRouteReconciler(client), @@ -47,7 +48,7 @@ func NewKServeServerlessInferenceServiceReconciler(client client.Client) *Kserve NewKServeNetworkPolicyReconciler(client), NewKserveAuthConfigReconciler(client), NewKserveIsvcServiceReconciler(client), - NewKserveGatewayReconciler(client), + NewKserveGatewayReconciler(client, clientReader), NewKserveMetricsDashboardReconciler(client), } diff --git a/controllers/suite_test.go b/controllers/suite_test.go index b0758609..afc3df02 100644 --- a/controllers/suite_test.go +++ b/controllers/suite_test.go @@ -43,6 +43,8 @@ import ( routev1 "github.com/openshift/api/route/v1" istioclientv1beta1 "istio.io/client-go/pkg/apis/networking/v1beta1" corev1 "k8s.io/api/core/v1" + "k8s.io/client-go/kubernetes" + "k8s.io/client-go/kubernetes/fake" "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/controller-runtime/pkg/envtest" logf "sigs.k8s.io/controller-runtime/pkg/log" @@ -157,6 +159,7 @@ var _ = BeforeSuite(func() { err = (NewOpenshiftInferenceServiceReconciler( mgr.GetClient(), + mgr.GetAPIReader(), ctrl.Log.WithName("controllers").WithName("InferenceService-controller"), false)). SetupWithManager(mgr) @@ -284,3 +287,7 @@ func createTestNamespaceName() string { } return "test-ns-" + string(b) } + +func NewFakeClientsetWrapper(fakeClient *fake.Clientset) kubernetes.Interface { + return fakeClient +} diff --git a/go.mod b/go.mod index c71d0843..72d85158 100644 --- a/go.mod +++ b/go.mod @@ -41,6 +41,7 @@ require ( github.com/cespare/xxhash/v2 v2.2.0 // indirect github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect github.com/emicklei/go-restful/v3 v3.11.0 // indirect + github.com/evanphx/json-patch v5.7.0+incompatible // indirect github.com/evanphx/json-patch/v5 v5.7.0 // indirect github.com/fsnotify/fsnotify v1.7.0 // indirect github.com/go-logr/zapr v1.3.0 // indirect diff --git a/go.sum b/go.sum index a3e825af..0de96e76 100644 --- a/go.sum +++ b/go.sum @@ -6,268 +6,86 @@ cloud.google.com/go v0.44.2/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxK cloud.google.com/go v0.44.3/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxKY= cloud.google.com/go v0.110.10 h1:LXy9GEO+timppncPIAZoOj3l58LIU9k+kn48AN7IO3Y= cloud.google.com/go v0.110.10/go.mod h1:v1OoFqYxiBkUrruItNM3eT4lLByNjxmJSV/xDKJNnic= -cloud.google.com/go/accessapproval v1.7.4/go.mod h1:/aTEh45LzplQgFYdQdwPMR9YdX0UlhBmvB84uAmQKUc= -cloud.google.com/go/accesscontextmanager v1.8.4/go.mod h1:ParU+WbMpD34s5JFEnGAnPBYAgUHozaTmDJU7aCU9+M= -cloud.google.com/go/aiplatform v1.52.0/go.mod h1:pwZMGvqe0JRkI1GWSZCtnAfrR4K1bv65IHILGA//VEU= -cloud.google.com/go/analytics v0.21.6/go.mod h1:eiROFQKosh4hMaNhF85Oc9WO97Cpa7RggD40e/RBy8w= -cloud.google.com/go/apigateway v1.6.4/go.mod h1:0EpJlVGH5HwAN4VF4Iec8TAzGN1aQgbxAWGJsnPCGGY= -cloud.google.com/go/apigeeconnect v1.6.4/go.mod h1:CapQCWZ8TCjnU0d7PobxhpOdVz/OVJ2Hr/Zcuu1xFx0= -cloud.google.com/go/apigeeregistry v0.8.2/go.mod h1:h4v11TDGdeXJDJvImtgK2AFVvMIgGWjSb0HRnBSjcX8= -cloud.google.com/go/appengine v1.8.4/go.mod h1:TZ24v+wXBujtkK77CXCpjZbnuTvsFNT41MUaZ28D6vg= -cloud.google.com/go/area120 v0.8.4/go.mod h1:jfawXjxf29wyBXr48+W+GyX/f8fflxp642D/bb9v68M= -cloud.google.com/go/artifactregistry v1.14.6/go.mod h1:np9LSFotNWHcjnOgh8UVK0RFPCTUGbO0ve3384xyHfE= -cloud.google.com/go/asset v1.15.3/go.mod h1:yYLfUD4wL4X589A9tYrv4rFrba0QlDeag0CMcM5ggXU= -cloud.google.com/go/assuredworkloads v1.11.4/go.mod h1:4pwwGNwy1RP0m+y12ef3Q/8PaiWrIDQ6nD2E8kvWI9U= -cloud.google.com/go/automl v1.13.4/go.mod h1:ULqwX/OLZ4hBVfKQaMtxMSTlPx0GqGbWN8uA/1EqCP8= -cloud.google.com/go/baremetalsolution v1.2.3/go.mod h1:/UAQ5xG3faDdy180rCUv47e0jvpp3BFxT+Cl0PFjw5g= -cloud.google.com/go/batch v1.6.3/go.mod h1:J64gD4vsNSA2O5TtDB5AAux3nJ9iV8U3ilg3JDBYejU= -cloud.google.com/go/beyondcorp v1.0.3/go.mod h1:HcBvnEd7eYr+HGDd5ZbuVmBYX019C6CEXBonXbCVwJo= cloud.google.com/go/bigquery v1.0.1/go.mod h1:i/xbL2UlR5RvWAURpBYZTtm/cXjCha9lbfbpx4poX+o= -cloud.google.com/go/bigquery v1.57.1/go.mod h1:iYzC0tGVWt1jqSzBHqCr3lrRn0u13E8e+AqowBsDgug= -cloud.google.com/go/billing v1.17.4/go.mod h1:5DOYQStCxquGprqfuid/7haD7th74kyMBHkjO/OvDtk= -cloud.google.com/go/binaryauthorization v1.7.3/go.mod h1:VQ/nUGRKhrStlGr+8GMS8f6/vznYLkdK5vaKfdCIpvU= -cloud.google.com/go/certificatemanager v1.7.4/go.mod h1:FHAylPe/6IIKuaRmHbjbdLhGhVQ+CWHSD5Jq0k4+cCE= -cloud.google.com/go/channel v1.17.3/go.mod h1:QcEBuZLGGrUMm7kNj9IbU1ZfmJq2apotsV83hbxX7eE= -cloud.google.com/go/cloudbuild v1.14.3/go.mod h1:eIXYWmRt3UtggLnFGx4JvXcMj4kShhVzGndL1LwleEM= -cloud.google.com/go/clouddms v1.7.3/go.mod h1:fkN2HQQNUYInAU3NQ3vRLkV2iWs8lIdmBKOx4nrL6Hc= -cloud.google.com/go/cloudtasks v1.12.4/go.mod h1:BEPu0Gtt2dU6FxZHNqqNdGqIG86qyWKBPGnsb7udGY0= cloud.google.com/go/compute v1.23.3 h1:6sVlXXBmbd7jNX0Ipq0trII3e4n1/MsADLK6a+aiVlk= cloud.google.com/go/compute v1.23.3/go.mod h1:VCgBUoMnIVIR0CscqQiPJLAG25E3ZRZMzcFZeQ+h8CI= cloud.google.com/go/compute/metadata v0.2.3 h1:mg4jlk7mCAj6xXp9UJ4fjI9VUI5rubuGBW5aJ7UnBMY= cloud.google.com/go/compute/metadata v0.2.3/go.mod h1:VAV5nSsACxMJvgaAuX6Pk2AawlZn8kiOGuCv6gTkwuA= -cloud.google.com/go/contactcenterinsights v1.11.3/go.mod h1:HHX5wrz5LHVAwfI2smIotQG9x8Qd6gYilaHcLLLmNis= -cloud.google.com/go/container v1.27.1/go.mod h1:b1A1gJeTBXVLQ6GGw9/9M4FG94BEGsqJ5+t4d/3N7O4= -cloud.google.com/go/containeranalysis v0.11.3/go.mod h1:kMeST7yWFQMGjiG9K7Eov+fPNQcGhb8mXj/UcTiWw9U= -cloud.google.com/go/datacatalog v1.18.3/go.mod h1:5FR6ZIF8RZrtml0VUao22FxhdjkoG+a0866rEnObryM= -cloud.google.com/go/dataflow v0.9.4/go.mod h1:4G8vAkHYCSzU8b/kmsoR2lWyHJD85oMJPHMtan40K8w= -cloud.google.com/go/dataform v0.9.1/go.mod h1:pWTg+zGQ7i16pyn0bS1ruqIE91SdL2FDMvEYu/8oQxs= -cloud.google.com/go/datafusion v1.7.4/go.mod h1:BBs78WTOLYkT4GVZIXQCZT3GFpkpDN4aBY4NDX/jVlM= -cloud.google.com/go/datalabeling v0.8.4/go.mod h1:Z1z3E6LHtffBGrNUkKwbwbDxTiXEApLzIgmymj8A3S8= -cloud.google.com/go/dataplex v1.11.1/go.mod h1:mHJYQQ2VEJHsyoC0OdNyy988DvEbPhqFs5OOLffLX0c= -cloud.google.com/go/dataproc/v2 v2.2.3/go.mod h1:G5R6GBc9r36SXv/RtZIVfB8SipI+xVn0bX5SxUzVYbY= -cloud.google.com/go/dataqna v0.8.4/go.mod h1:mySRKjKg5Lz784P6sCov3p1QD+RZQONRMRjzGNcFd0c= cloud.google.com/go/datastore v1.0.0/go.mod h1:LXYbyblFSglQ5pkeyhO+Qmw7ukd3C+pD7TKLgZqpHYE= -cloud.google.com/go/datastore v1.15.0/go.mod h1:GAeStMBIt9bPS7jMJA85kgkpsMkvseWWXiaHya9Jes8= -cloud.google.com/go/datastream v1.10.3/go.mod h1:YR0USzgjhqA/Id0Ycu1VvZe8hEWwrkjuXrGbzeDOSEA= -cloud.google.com/go/deploy v1.14.2/go.mod h1:e5XOUI5D+YGldyLNZ21wbp9S8otJbBE4i88PtO9x/2g= -cloud.google.com/go/dialogflow v1.44.3/go.mod h1:mHly4vU7cPXVweuB5R0zsYKPMzy240aQdAu06SqBbAQ= -cloud.google.com/go/dlp v1.11.1/go.mod h1:/PA2EnioBeXTL/0hInwgj0rfsQb3lpE3R8XUJxqUNKI= -cloud.google.com/go/documentai v1.23.5/go.mod h1:ghzBsyVTiVdkfKaUCum/9bGBEyBjDO4GfooEcYKhN+g= -cloud.google.com/go/domains v0.9.4/go.mod h1:27jmJGShuXYdUNjyDG0SodTfT5RwLi7xmH334Gvi3fY= -cloud.google.com/go/edgecontainer v1.1.4/go.mod h1:AvFdVuZuVGdgaE5YvlL1faAoa1ndRR/5XhXZvPBHbsE= -cloud.google.com/go/errorreporting v0.3.0/go.mod h1:xsP2yaAp+OAW4OIm60An2bbLpqIhKXdWR/tawvl7QzU= -cloud.google.com/go/essentialcontacts v1.6.5/go.mod h1:jjYbPzw0x+yglXC890l6ECJWdYeZ5dlYACTFL0U/VuM= -cloud.google.com/go/eventarc v1.13.3/go.mod h1:RWH10IAZIRcj1s/vClXkBgMHwh59ts7hSWcqD3kaclg= -cloud.google.com/go/filestore v1.7.4/go.mod h1:S5JCxIbFjeBhWMTfIYH2Jx24J6BqjwpkkPl+nBA5DlI= -cloud.google.com/go/firestore v1.14.0/go.mod h1:96MVaHLsEhbvkBEdZgfN+AS/GIkco1LRpH9Xp9YZfzQ= -cloud.google.com/go/functions v1.15.4/go.mod h1:CAsTc3VlRMVvx+XqXxKqVevguqJpnVip4DdonFsX28I= -cloud.google.com/go/gkebackup v1.3.4/go.mod h1:gLVlbM8h/nHIs09ns1qx3q3eaXcGSELgNu1DWXYz1HI= -cloud.google.com/go/gkeconnect v0.8.4/go.mod h1:84hZz4UMlDCKl8ifVW8layK4WHlMAFeq8vbzjU0yJkw= -cloud.google.com/go/gkehub v0.14.4/go.mod h1:Xispfu2MqnnFt8rV/2/3o73SK1snL8s9dYJ9G2oQMfc= -cloud.google.com/go/gkemulticloud v1.0.3/go.mod h1:7NpJBN94U6DY1xHIbsDqB2+TFZUfjLUKLjUX8NGLor0= -cloud.google.com/go/gsuiteaddons v1.6.4/go.mod h1:rxtstw7Fx22uLOXBpsvb9DUbC+fiXs7rF4U29KHM/pE= cloud.google.com/go/iam v1.1.5 h1:1jTsCu4bcsNsE4iiqNT5SHwrDRCfRmIaaaVFhRveTJI= cloud.google.com/go/iam v1.1.5/go.mod h1:rB6P/Ic3mykPbFio+vo7403drjlgvoWfYpJhMXEbzv8= -cloud.google.com/go/iap v1.9.3/go.mod h1:DTdutSZBqkkOm2HEOTBzhZxh2mwwxshfD/h3yofAiCw= -cloud.google.com/go/ids v1.4.4/go.mod h1:z+WUc2eEl6S/1aZWzwtVNWoSZslgzPxAboS0lZX0HjI= -cloud.google.com/go/iot v1.7.4/go.mod h1:3TWqDVvsddYBG++nHSZmluoCAVGr1hAcabbWZNKEZLk= -cloud.google.com/go/kms v1.15.5/go.mod h1:cU2H5jnp6G2TDpUGZyqTCoy1n16fbubHZjmVXSMtwDI= -cloud.google.com/go/language v1.12.2/go.mod h1:9idWapzr/JKXBBQ4lWqVX/hcadxB194ry20m/bTrhWc= -cloud.google.com/go/lifesciences v0.9.4/go.mod h1:bhm64duKhMi7s9jR9WYJYvjAFJwRqNj+Nia7hF0Z7JA= -cloud.google.com/go/logging v1.8.1/go.mod h1:TJjR+SimHwuC8MZ9cjByQulAMgni+RkXeI3wwctHJEI= -cloud.google.com/go/longrunning v0.5.4/go.mod h1:zqNVncI0BOP8ST6XQD1+VcvuShMmq7+xFSzOL++V0dI= -cloud.google.com/go/managedidentities v1.6.4/go.mod h1:WgyaECfHmF00t/1Uk8Oun3CQ2PGUtjc3e9Alh79wyiM= -cloud.google.com/go/maps v1.6.1/go.mod h1:4+buOHhYXFBp58Zj/K+Lc1rCmJssxxF4pJ5CJnhdz18= -cloud.google.com/go/mediatranslation v0.8.4/go.mod h1:9WstgtNVAdN53m6TQa5GjIjLqKQPXe74hwSCxUP6nj4= -cloud.google.com/go/memcache v1.10.4/go.mod h1:v/d8PuC8d1gD6Yn5+I3INzLR01IDn0N4Ym56RgikSI0= -cloud.google.com/go/metastore v1.13.3/go.mod h1:K+wdjXdtkdk7AQg4+sXS8bRrQa9gcOr+foOMF2tqINE= -cloud.google.com/go/monitoring v1.16.3/go.mod h1:KwSsX5+8PnXv5NJnICZzW2R8pWTis8ypC4zmdRD63Tw= -cloud.google.com/go/networkconnectivity v1.14.3/go.mod h1:4aoeFdrJpYEXNvrnfyD5kIzs8YtHg945Og4koAjHQek= -cloud.google.com/go/networkmanagement v1.9.3/go.mod h1:y7WMO1bRLaP5h3Obm4tey+NquUvB93Co1oh4wpL+XcU= -cloud.google.com/go/networksecurity v0.9.4/go.mod h1:E9CeMZ2zDsNBkr8axKSYm8XyTqNhiCHf1JO/Vb8mD1w= -cloud.google.com/go/notebooks v1.11.2/go.mod h1:z0tlHI/lREXC8BS2mIsUeR3agM1AkgLiS+Isov3SS70= -cloud.google.com/go/optimization v1.6.2/go.mod h1:mWNZ7B9/EyMCcwNl1frUGEuY6CPijSkz88Fz2vwKPOY= -cloud.google.com/go/orchestration v1.8.4/go.mod h1:d0lywZSVYtIoSZXb0iFjv9SaL13PGyVOKDxqGxEf/qI= -cloud.google.com/go/orgpolicy v1.11.4/go.mod h1:0+aNV/nrfoTQ4Mytv+Aw+stBDBjNf4d8fYRA9herfJI= -cloud.google.com/go/osconfig v1.12.4/go.mod h1:B1qEwJ/jzqSRslvdOCI8Kdnp0gSng0xW4LOnIebQomA= -cloud.google.com/go/oslogin v1.12.2/go.mod h1:CQ3V8Jvw4Qo4WRhNPF0o+HAM4DiLuE27Ul9CX9g2QdY= -cloud.google.com/go/phishingprotection v0.8.4/go.mod h1:6b3kNPAc2AQ6jZfFHioZKg9MQNybDg4ixFd4RPZZ2nE= -cloud.google.com/go/policytroubleshooter v1.10.2/go.mod h1:m4uF3f6LseVEnMV6nknlN2vYGRb+75ylQwJdnOXfnv0= -cloud.google.com/go/privatecatalog v0.9.4/go.mod h1:SOjm93f+5hp/U3PqMZAHTtBtluqLygrDrVO8X8tYtG0= -cloud.google.com/go/pubsub v1.33.0/go.mod h1:f+w71I33OMyxf9VpMVcZbnG5KSUkCOUHYpFd5U1GdRc= -cloud.google.com/go/pubsublite v1.8.1/go.mod h1:fOLdU4f5xldK4RGJrBMm+J7zMWNj/k4PxwEZXy39QS0= -cloud.google.com/go/recaptchaenterprise/v2 v2.8.3/go.mod h1:Dak54rw6lC2gBY8FBznpOCAR58wKf+R+ZSJRoeJok4w= -cloud.google.com/go/recommendationengine v0.8.4/go.mod h1:GEteCf1PATl5v5ZsQ60sTClUE0phbWmo3rQ1Js8louU= -cloud.google.com/go/recommender v1.11.3/go.mod h1:+FJosKKJSId1MBFeJ/TTyoGQZiEelQQIZMKYYD8ruK4= -cloud.google.com/go/redis v1.14.1/go.mod h1:MbmBxN8bEnQI4doZPC1BzADU4HGocHBk2de3SbgOkqs= -cloud.google.com/go/resourcemanager v1.9.4/go.mod h1:N1dhP9RFvo3lUfwtfLWVxfUWq8+KUQ+XLlHLH3BoFJ0= -cloud.google.com/go/resourcesettings v1.6.4/go.mod h1:pYTTkWdv2lmQcjsthbZLNBP4QW140cs7wqA3DuqErVI= -cloud.google.com/go/retail v1.14.4/go.mod h1:l/N7cMtY78yRnJqp5JW8emy7MB1nz8E4t2yfOmklYfg= -cloud.google.com/go/run v1.3.3/go.mod h1:WSM5pGyJ7cfYyYbONVQBN4buz42zFqwG67Q3ch07iK4= -cloud.google.com/go/scheduler v1.10.4/go.mod h1:MTuXcrJC9tqOHhixdbHDFSIuh7xZF2IysiINDuiq6NI= -cloud.google.com/go/secretmanager v1.11.4/go.mod h1:wreJlbS9Zdq21lMzWmJ0XhWW2ZxgPeahsqeV/vZoJ3w= -cloud.google.com/go/security v1.15.4/go.mod h1:oN7C2uIZKhxCLiAAijKUCuHLZbIt/ghYEo8MqwD/Ty4= -cloud.google.com/go/securitycenter v1.24.2/go.mod h1:l1XejOngggzqwr4Fa2Cn+iWZGf+aBLTXtB/vXjy5vXM= -cloud.google.com/go/servicedirectory v1.11.3/go.mod h1:LV+cHkomRLr67YoQy3Xq2tUXBGOs5z5bPofdq7qtiAw= -cloud.google.com/go/shell v1.7.4/go.mod h1:yLeXB8eKLxw0dpEmXQ/FjriYrBijNsONpwnWsdPqlKM= -cloud.google.com/go/spanner v1.51.0/go.mod h1:c5KNo5LQ1X5tJwma9rSQZsXNBDNvj4/n8BVc3LNahq0= -cloud.google.com/go/speech v1.20.1/go.mod h1:wwolycgONvfz2EDU8rKuHRW3+wc9ILPsAWoikBEWavY= cloud.google.com/go/storage v1.35.1 h1:B59ahL//eDfx2IIKFBeT5Atm9wnNmj3+8xG/W4WB//w= cloud.google.com/go/storage v1.35.1/go.mod h1:M6M/3V/D3KpzMTJyPOR/HU6n2Si5QdaXYEsng2xgOs8= -cloud.google.com/go/storagetransfer v1.10.3/go.mod h1:Up8LY2p6X68SZ+WToswpQbQHnJpOty/ACcMafuey8gc= -cloud.google.com/go/talent v1.6.5/go.mod h1:Mf5cma696HmE+P2BWJ/ZwYqeJXEeU0UqjHFXVLadEDI= -cloud.google.com/go/texttospeech v1.7.4/go.mod h1:vgv0002WvR4liGuSd5BJbWy4nDn5Ozco0uJymY5+U74= -cloud.google.com/go/tpu v1.6.4/go.mod h1:NAm9q3Rq2wIlGnOhpYICNI7+bpBebMJbh0yyp3aNw1Y= -cloud.google.com/go/trace v1.10.4/go.mod h1:Nso99EDIK8Mj5/zmB+iGr9dosS/bzWCJ8wGmE6TXNWY= -cloud.google.com/go/translate v1.9.3/go.mod h1:Kbq9RggWsbqZ9W5YpM94Q1Xv4dshw/gr/SHfsl5yCZ0= -cloud.google.com/go/video v1.20.3/go.mod h1:TnH/mNZKVHeNtpamsSPygSR0iHtvrR/cW1/GDjN5+GU= -cloud.google.com/go/videointelligence v1.11.4/go.mod h1:kPBMAYsTPFiQxMLmmjpcZUMklJp3nC9+ipJJtprccD8= -cloud.google.com/go/vision/v2 v2.7.5/go.mod h1:GcviprJLFfK9OLf0z8Gm6lQb6ZFUulvpZws+mm6yPLM= -cloud.google.com/go/vmmigration v1.7.4/go.mod h1:yBXCmiLaB99hEl/G9ZooNx2GyzgsjKnw5fWcINRgD70= -cloud.google.com/go/vmwareengine v1.0.3/go.mod h1:QSpdZ1stlbfKtyt6Iu19M6XRxjmXO+vb5a/R6Fvy2y4= -cloud.google.com/go/vpcaccess v1.7.4/go.mod h1:lA0KTvhtEOb/VOdnH/gwPuOzGgM+CWsmGu6bb4IoMKk= -cloud.google.com/go/webrisk v1.9.4/go.mod h1:w7m4Ib4C+OseSr2GL66m0zMBywdrVNTDKsdEsfMl7X0= -cloud.google.com/go/websecurityscanner v1.6.4/go.mod h1:mUiyMQ+dGpPPRkHgknIZeCzSHJ45+fY4F52nZFDHm2o= -cloud.google.com/go/workflows v1.12.3/go.mod h1:fmOUeeqEwPzIU81foMjTRQIdwQHADi/vEr1cx9R1m5g= contrib.go.opencensus.io/exporter/ocagent v0.7.1-0.20200907061046-05415f1de66d h1:LblfooH1lKOpp1hIhukktmSAxFkqMPFk9KR6iZ0MJNI= contrib.go.opencensus.io/exporter/ocagent v0.7.1-0.20200907061046-05415f1de66d/go.mod h1:IshRmMJBhDfFj5Y67nVhMYTTIze91RUeT73ipWKs/GY= contrib.go.opencensus.io/exporter/prometheus v0.4.2 h1:sqfsYl5GIY/L570iT+l93ehxaWJs2/OwXtiWwew3oAg= contrib.go.opencensus.io/exporter/prometheus v0.4.2/go.mod h1:dvEHbiKmgvbr5pjaF9fpw1KeYcjrnC1J8B+JKjsZyRQ= -contrib.go.opencensus.io/exporter/zipkin v0.1.2/go.mod h1:mP5xM3rrgOjpn79MM8fZbj3gsxcuytSqtH0dxSWW1RE= dario.cat/mergo v1.0.0 h1:AGCNq9Evsj31mOgNPcLyXc+4PNABt905YmuqPYYpBWk= dario.cat/mergo v1.0.0/go.mod h1:uNxQE+84aUszobStD9th8a29P2fMDhsBdgRYvZOxGmk= -github.com/Azure/azure-sdk-for-go v67.0.0+incompatible/go.mod h1:9XXNKU+eRnpl9moKnB4QOLf1HestfXbmab5FXxiDBjc= github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1 h1:UQHMgLO+TxOElx5B5HZ4hJQsoJ/PvUvKRhJHDQXO8P8= github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E= -github.com/Azure/go-autorest v14.2.0+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24= -github.com/Azure/go-autorest/autorest v0.11.28/go.mod h1:MrkzG3Y3AH668QyF9KRk5neJnGgmhQ6krbhR8Q5eMvA= -github.com/Azure/go-autorest/autorest/adal v0.9.21/go.mod h1:zua7mBUaCc5YnSLKYgGJR/w5ePdMDA6H56upLsHzA9U= -github.com/Azure/go-autorest/autorest/azure/auth v0.5.11/go.mod h1:84w/uV8E37feW2NCJ08uT9VBfjfUHpgLVnG2InYD6cg= -github.com/Azure/go-autorest/autorest/azure/cli v0.4.6/go.mod h1:piCfgPho7BiIDdEQ1+g4VmKyD5y+p/XtSNqE6Hc4QD0= -github.com/Azure/go-autorest/autorest/date v0.3.0/go.mod h1:BI0uouVdmngYNUzGWeSYnokU+TrmwEsOqdt8Y6sso74= -github.com/Azure/go-autorest/logger v0.2.1/go.mod h1:T9E3cAhj2VqvPOtCYAvby9aBXkZmbF5NWuPV8+WeEW8= -github.com/Azure/go-autorest/tracing v0.6.0/go.mod h1:+vhtPC754Xsa23ID7GlGsrdKBpUA79WCAKPPZVC2DeU= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= github.com/Microsoft/go-winio v0.6.1 h1:9/kr64B9VUZrLm5YYwbGtUJnMgqWVOdUAXu6Migciow= github.com/Microsoft/go-winio v0.6.1/go.mod h1:LRdKpFKfdobln8UmuiYcKPot9D2v6svN5+sAH+4kjUM= github.com/Microsoft/hcsshim v0.11.4 h1:68vKo2VN8DE9AdN4tnkWnmdhqdbpUFM8OF3Airm7fz8= github.com/Microsoft/hcsshim v0.11.4/go.mod h1:smjE4dvqPX9Zldna+t5FG3rnoHhaB7QYxPRqGcpAD9w= -github.com/NYTimes/gziphandler v1.1.1/go.mod h1:n/CVRwUEOgIxrgPvAQhUUr9oeUtvrhMomdKFjzJNB0c= -github.com/OneOfOne/xxhash v1.2.8/go.mod h1:eZbhyaAYD41SGSSsnmcpxVoRiQ/MPUTjUdIIOT9Um7Q= -github.com/PuerkitoBio/purell v1.1.1/go.mod h1:c11w/QuzBsJSee3cPx9rAFu61PvFxuPbtSwDGJws/X0= -github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578/go.mod h1:uGdkoq3SwY9Y+13GIhn11/XLaGBb4BfwItxLd5jeuXE= -github.com/XiaoMi/pegasus-go-client v0.0.0-20210427083443-f3b6b08bc4c2/go.mod h1:jNIx5ykW1MroBuaTja9+VpglmaJOUzezumfhLlER3oY= -github.com/agnivade/levenshtein v1.1.1/go.mod h1:veldBMzWxcCG2ZvUTKD2kJNRdCk5hVbJomOvKkmgYbo= -github.com/ahmetb/gen-crd-api-reference-docs v0.3.1-0.20210609063737-0067dc6dcea2/go.mod h1:TdjdkYhlOifCQWPs1UdTma97kQQMozf5h26hTuG70u8= -github.com/alecthomas/kingpin/v2 v2.3.2/go.mod h1:0gyi0zQnjuFk8xrkNKamJoyUo382HRL7ATRpFZCw6tE= -github.com/alecthomas/units v0.0.0-20211218093645-b94a6e3cc137/go.mod h1:OMCwj8VM1Kc9e19TLln2VL61YJF0x1XFtfdL4JdbSyE= -github.com/antlr/antlr4/runtime/Go/antlr/v4 v4.0.0-20230305170008-8188dc5388df/go.mod h1:pSwJ0fSY5KhvocuWSx4fz3BA8OrA1bQn+K1Eli3BRwM= -github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5/go.mod h1:wHh0iHkYZB8zMSxRWpUBQtwG5a7fFgvEO+odwuTv2gs= -github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a/go.mod h1:lB+ZfQJz7igIIfQNfa7Ml4HSf2uFQQRzpGGRXenZAgY= -github.com/authzed/authzed-go v0.7.0/go.mod h1:bmjzzIQ34M0+z8NO9SLjf4oA0A9Ka9gUWVzeSbD0E7c= -github.com/authzed/grpcutil v0.0.0-20230109193425-40ce0530e048/go.mod h1:rqjY3zyK/YP7NID9+B2BdIRRkvnK+cdf9/qya/zaFZE= github.com/aws/aws-sdk-go v1.48.0 h1:1SeJ8agckRDQvnSCt1dGZYAwUaoD2Ixj6IaXB4LCv8Q= github.com/aws/aws-sdk-go v1.48.0/go.mod h1:LF8svs817+Nz+DmiMQKTO3ubZ/6IaTpq3TjupRn3Eqk= -github.com/aws/aws-sdk-go-v2 v1.16.16/go.mod h1:SwiyXi/1zTUZ6KIAmLK5V5ll8SiURNUYOqTerZPaF9k= -github.com/aws/aws-sdk-go-v2/config v1.17.8/go.mod h1:UkCI3kb0sCdvtjiXYiU4Zx5h07BOpgBTtkPu/49r+kA= -github.com/aws/aws-sdk-go-v2/credentials v1.12.21/go.mod h1:O+4XyAt4e+oBAoIwNUYkRg3CVMscaIJdmZBOcPgJ8D8= -github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.12.17/go.mod h1:yIkQcCDYNsZfXpd5UX2Cy+sWA1jPgIhGTw9cOBzfVnQ= -github.com/aws/aws-sdk-go-v2/internal/configsources v1.1.23/go.mod h1:2DFxAQ9pfIRy0imBCJv+vZ2X6RKxves6fbnEuSry6b4= -github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.4.17/go.mod h1:pRwaTYCJemADaqCbUAxltMoHKata7hmB5PjEXeu0kfg= -github.com/aws/aws-sdk-go-v2/internal/ini v1.3.24/go.mod h1:jULHjqqjDlbyTa7pfM7WICATnOv+iOhjletM3N0Xbu8= -github.com/aws/aws-sdk-go-v2/service/ecr v1.17.18/go.mod h1:DQtDYmexqR+z+B6HBCvY7zK/tuXKv6Zy/IwOXOK3eow= -github.com/aws/aws-sdk-go-v2/service/ecrpublic v1.13.17/go.mod h1:r1Vuka0kyzqN0sZm4lYTXf0Vhl+o/mTLq6vKpBBZYaQ= -github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.9.17/go.mod h1:4nYOrY41Lrbk2170/BGkcJKBhws9Pfn8MG3aGqjjeFI= -github.com/aws/aws-sdk-go-v2/service/sso v1.11.23/go.mod h1:/w0eg9IhFGjGyyncHIQrXtU8wvNsTJOP0R6PPj0wf80= -github.com/aws/aws-sdk-go-v2/service/ssooidc v1.13.6/go.mod h1:csZuQY65DAdFBt1oIjO5hhBR49kQqop4+lcuCjf2arA= -github.com/aws/aws-sdk-go-v2/service/sts v1.16.19/go.mod h1:h4J3oPZQbxLhzGnk+j9dfYHi5qIOVJ5kczZd658/ydM= -github.com/aws/smithy-go v1.13.3/go.mod h1:Tg+OJXh4MB2R/uN61Ko2f6hTZwB/ZYGOtib8J3gBHzA= -github.com/awslabs/amazon-ecr-credential-helper/ecr-login v0.0.0-20221004211355-a250ad2ca1e3/go.mod h1:m06KtrZgOloUaePAQMv+Ha8kRmTnKdozTHZrweepIrw= 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/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/bradfitz/gomemcache v0.0.0-20190913173617-a41fca850d0b/go.mod h1:H0wQNHz2YrLsuXOZozoeDmnHXkNCRmMW0gwFWDfEZDA= -github.com/c2h5oh/datasize v0.0.0-20220606134207-859f65c6625b/go.mod h1:S/7n9copUssQ56c7aAgHqftWO4LTf4xY6CGWt8Bc+3M= github.com/cenkalti/backoff/v4 v4.2.1 h1:y4OZtCnogmCPw98Zjyt5a6+QwPLGkiQsYW5oUqylYbM= github.com/cenkalti/backoff/v4 v4.2.1/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= -github.com/certifi/gocertifi v0.0.0-20210507211836-431795d63e8d/go.mod h1:sGbDF6GwGcLpkNXPUTkMRoywsNa/ol15pxFe6ERfguA= -github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghfAqPWnc= github.com/cespare/xxhash/v2 v2.2.0 h1:DC2CZ1Ep5Y4k3ZQ899DldepgrayRUGE6BBZ/cd9Cj44= github.com/cespare/xxhash/v2 v2.2.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= -github.com/chrismellard/docker-credential-acr-env v0.0.0-20221002210726-e883f69e0206/go.mod h1:1UmFRnmMnVsHwD+ZntmLkoVBB1ZLa6V+XXEbF6hZCxU= github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= -github.com/cloudevents/sdk-go/v2 v2.14.0/go.mod h1:xDmKfzNjM8gBvjaF8ijFjM1VYOVUEeUfapHMUX1T5To= github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc= -github.com/cncf/udpa/go v0.0.0-20220112060539-c52dc94e7fbe/go.mod h1:6pvJx4me5XPnfI9Z40ddWsdw2W/uZgQLFXToKeRcDiI= -github.com/cncf/xds/go v0.0.0-20231109132714-523115ebc101/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= github.com/containerd/containerd v1.7.13 h1:wPYKIeGMN8vaggSKuV1X0wZulpMz4CrgEsZdaCyB6Is= github.com/containerd/containerd v1.7.13/go.mod h1:zT3up6yTRfEUa6+GsITYIJNgSVL9NQ4x4h1RPzk0Wu4= github.com/containerd/log v0.1.0 h1:TCJt7ioM2cr/tfR8GPbGf9/VRAX8D2B4PjzCpfX540I= github.com/containerd/log v0.1.0/go.mod h1:VRRf09a7mHDIRezVKTRCrOq78v577GXq3bSa3EhrzVo= -github.com/containerd/stargz-snapshotter/estargz v0.14.3/go.mod h1:KY//uOCIkSuNAHhJogcZtrNHdKrA99/FCCRjE3HD36o= -github.com/coocood/freecache v1.1.1/go.mod h1:OKrEjkGVoxZhyWAJoeFi5BMLUJm2Tit0kpGkIr7NGYY= -github.com/coreos/go-oidc v2.2.1+incompatible/go.mod h1:CgnwVTmzoESiwO9qyAFEMiHoZ1nMCKZlZ9V6mm3/LKc= -github.com/coreos/go-semver v0.3.1/go.mod h1:irMmmIw/7yzSRPWryHsK7EYSg09caPQL03VsM8rvUec= -github.com/coreos/go-systemd/v22 v22.5.0/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc= github.com/cpuguy83/dockercfg v0.3.1 h1:/FpZ+JaygUR/lZP2NlFI2DVfrOEMAIKP5wWEJdoYe9E= github.com/cpuguy83/dockercfg v0.3.1/go.mod h1:sugsbF4//dDlL/i+S+rtpIWp+5h0BHJHfjj5/jFyUJc= -github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc h1:U9qPSI2PIWSS1VwoXQT9A3Wy9MM3WgvqSxFWenqJduM= github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/deepmap/oapi-codegen v1.8.2/go.mod h1:YLgSKSDv/bZQB7N4ws6luhozi3cEdRktEqrX88CvjIw= -github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f/go.mod h1:cuUVRXasLTGF7a8hSLbxyZXjz+1KgoB3wDUb6vlszIc= -github.com/dimchansky/utfbom v1.1.1/go.mod h1:SxdoEBH5qIqFocHMyGOXVAybYJdr71b1Q/j0mACtrfE= -github.com/docker/cli v24.0.0+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8= github.com/docker/distribution v2.8.2+incompatible h1:T3de5rq0dB1j30rp0sA2rER+m322EBzniBPB6ZIzuh8= github.com/docker/distribution v2.8.2+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w= github.com/docker/docker v24.0.7+incompatible h1:Wo6l37AuwP3JaMnZa226lzVXGA3F9Ig1seQen0cKYlM= github.com/docker/docker v24.0.7+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= -github.com/docker/docker-credential-helpers v0.7.0/go.mod h1:rETQfLdHNT3foU5kuNkFR1R1V12OJRRO5lzt2D1b5X0= github.com/docker/go-connections v0.4.0 h1:El9xVISelRB7BuFusrZozjnkIM5YnzCViNKohAFqRJQ= github.com/docker/go-connections v0.4.0/go.mod h1:Gbd7IOopHjR8Iph03tsViu4nIes5XhDvyHbTtUxmeec= github.com/docker/go-units v0.5.0 h1:69rxXcBk27SvSaaxTtLh/8llcHD8vYHT7WSdRZ/jvr4= github.com/docker/go-units v0.5.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk= -github.com/dustin/go-humanize v1.0.1/go.mod h1:Mu1zIs6XwVuF/gI1OepvI0qD18qycQx+mFykh5fBlto= -github.com/eko/gocache v1.2.0/go.mod h1:6u8/2bnr+nOf87mRXWS710rqNNZUECF4CGsPNnsoJ78= github.com/emicklei/go-restful/v3 v3.11.0 h1:rAQeMHw1c7zTmncogyy8VvRZwtkmkZ4FxERmMY4rD+g= github.com/emicklei/go-restful/v3 v3.11.0/go.mod h1:6n3XBCmQQb25CM2LCACGz8ukIrRry+4bhvbpWn3mrbc= github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98= -github.com/envoyproxy/go-control-plane v0.11.1/go.mod h1:uhMcXKCQMEJHiAb0w+YGefQLaTEw+YhGluxZkrTmD0g= github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= -github.com/envoyproxy/protoc-gen-validate v1.0.2/go.mod h1:GpiZQP3dDbg4JouG/NNS7QWXpgx6x8QiMKdmN72jogE= github.com/evanphx/json-patch v5.7.0+incompatible h1:vgGkfT/9f8zE6tvSCe74nfpAVDQ2tG6yudJd8LBksgI= github.com/evanphx/json-patch v5.7.0+incompatible/go.mod h1:50XU6AFN0ol/bzJsmQLiYLvXMP4fmwYFNcr97nuDLSk= github.com/evanphx/json-patch/v5 v5.7.0 h1:nJqP7uwL84RJInrohHfW0Fx3awjbm8qZeFv0nW9SYGc= github.com/evanphx/json-patch/v5 v5.7.0/go.mod h1:VNkHZ/282BpEyt/tObQO8s5CMPmYYq14uClGH4abBuQ= -github.com/fatih/color v1.12.0/go.mod h1:ELkj/draVOlAH/xkhN6mQ50Qd0MPOk5AAr3maGEBuJM= -github.com/felixge/httpsnoop v1.0.3/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ= github.com/fsnotify/fsnotify v1.7.0 h1:8JEhPFa5W2WU7YfeZzPNqzMP6Lwt7L2715Ggo0nosvA= github.com/fsnotify/fsnotify v1.7.0/go.mod h1:40Bi/Hjc2AVfZrqy+aj+yEI+/bRxZnMJyTJwOpGvigM= -github.com/getkin/kin-openapi v0.120.0/go.mod h1:PCWw/lfBrJY4HcdqE3jj+QFkaFK8ABoqo7PvqVhXXqw= github.com/ghodss/yaml v1.0.0 h1:wQHKEahhL6wmXdzwWG11gIVCkOv05bNOh+Rxn0yngAk= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= -github.com/go-chi/chi/v5 v5.0.11/go.mod h1:DslCQbL2OYiznFReuXYUmQ2hGd1aDpCnlMNITLSKoi8= -github.com/go-chi/cors v1.2.1/go.mod h1:sSbTewc+6wYHBBCW7ytsFSn836hqM7JxpglAy2Vzc58= github.com/go-kit/log v0.2.1 h1:MRVx0/zhvdseW+Gza6N9rVzU/IVzaeE1SFI4raAhmBU= github.com/go-kit/log v0.2.1/go.mod h1:NwTd00d/i8cPZ3xOwwiv2PO5MOcx78fFErGNcVmBjv0= github.com/go-logfmt/logfmt v0.6.0 h1:wGYYu3uicYdqXVgoYbvnkrPVXkuLM1p1ifugDMEdRi4= github.com/go-logfmt/logfmt v0.6.0/go.mod h1:WYhtIu8zTZfxdn5+rREduYbwxfcBr/Vr6KEVveWlfTs= github.com/go-logr/logr v1.3.0 h1:2y3SDp0ZXuc6/cjLSZ+Q3ir+QB9T/iG5yYRXqsagWSY= github.com/go-logr/logr v1.3.0/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY= -github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE= github.com/go-logr/zapr v1.3.0 h1:XGdV8XW8zdwFiwOA2Dryh1gj2KRQyOOoNmBy4EplIcQ= github.com/go-logr/zapr v1.3.0/go.mod h1:YKepepNBd1u/oyhd/yQmtjVXmm9uML4IXUgMOwR8/Gg= github.com/go-ole/go-ole v1.2.6 h1:/Fpf6oFPoeFik9ty7siob0G6Ke8QvQEuVcuChpwXzpY= @@ -280,18 +98,11 @@ github.com/go-openapi/jsonreference v0.20.2/go.mod h1:Bl1zwGIM8/wsvqjsOQLJ/SH+En github.com/go-openapi/swag v0.22.3/go.mod h1:UzaqsxGiab7freDnrUUra0MwWfN/q7tE4j+VcZ0yl14= github.com/go-openapi/swag v0.22.4 h1:QLMzNJnMGPRNDCbySlcj1x01tzU8/9LTTL9hZZZogBU= github.com/go-openapi/swag v0.22.4/go.mod h1:UzaqsxGiab7freDnrUUra0MwWfN/q7tE4j+VcZ0yl14= -github.com/go-redis/redis/v8 v8.11.5/go.mod h1:gREzHqY1hg6oD9ngVRbLStwAWKhA0FEgq8Jd4h5lpwo= github.com/go-task/slim-sprig v0.0.0-20210107165309-348f09dbbbc0/go.mod h1:fyg7847qk6SyHyPtNmDHnmrv/HOrqktSC+C9fM+CJOE= github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572 h1:tfuBGBXKqDEevZMzYi5KSi8KkcZtzBcTgAUUtapy0OI= github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572/go.mod h1:9Pwr4B2jHnOSGXyyzV8ROjYa2ojvAY6HCGYYfMoC3Ls= -github.com/gobuffalo/flect v1.0.2/go.mod h1:A5msMlrHtLqh9umBSnvabjsMrCcCpAyzglnDvkbYKHs= -github.com/gobwas/glob v0.2.3/go.mod h1:d3Ez4x06l9bZtSvzIay5+Yzi0fmZzPgnTbPcKjJAkT8= -github.com/gofrs/uuid/v5 v5.0.0/go.mod h1:CDOjlDMVAtN56jqyRUZh58JT31Tiw7/oQyEXZV+9bD8= -github.com/gogo/googleapis v1.4.0/go.mod h1:5YRNX2z1oM5gXdAkurHa942MDgEJyk02w4OecKY87+c= github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= -github.com/golang-jwt/jwt v3.2.2+incompatible/go.mod h1:8pz2t5EyA70fFQQSrl6XZXzqecmYZeUEB8OUGHkxJ+I= -github.com/golang-jwt/jwt/v4 v4.5.0/go.mod h1:m21LjoU+eqJr34lmDMbreY2eSTRJ1cv77w39/MY0Ch0= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= github.com/golang/glog v1.2.0 h1:uCdmnmatrKCgMBlM4rMuJZWOkPDqdbZPnrMXDY4gI68= github.com/golang/glog v1.2.0/go.mod h1:6AhwSGph0fcJtXVM/PEHPqZlFeoLxhs7/t5UDAwmO+w= @@ -301,7 +112,6 @@ github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da/go.mod h1:cIg4er github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= github.com/golang/mock v1.2.0/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= github.com/golang/mock v1.3.1/go.mod h1:sBzyDLLjw3U8JLTeZvSv8jJB+tU5PVekmnlKIyFUx0Y= -github.com/golang/mock v1.6.0/go.mod h1:p6yTPP+5HYm5mzsMV8JkE6ZKdX+/wYM6Hr+LicevLPs= github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= @@ -312,12 +122,8 @@ github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaS github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= github.com/golang/protobuf v1.5.3 h1:KhyjKVUg7Usr/dYsdSqoFveMYd5ko72D+zANwlG1mmg= github.com/golang/protobuf v1.5.3/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= -github.com/golang/snappy v0.0.4/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= 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/btree v1.0.1/go.mod h1:xXMiIv4Fb/0kKde4SpL7qlzvu5cMJDRkFDxJfI9uaxA= -github.com/google/cel-go v0.16.1/go.mod h1:HXZKzB0LXqer5lHHgfWAnlYwJaQBDKMjxjulNQzhwhY= -github.com/google/gnostic v0.6.9/go.mod h1:Nm8234We1lq6iB9OmlgNv3nH91XLLVZHCDayfA3xq+E= github.com/google/gnostic-models v0.6.8 h1:yo/ABAfM5IMRsS1VnXjTBvUb61tFIHozhlYvRgGre9I= github.com/google/gnostic-models v0.6.8/go.mod h1:5n7qKqH0f5wFt+aWF8CW6pZLLNOfYuF5OpfBSENuI8U= github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M= @@ -331,15 +137,9 @@ github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/go-containerregistry v0.16.1 h1:rUEt426sR6nyrL3gt+18ibRcvYpKYdpsa5ZW7MA08dQ= github.com/google/go-containerregistry v0.16.1/go.mod h1:u0qB2l7mvtWVR5kNcbFIhFY1hLbf8eeGapA+vbFDCtQ= -github.com/google/go-containerregistry/pkg/authn/k8schain v0.0.0-20230209165335-3624968304fd/go.mod h1:x5fIlj5elU+/eYF60q4eASMQ9kDc+GMFa7UU9M3mFFw= -github.com/google/go-containerregistry/pkg/authn/kubernetes v0.0.0-20230209165335-3624968304fd/go.mod h1:6pjZpt+0dg+Z0kUEn53qLtD57raiZo/bqWzsuX6dDjo= -github.com/google/go-github/v27 v27.0.6/go.mod h1:/0Gr8pJ55COkmv+S/yPKCczSkUPIM/LnFyubufRNIS0= -github.com/google/go-pkcs11 v0.2.1-0.20230907215043-c6f79328ddf9/go.mod h1:6eQoGcuNJpa7jnd5pMGdkSaQpNDYvPlXWMcjXXThLlY= -github.com/google/go-querystring v1.0.0/go.mod h1:odCYkC5MyYFN7vkCjXpyrEuKhc/BUO6wN/zVPAxq5ck= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/gofuzz v1.2.0 h1:xRy4A+RhZaiKjJ1bPfwQ8sedCA+YS2YcCHW6ec7JMi0= github.com/google/gofuzz v1.2.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= -github.com/google/mako v0.0.0-20190821191249-122f8dcef9e3/go.mod h1:YzLcVlL+NqWnmUEPuhS1LxDDwGO9WNbVlEXaF4IH35g= github.com/google/martian v2.1.0+incompatible h1:/CP5g8u/VJHijgedC/Legn3BAbAaWPgecwXBIDzw5no= github.com/google/martian v2.1.0+incompatible/go.mod h1:9I4somxYTbIHy5NJKHRl3wXiIaQGbYVAs8BPL6v8lEs= github.com/google/martian/v3 v3.3.2 h1:IqNFLAmvJOgVlpdEBiQbDc2EwKW77amAycfTuWKdfvw= @@ -359,15 +159,9 @@ github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+ github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= github.com/googleapis/gax-go/v2 v2.12.0 h1:A+gCJKdRfqXkr+BIRGtZLibNXf0m1f9E4HG56etFpas= github.com/googleapis/gax-go/v2 v2.12.0/go.mod h1:y+aIqrI5eb1YGMVJfuV3185Ts/D7qKpsEkdD5+I6QGU= -github.com/googleapis/gnostic v0.5.5/go.mod h1:7+EbHbldMins07ALC74bsA81Ovc97DwqyJO1AENw9kA= github.com/googleapis/google-cloud-go-testing v0.0.0-20210719221736-1c9a4c676720 h1:zC34cGQu69FG7qzJ3WiKW244WfhDC3xxYMeNOX2gtUQ= github.com/googleapis/google-cloud-go-testing v0.0.0-20210719221736-1c9a4c676720/go.mod h1:dvDLG8qkwmyD9a/MJJN3XJcT3xFxOKAvTZGvuZmac9g= -github.com/gorilla/websocket v1.5.1/go.mod h1:x3kM2JMyaluk02fnUJpQuwD2dCS5NDG2ZHL0uE0tcaY= -github.com/gregjones/httpcache v0.0.0-20180305231024-9cad4c3443a7/go.mod h1:FecbI9+v66THATjSRHfNgh1IVFe/9kFxbXtjV0ctIMA= -github.com/grpc-ecosystem/go-grpc-middleware v1.3.0/go.mod h1:z0ButlSOZa5vEBq9m2m2hlwIgKw+rp3sdCBRoJY+30Y= -github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway v1.16.0 h1:gmcG1KaJ57LophUzW0Hy8NmPhnMZb4M0+kPpLofRdBo= -github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw= github.com/grpc-ecosystem/grpc-gateway/v2 v2.18.1 h1:6UKoz5ujsI55KNpsJH3UwCq3T8kKbZwNZBNPuTTje8U= github.com/grpc-ecosystem/grpc-gateway/v2 v2.18.1/go.mod h1:YvJ2f6MplWDhfxiUC3KpyTy76kYUZA4W3pTv/wdKQ9Y= github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4= @@ -377,31 +171,18 @@ github.com/hashicorp/go-multierror v1.1.1 h1:H5DkEtf6CXdFp0N0Em5UCwQpXMWke8IA0+l github.com/hashicorp/go-multierror v1.1.1/go.mod h1:iw975J/qwKPdAO1clOe2L8331t/9/fmwbPZ6JB6eMoM= github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= -github.com/hashicorp/golang-lru v1.0.2/go.mod h1:iADmTwqILo4mZ8BN3D2Q6+9jd8WM5uGBxy+E8yxSoD4= -github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ= github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= github.com/imdario/mergo v0.3.16 h1:wwQJbIsHYGMUyLSPrEq1CT16AhnhNJQ51+4fdHUnCl4= github.com/imdario/mergo v0.3.16/go.mod h1:WBLT9ZmE3lPoWsEzCh9LPo3TiwVN+ZKEjmz+hD27ysY= -github.com/inconshreveable/mousetrap v1.1.0/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= -github.com/influxdata/influxdb-client-go/v2 v2.9.0/go.mod h1:x7Jo5UHHl+w8wu8UnGiNobDDHygojXwJX4mx7rXGKMk= -github.com/influxdata/line-protocol v0.0.0-20200327222509-2487e7298839/go.mod h1:xaLFMmpvUxqXtVkUJfg9QmT88cDaCJ3ZKgdZ78oO8Qo= -github.com/influxdata/tdigest v0.0.1/go.mod h1:Z0kXnxzbTC2qrx4NaIzYkE1k66+6oEDQTvL95hQFh5Y= -github.com/invopop/yaml v0.2.0/go.mod h1:2XuRLgs/ouIrW3XNzuNj7J3Nvu/Dig5MXvbCEdiBN3Q= -github.com/jessevdk/go-flags v1.4.0/go.mod h1:4FA24M0QyGHXBuZZK/XkWh8h0e1EYbRYJSGM75WSRxI= github.com/jmespath/go-jmespath v0.4.0 h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9YPoQUg= github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo= github.com/jmespath/go-jmespath/internal/testify v1.5.1 h1:shLQSRRSCCPj3f2gpwzGwWFoC7ycTf1rcQZHOlsJ6N8= github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfCI6z80xFu9LTZmf1ZRjMHUOPmWr69U= -github.com/jonboulle/clockwork v0.2.2/go.mod h1:Pkfl5aHPm1nk2H9h0bjmnJD/BcgbGXUBGnn1kMkgxc8= github.com/josharian/intern v1.0.0 h1:vlS4z54oSdjm0bgjRigI+G1HpF+tI+9rE5LLzOg8HmY= github.com/josharian/intern v1.0.0/go.mod h1:5DoeVV0s6jJacbCEi61lwdGj/aVlrQvzHFFd8Hwg//Y= -github.com/jpillora/backoff v1.0.0/go.mod h1:J/6gKK9jxlEcS3zixgDgUAsiuZ7yrSoa/FX5e0EB2j4= github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM= github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHmT4TnhNGBo= github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU= -github.com/julienschmidt/httprouter v1.3.0/go.mod h1:JR6WtHb+2LUe8TCKY3cZOxFyyO8IZAc4RVcycCCAKdM= -github.com/jzelinskie/stringz v0.0.0-20210414224931-d6a8ce844a70/go.mod h1:hHYbgxJuNLRw91CmpuFsYEOyQqpDVFg8pvEh23vy4P0= -github.com/kelseyhightower/envconfig v1.4.0/go.mod h1:cccZRl6mQpaq41TPp5QxidR+Sa3axMbJDNb//FQX6Gg= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= github.com/klauspost/compress v1.17.0 h1:Rnbp4K9EjcDuVuHtd0dgA4qNuv9yKDYKK1ulpJwgrqM= @@ -423,17 +204,10 @@ github.com/magiconair/properties v1.8.7 h1:IeQXZAiQcpL9mgcAe1Nu6cX9LLw6ExEHKjN0V github.com/magiconair/properties v1.8.7/go.mod h1:Dhd985XPs7jluiymwWYZ0G4Z61jb3vdS329zhj2hYo0= github.com/mailru/easyjson v0.7.7 h1:UGYAvKxe3sBsEDzO8ZeWOSlIQfWFlxbzLZe7hwFURr0= github.com/mailru/easyjson v0.7.7/go.mod h1:xzfreul335JAWq5oZzymOObrkdz5UnU4kGfJJLY9Nlc= -github.com/maistra/xns-informer v0.0.0-20230111124621-73ee35e5f523/go.mod h1:2DP6ps5pmbxaazskTazVHwwLF+RiW+EtcJqQxLBaWH8= -github.com/mattn/go-colorable v0.1.8/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= -github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU= -github.com/matttproud/golang_protobuf_extensions v1.0.4/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4= github.com/matttproud/golang_protobuf_extensions/v2 v2.0.0 h1:jWpvCLoY8Z/e3VKvlsiIGKtc+UG6U5vzxaoagmhXfyg= github.com/matttproud/golang_protobuf_extensions/v2 v2.0.0/go.mod h1:QUyp042oQthUoa9bqDv0ER0wrtXnBruoNd7aNjkbP+k= -github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= -github.com/mitchellh/mapstructure v1.5.0/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/moby/patternmatcher v0.6.0 h1:GmP9lR19aU5GqSSFko+5pRqHi+Ohk1O69aFiKkVGiPk= github.com/moby/patternmatcher v0.6.0/go.mod h1:hDPoyOpDY7OrrMDLaYoY3hf52gNCR/YOUYxkhApJIxc= -github.com/moby/spdystream v0.2.0/go.mod h1:f7i0iNDQJ059oMTcWxx8MA/zKFIuD/lY+0GqbN2Wy8c= github.com/moby/sys/sequential v0.5.0 h1:OPvI35Lzn9K04PBbCLW0g4LcFAJgHsvXsRyewg5lXtc= github.com/moby/sys/sequential v0.5.0/go.mod h1:tH2cOOs5V9MlPiXcQzRC+eEyab644PWKGRYaaV5ZZlo= github.com/moby/term v0.5.0 h1:xt8Q1nalod/v7BqbG21f8mQPqH+xAaC9C3N3wfWbVP0= @@ -443,13 +217,10 @@ github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M= github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= -github.com/mohae/deepcopy v0.0.0-20170929034955-c48cc78d4826/go.mod h1:TaXosZuwdSHYgviHp1DAtfrULt5eUgsSMsZf+YrPgl8= github.com/morikuni/aec v1.0.0 h1:nP9CBfwrvYnBRgY6qfDQkygYDmYwOilePFkwzv4dU8A= github.com/morikuni/aec v1.0.0/go.mod h1:BbKIizmSmc5MMPqRYbxO4ZU0S0+P200+tUnFx7PXmsc= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 h1:C3w9PqII01/Oq1c1nUAm88MOHcQC9l5mIlSMApZMrHA= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ= -github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= -github.com/mxk/go-flowrate v0.0.0-20140419014527-cca7078d478f/go.mod h1:ZdcZmHo+o7JKHSa8/e818NopupXU1YMK5fe1lsApnBw= github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= github.com/nxadm/tail v1.4.8 h1:nPr65rt6Y5JFSKQO7qToXr7pePgD6Gwiw05lkbyAQTE= github.com/nxadm/tail v1.4.8/go.mod h1:+ncqLTQzXmGhMZNUePPaPqPvBxHAIsmXswZKocGu+AU= @@ -463,7 +234,6 @@ github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7J github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo= github.com/onsi/gomega v1.30.0 h1:hvMK7xYz4D3HapigLTeGdId/NcfQx1VHMJc60ew99+8= github.com/onsi/gomega v1.30.0/go.mod h1:9sxs+SwGrKI0+PWe4Fxa9tFQQBG5xSsSbMXOI8PPpoQ= -github.com/open-policy-agent/opa v0.52.0/go.mod h1:2n99s7WY/BXZUWUOq10JdTgK+G6XM4FYGoe7kQ5Vg0s= github.com/opencontainers/go-digest v1.0.0 h1:apOUWs51W5PlhuyGyz9FCeeBIOUDA/6nW8Oi/yOhh5U= github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM= github.com/opencontainers/image-spec v1.1.0-rc5 h1:Ygwkfw9bpDvs+c9E34SdgGOj41dX/cbdlwvlWt0pnFI= @@ -474,11 +244,6 @@ github.com/opendatahub-io/model-registry v0.1.1 h1:q5KJIRhOAwUarodz/SP1NDx25rUNc github.com/opendatahub-io/model-registry v0.1.1/go.mod h1:LlAAyLOh4Fn3AESXKXpgfERzQlBeTSyYex1vrDIgog0= github.com/openshift/api v3.9.0+incompatible h1:fJ/KsefYuZAjmrr3+5U9yZIZbTOpVkDDLDLFresAeYs= github.com/openshift/api v3.9.0+incompatible/go.mod h1:dh9o4Fs58gpFXGSYfnVxGR9PnV53I8TW84pQaJDdGiY= -github.com/openzipkin/zipkin-go v0.4.2/go.mod h1:ZeVkFjuuBiSy13y8vpSDCjMi9GoI3hPpCJSBx/EYFhY= -github.com/pegasus-kv/thrift v0.13.0/go.mod h1:Gl9NT/WHG6ABm6NsrbfE8LiJN0sAyneCrvB4qN4NPqQ= -github.com/pelletier/go-toml/v2 v2.1.0/go.mod h1:tJU2Z3ZkXwnxa4DPO899bsyIoywizdUvyaeZurnPPDc= -github.com/perimeterx/marshmallow v1.1.5/go.mod h1:dsXbUu8CRzfYP5a87xpp0xq9S3u0Vchtcl8we9tYaXw= -github.com/peterbourgon/diskv v2.0.1+incompatible/go.mod h1:uqqh8zWWbv1HBMNONnaR/tNboyR3/BZd58JJSHlUSCU= github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= @@ -487,7 +252,6 @@ github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 h1:Jamvg5psRI github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/power-devops/perfstat v0.0.0-20210106213030-5aafc221ea8c h1:ncq/mPwQF4JjgDlrVEn3C11VoGHZN7m8qihwgMEtzYw= github.com/power-devops/perfstat v0.0.0-20210106213030-5aafc221ea8c/go.mod h1:OmDBASR4679mdNQnz2pUhc2G8CO2JrUAVFDRBDP/hJE= -github.com/pquerna/cachecontrol v0.0.0-20201205024021-ac21108117ac/go.mod h1:hoLfEwdY11HjRfKFH6KqnPsfxlo3BP6bJehpDv8t6sQ= github.com/prometheus-operator/prometheus-operator/pkg/apis/monitoring v0.64.1 h1:bvntWler8vOjDJtxBwGDakGNC6srSZmgawGM9Jf7HC8= github.com/prometheus-operator/prometheus-operator/pkg/apis/monitoring v0.64.1/go.mod h1:cfNgxpCPGyIydmt3HcwDqKDt0nYdlGRhzftl+DZH7WA= github.com/prometheus/client_golang v1.17.0 h1:rl2sfwZMtSthVU752MqfjQozy7blglC+1SOtjMAMh+Q= @@ -501,29 +265,16 @@ github.com/prometheus/procfs v0.12.0 h1:jluTpSng7V9hY0O2R9DzzJHYb2xULk9VTR1V1R/k github.com/prometheus/procfs v0.12.0/go.mod h1:pcuDEFsWDnvcgNzo4EEweacyhjeA9Zk3cnaOZAZEfOo= github.com/prometheus/statsd_exporter v0.25.0 h1:gpVF1TMf1UqMJmBDpzBYrEaGOFMpbMBYYYUDwM38Y/I= github.com/prometheus/statsd_exporter v0.25.0/go.mod h1:HwzfSvg6ehmb0Qg71ZuFrlgj5XQt9C+MGVLz5Gt5lqc= -github.com/rcrowley/go-metrics v0.0.0-20200313005456-10cdbea86bc0/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4= github.com/rogpeppe/go-internal v1.10.0 h1:TMyTOH3F/DB16zRVcYyreMH6GnZZrwQVAoYjRBZyWFQ= github.com/rogpeppe/go-internal v1.10.0/go.mod h1:UQnix2H7Ngw/k4C5ijL5+65zddjncjaFoBhdsK/akog= -github.com/rs/dnscache v0.0.0-20211102005908-e0241e321417/go.mod h1:qe5TWALJ8/a1Lqznoc5BDHpYX/8HU60Hm2AwRmqzxqA= -github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= -github.com/sagikazarmark/locafero v0.4.0/go.mod h1:Pe1W6UlPYUk/+wc/6KFhbORCfqzgYEpgQ3O5fPuL3H4= -github.com/sagikazarmark/slog-shim v0.1.0/go.mod h1:SrcSrq8aKtyuqEI1uvTDTK1arOWRIczQRv+GVI1AkeQ= github.com/shirou/gopsutil/v3 v3.23.9 h1:ZI5bWVeu2ep4/DIxB4U9okeYJ7zp/QLTO4auRb/ty/E= github.com/shirou/gopsutil/v3 v3.23.9/go.mod h1:x/NWSb71eMcjFIO0vhyGW5nZ7oSIgVjrCnADckb85GA= github.com/shoenig/go-m1cpu v0.1.6 h1:nxdKQNcEB6vzgA2E2bvzKIYRuNj7XNJ4S/aRSwKzFtM= github.com/shoenig/go-m1cpu v0.1.6/go.mod h1:1JJMcUBvfNwpq05QDQVAnx3gUHr9IYF7GNg9SUEw2VQ= github.com/sirupsen/logrus v1.9.3 h1:dueUQJ1C2q9oE3F7wvmSGAaVtTmUizReu6fjN8uqzbQ= github.com/sirupsen/logrus v1.9.3/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= -github.com/soheilhy/cmux v0.1.5/go.mod h1:T7TcVDs9LWfQgPlPsdngu6I6QIoyIFZDDC6sNE1GqG0= -github.com/sourcegraph/conc v0.3.0/go.mod h1:Sdozi7LEKbFPqYX2/J+iBAM6HpqSLTASQIKqDmF7Mt0= -github.com/spaolacci/murmur3 v1.1.0/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= -github.com/spf13/afero v1.11.0/go.mod h1:GH9Y3pIexgf1MTIWtNGyogA5MwRIDXGUr+hbWNoBjkY= -github.com/spf13/cast v1.6.0/go.mod h1:ancEpBxwJDODSW/UG4rDrAqiKolqNNh2DX3mk86cAdo= -github.com/spf13/cobra v1.8.0/go.mod h1:WXLWApfZ71AjXPya3WOlMsY9yMs7YeiHhFVlvLyhcho= github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= -github.com/spf13/viper v1.18.2/go.mod h1:EKmWIqdnk5lOcmR72yw6hS+8OPYcwD0jteitLMVB+yk= -github.com/stoewer/go-strcase v1.2.0/go.mod h1:IBiWB2sKIp3wVVQ3Y035++gc+knqhUQag1KpM8ahLw8= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw= github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo= @@ -534,8 +285,6 @@ github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk= github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= -github.com/subosito/gotenv v1.6.0/go.mod h1:Dk4QP5c2W3ibzajGcXpNraDfq2IrhjMIvMSWPKKo0FU= -github.com/tchap/go-patricia/v2 v2.3.1/go.mod h1:VZRHKAb53DLaG+nA9EaYYiaEx6YztwDlLElMsnSHD4k= github.com/testcontainers/testcontainers-go v0.26.0 h1:uqcYdoOHBy1ca7gKODfBd9uTHVK3a7UL848z09MVZ0c= github.com/testcontainers/testcontainers-go v0.26.0/go.mod h1:ICriE9bLX5CLxL9OFQ2N+2N+f+803LNJ1utJb1+Inx0= github.com/tidwall/gjson v1.17.0 h1:/Jocvlh98kcTfpN2+JzGQWQcqrPQwDrVEMApx/M5ZwM= @@ -549,46 +298,16 @@ github.com/tklauser/go-sysconf v0.3.12 h1:0QaGUFOdQaIVdPgfITYzaTegZvdCjmYO52cSFA github.com/tklauser/go-sysconf v0.3.12/go.mod h1:Ho14jnntGE1fpdOqQEEaiKRpvIavV0hSfmBq8nJbHYI= github.com/tklauser/numcpus v0.6.1 h1:ng9scYS7az0Bk4OZLvrNXNSAO2Pxr1XXRAPyjhIx+Fk= github.com/tklauser/numcpus v0.6.1/go.mod h1:1XfjsgE2zo8GVw7POkMbHENHzVg3GzmoZ9fESEdAacY= -github.com/tmc/grpc-websocket-proxy v0.0.0-20220101234140-673ab2c3ae75/go.mod h1:KO6IkyS8Y3j8OdNO85qEYBsRPuteD+YciPomcXdrMnk= -github.com/tsenart/go-tsz v0.0.0-20180814235614-0bd30b3df1c3/go.mod h1:SWZznP1z5Ki7hDT2ioqiFKEse8K9tU2OUvaRI0NeGQo= -github.com/tsenart/vegeta/v12 v12.11.1/go.mod h1:swiFmrgpqj2llHURgHYFRFN0tfrIrlnspg01HjwOnSQ= -github.com/vbatts/tar-split v0.11.3/go.mod h1:9QlHN18E+fEH7RdG+QAJJcuya3rqT7eXSTY7wGrAokY= -github.com/xeipuuv/gojsonpointer v0.0.0-20190905194746-02993c407bfb/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU= -github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415/go.mod h1:GwrjFmJcFw6At/Gs6z4yjiIwzuJ1/+UwLxMQDVQXShQ= -github.com/xhit/go-str2duration/v2 v2.1.0/go.mod h1:ohY8p+0f07DiV6Em5LKB0s2YpLtXVyJfNt1+BlmyAsU= -github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU= -github.com/yashtewari/glob-intersection v0.1.0/go.mod h1:LK7pIC3piUjovexikBbJ26Yml7g8xa5bsjfx2v1fwok= github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= github.com/yusufpapurcu/wmi v1.2.3 h1:E1ctvB7uKFMOJw3fdOW32DwGE9I7t++CRUEMKvFoFiw= github.com/yusufpapurcu/wmi v1.2.3/go.mod h1:SBZ9tNy3G9/m5Oi98Zks0QjeHVDvuK0qfxQmPyzfmi0= -go.etcd.io/bbolt v1.3.7/go.mod h1:N9Mkw9X8x5fupy0IKsmuqVtoGDyxsaDlbk4Rd05IAQw= -go.etcd.io/etcd/api/v3 v3.5.9/go.mod h1:uyAal843mC8uUVSLWz6eHa/d971iDGnCRpmKd2Z+X8k= -go.etcd.io/etcd/client/pkg/v3 v3.5.9/go.mod h1:y+CzeSmkMpWN2Jyu1npecjB9BBnABxGM4pN8cGuJeL4= -go.etcd.io/etcd/client/v2 v2.305.9/go.mod h1:0NBdNx9wbxtEQLwAQtrDHwx58m02vXpDcgSYI2seohQ= -go.etcd.io/etcd/client/v3 v3.5.9/go.mod h1:i/Eo5LrZ5IKqpbtpPDuaUnDOUv471oDg8cjQaUr2MbA= -go.etcd.io/etcd/pkg/v3 v3.5.9/go.mod h1:BZl0SAShQFk0IpLWR78T/+pyt8AruMHhTNNX73hkNVY= -go.etcd.io/etcd/raft/v3 v3.5.9/go.mod h1:WnFkqzFdZua4LVlVXQEGhmooLeyS7mqzS4Pf4BCVqXg= -go.etcd.io/etcd/server/v3 v3.5.9/go.mod h1:GgI1fQClQCFIzuVjlvdbMxNbnISt90gdfYyqiAIt65g= go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU= go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8= go.opencensus.io v0.24.0 h1:y73uSU6J157QMP2kn2r30vwW1A2W2WFwSCGnAVxeaD0= go.opencensus.io v0.24.0/go.mod h1:vNK8G9p7aAivkbmorf4v+7Hgx+Zs0yY+0fOtgBfjQKo= -go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.40.0/go.mod h1:UMklln0+MRhZC4e3PwmN3pCtq4DyIadWw4yikh6bNrw= -go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.44.0/go.mod h1:SeQhzAEccGVZVEy7aH87Nh0km+utSpo1pTv6eMMop48= -go.opentelemetry.io/otel v1.14.0/go.mod h1:o4buv+dJzx8rohcUeRmWUZhqupFvzWis188WlggnNeU= -go.opentelemetry.io/otel/exporters/otlp/internal/retry v1.14.0/go.mod h1:UFG7EBMRdXyFstOwH028U0sVf+AvukSGhF0g8+dmNG8= -go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.14.0/go.mod h1:HrbCVv40OOLTABmOn1ZWty6CHXkU8DK/Urc43tHug70= -go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.14.0/go.mod h1:5w41DY6S9gZrbjuq6Y+753e96WfPha5IcsOSZTtullM= -go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp v1.14.0/go.mod h1:+N7zNjIJv4K+DeX67XXET0P+eIciESgaFDBqh+ZJFS4= -go.opentelemetry.io/otel/metric v0.37.0/go.mod h1:DmdaHfGt54iV6UKxsV9slj2bBRJcKC1B1uvDLIioc1s= -go.opentelemetry.io/otel/sdk v1.14.0/go.mod h1:bwIC5TjrNG6QDCHNWvW4HLHtUQ4I+VQDsnjhvyZCALM= -go.opentelemetry.io/otel/trace v1.14.0/go.mod h1:8avnQLK+CG77yNLUae4ea2JDQ6iT+gozhnZjy/rw9G8= -go.opentelemetry.io/proto/otlp v0.19.0/go.mod h1:H7XAot3MsfNsj7EXtrA2q5xSNQ10UqI405h3+duxN4U= go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= -go.uber.org/atomic v1.11.0/go.mod h1:LUxbIzbOniOlMKjJjyPfpl4v+PKK2cNJn91OQbhoJI0= -go.uber.org/automaxprocs v1.5.3/go.mod h1:eRbA25aqJrxAbsLO0xy5jVwPt7FQnRgjW+efnwa1WM0= go.uber.org/goleak v1.2.1 h1:NBol2c7O1ZokfZ0LEU9K6Whx/KnwvepVetCUhtKja4A= go.uber.org/goleak v1.2.1/go.mod h1:qlT2yGI9QafXHhZZLxlSuNsMw3FFLxBr+tBRlmO1xH4= go.uber.org/multierr v1.1.0/go.mod h1:wR5kodmAFQ0UK8QlbwjlSNy0Z68gJhDJUG5sjR94q/0= @@ -722,7 +441,6 @@ google.golang.org/genproto v0.0.0-20231106174013-bbf56f31fb17 h1:wpZ8pe2x1Q3f2Ky google.golang.org/genproto v0.0.0-20231106174013-bbf56f31fb17/go.mod h1:J7XzRzVy1+IPwWHZUzoD0IccYZIrXILAQpc+Qy9CMhY= google.golang.org/genproto/googleapis/api v0.0.0-20231106174013-bbf56f31fb17 h1:JpwMPBpFN3uKhdaekDpiNlImDdkUAyiJ6ez/uxGaUSo= google.golang.org/genproto/googleapis/api v0.0.0-20231106174013-bbf56f31fb17/go.mod h1:0xJLfVdJqpAPl8tDg1ujOCGzx6LFLttXT5NhllGOXY4= -google.golang.org/genproto/googleapis/bytestream v0.0.0-20231030173426-d783a09b4405/go.mod h1:GRUCuLdzVqZte8+Dl/D4N25yLzcGqqWaYkeVOwulFqw= google.golang.org/genproto/googleapis/rpc v0.0.0-20231120223509-83a465c0220f h1:ultW7fxlIvee4HYrtnaRPon9HpEgFk5zYpmfMgtKB5I= google.golang.org/genproto/googleapis/rpc v0.0.0-20231120223509-83a465c0220f/go.mod h1:L9KNLi232K1/xB6f7AlSX692koaRnKaWSR0stBki0Yc= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= @@ -742,12 +460,8 @@ gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EV gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys= gopkg.in/inf.v0 v0.9.1 h1:73M5CoZyi3ZLMOyDlQh031Cx6N9NDJ2Vvfl76EDAgDc= gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw= -gopkg.in/ini.v1 v1.67.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= -gopkg.in/natefinch/lumberjack.v2 v2.2.1/go.mod h1:YD8tP3GAjkrDg1eZH7EGmyESg/lsYskCTPBJVb9jqSc= -gopkg.in/square/go-jose.v2 v2.5.1/go.mod h1:M9dMgbHiYLoDGQrXy7OpJDJWiKiU//h+vD76mk0e1AI= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= -gopkg.in/tomb.v2 v2.0.0-20161208151619-d5d1b5820637/go.mod h1:BHsqpu/nsuzkT5BpiH1EMZPLyqSMM8JbIavyFACoFNk= gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= @@ -759,7 +473,6 @@ gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gotest.tools v2.2.0+incompatible h1:VsBPFP1AI068pPrMxtb/S8Zkgf9xEmTLJjfM+P5UIEo= gotest.tools v2.2.0+incompatible/go.mod h1:DsYFclhRJ6vuDpmuTbkuFWG+y2sxOXAzmJt81HFBacw= -gotest.tools/v3 v3.0.3/go.mod h1:Z7Lb0S5l+klDB31fvDQX8ss/FlKDxtlFlw3Oa8Ymbl8= honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190418001031-e561f6794a2a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= @@ -774,23 +487,16 @@ k8s.io/apiextensions-apiserver v0.28.4 h1:AZpKY/7wQ8n+ZYDtNHbAJBb+N4AXXJvyZx6ww6 k8s.io/apiextensions-apiserver v0.28.4/go.mod h1:pgQIZ1U8eJSMQcENew/0ShUTlePcSGFq6dxSxf2mwPM= k8s.io/apimachinery v0.28.4 h1:zOSJe1mc+GxuMnFzD4Z/U1wst50X28ZNsn5bhgIIao8= k8s.io/apimachinery v0.28.4/go.mod h1:wI37ncBvfAoswfq626yPTe6Bz1c22L7uaJ8dho83mgg= -k8s.io/apiserver v0.28.4/go.mod h1:Idq71oXugKZoVGUUL2wgBCTHbUR+FYTWa4rq9j4n23w= k8s.io/client-go v0.28.4 h1:Np5ocjlZcTrkyRJ3+T3PkXDpe4UpatQxj85+xjaD2wY= k8s.io/client-go v0.28.4/go.mod h1:0VDZFpgoZfelyP5Wqu0/r/TRYcLYuJ2U1KEeoaPa1N4= -k8s.io/code-generator v0.28.4/go.mod h1:OQAfl6bZikQ/tK6faJ18Vyzo54rUII2NmjurHyiN1g4= k8s.io/component-base v0.28.4 h1:c/iQLWPdUgI90O+T9TeECg8o7N3YJTiuz2sKxILYcYo= k8s.io/component-base v0.28.4/go.mod h1:m9hR0uvqXDybiGL2nf/3Lf0MerAfQXzkfWhUY58JUbU= -k8s.io/gengo v0.0.0-20230829151522-9cce18d56c01/go.mod h1:FiNAH4ZV3gBg2Kwh89tzAEV2be7d5xI0vBa/VySYy3E= -k8s.io/klog v1.0.0/go.mod h1:4Bi6QPql/J/LkTDqv7R/cd3hPo4k2DG6Ptcz060Ez5I= k8s.io/klog/v2 v2.110.1 h1:U/Af64HJf7FcwMcXyKm2RPM22WZzyR7OSpYj5tg3cL0= k8s.io/klog/v2 v2.110.1/go.mod h1:YGtd1984u+GgbuZ7e08/yBuAfKLSO0+uR1Fhi6ExXjo= -k8s.io/kms v0.28.4/go.mod h1:HL4/lR/bhjAJPbqycKtfhWiKh1Sp21cpHOL8P4oo87w= k8s.io/kube-openapi v0.0.0-20231113174909-778a5567bc1e h1:snPmy96t93RredGRjKfMFt+gvxuVAncqSAyBveJtr4Q= k8s.io/kube-openapi v0.0.0-20231113174909-778a5567bc1e/go.mod h1:AsvuZPBlUDVuCdzJ87iajxtXuR9oktsTctW/R9wwouA= k8s.io/utils v0.0.0-20230726121419-3b25d923346b h1:sgn3ZU783SCgtaSJjpcVVlRqd6GSnlTLKgpAAttJvpI= k8s.io/utils v0.0.0-20230726121419-3b25d923346b/go.mod h1:OLgZIPagt7ERELqWJFomSt595RzquPNLL48iOWgYOg0= -knative.dev/caching v0.0.0-20231017130712-54d0758671ef/go.mod h1:plGN+mIBKRtVxZ0vQeZ3Gt02RIaj0niwIMnQNkQHycw= -knative.dev/hack v0.0.0-20231109190034-5deaddeb51a7/go.mod h1:yk2OjGDsbEnQjfxdm0/HJKS2WqTLEFg/N6nUs6Rqx3Q= knative.dev/networking v0.0.0-20231115015815-3af9769712cd h1:VDtYz+hybqIAEp8NM2tAi2QV4D8Cc5DWLoXLi5IcZjE= knative.dev/networking v0.0.0-20231115015815-3af9769712cd/go.mod h1:HQ3rA7qrKVWvZUl6GGQefn/PzNXlX4e94KpbwBEjFcQ= knative.dev/pkg v0.0.0-20231115001034-97c7258e3a98 h1:uvOLwp5Ar7oJlaYEszh51CemuZc1sRRI14xzKhUEF3U= @@ -800,10 +506,8 @@ knative.dev/serving v0.39.3/go.mod h1:bWylSgwnRZeL659qy7m3/TZioYk25TIfusPUEeR695 maistra.io/api v0.0.0-20230417135504-0536f6c22b1c h1:WNBqA7R23P/TDkzP/wa3mfE4Bd9eM8NzWiwhcNyWAgk= maistra.io/api v0.0.0-20230417135504-0536f6c22b1c/go.mod h1:YdrOpeJBddUNHKIuhqlsNje9YUBFHl2pho7mhYwmsYs= rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= -sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.1.2/go.mod h1:+qG7ISXqCDVVcyO8hLn12AKVYYUjM7ftlqsqmrhMZE0= sigs.k8s.io/controller-runtime v0.16.3 h1:2TuvuokmfXvDUamSx1SuAOO3eTyye+47mJCigwG62c4= sigs.k8s.io/controller-runtime v0.16.3/go.mod h1:j7bialYoSn142nv9sCOJmQgDXQXxnroFU4VnX/brVJ0= -sigs.k8s.io/controller-tools v0.7.0/go.mod h1:bpBAo0VcSDDLuWt47evLhMLPxRPxMDInTEH/YbdeMK0= sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd h1:EDPBXCAspyGV4jQlpZSudPeMmr1bNJefnuqLsRAsHZo= sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd/go.mod h1:B8JuhiUyNFVKdsE8h686QcCxMaH6HrOAZj4vswFpcB0= sigs.k8s.io/structured-merge-diff/v4 v4.4.1 h1:150L+0vs/8DA78h1u02ooW1/fFq/Lwr+sGiqlzvrtq4= diff --git a/main.go b/main.go index ca95fc53..5b3e8753 100644 --- a/main.go +++ b/main.go @@ -32,6 +32,7 @@ import ( // to ensure that exec-entrypoint and run can make use of them. // Import all Kubernetes client auth plugins (e.g. Azure, GCP, OIDC, etc.) + _ "k8s.io/client-go/plugin/pkg/client/auth" "istio.io/client-go/pkg/apis/security/v1beta1" @@ -145,6 +146,7 @@ func main() { }, }, }) + if err != nil { setupLog.Error(err, "unable to start manager") os.Exit(1) @@ -153,6 +155,7 @@ func main() { //Setup InferenceService controller if err = (controllers.NewOpenshiftInferenceServiceReconciler( mgr.GetClient(), + mgr.GetAPIReader(), ctrl.Log.WithName("controllers").WithName("InferenceService"), getEnvAsBool("MESH_DISABLED", false))). SetupWithManager(mgr); err != nil {