From 4ef8caf4a709ba3797385dbf1f02f6f4213f75f3 Mon Sep 17 00:00:00 2001 From: Steven Wade Date: Fri, 26 Jul 2024 13:50:55 +0100 Subject: [PATCH] Importing k8s.io/client-go/plugin/pkg/client/auth package to hopefully fix oidc auth issue. Signed-off-by: Steven Wade --- internal/provider/provider_resource_data.go | 2 -- internal/provider/resource_bootstrap_git.go | 1 - internal/utils/kubernetes.go | 1 - main.go | 1 + 4 files changed, 1 insertion(+), 4 deletions(-) diff --git a/internal/provider/provider_resource_data.go b/internal/provider/provider_resource_data.go index 0c0e6dc0..b6651ed9 100644 --- a/internal/provider/provider_resource_data.go +++ b/internal/provider/provider_resource_data.go @@ -39,8 +39,6 @@ import ( clientcmdapi "k8s.io/client-go/tools/clientcmd/api" "sigs.k8s.io/controller-runtime/pkg/client" - _ "k8s.io/client-go/plugin/pkg/client/auth" - "github.com/fluxcd/terraform-provider-flux/internal/utils" ) diff --git a/internal/provider/resource_bootstrap_git.go b/internal/provider/resource_bootstrap_git.go index 33c9a894..1bfd00d9 100644 --- a/internal/provider/resource_bootstrap_git.go +++ b/internal/provider/resource_bootstrap_git.go @@ -57,7 +57,6 @@ import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" apitypes "k8s.io/apimachinery/pkg/types" "k8s.io/apimachinery/pkg/util/json" - _ "k8s.io/client-go/plugin/pkg/client/auth" "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/kustomize/api/konfig" diff --git a/internal/utils/kubernetes.go b/internal/utils/kubernetes.go index 0cdd057e..98fb061b 100644 --- a/internal/utils/kubernetes.go +++ b/internal/utils/kubernetes.go @@ -30,7 +30,6 @@ import ( "k8s.io/cli-runtime/pkg/genericclioptions" "k8s.io/client-go/discovery" "k8s.io/client-go/discovery/cached/memory" - _ "k8s.io/client-go/plugin/pkg/client/auth" "k8s.io/client-go/rest" "k8s.io/client-go/restmapper" "k8s.io/client-go/tools/clientcmd" diff --git a/main.go b/main.go index bddef7ca..ae8507d1 100644 --- a/main.go +++ b/main.go @@ -29,6 +29,7 @@ import ( "github.com/fluxcd/flux2/v2/pkg/manifestgen" "github.com/go-logr/logr" "github.com/hashicorp/terraform-plugin-framework/providerserver" + _ "k8s.io/client-go/plugin/pkg/client/auth" ctrllog "sigs.k8s.io/controller-runtime/pkg/log" "github.com/fluxcd/terraform-provider-flux/internal/provider"