Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: load all supported authentication plugins for k8s client-go #4802

Merged
merged 3 commits into from
Dec 29, 2020
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
8 changes: 2 additions & 6 deletions cmd/argo/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,8 @@ import (
"os"

"github.com/argoproj/argo/cmd/argo/commands"
// load the azure plugin (required to authenticate against AKS clusters).
_ "k8s.io/client-go/plugin/pkg/client/auth/azure"
// load the gcp plugin (required to authenticate against GKE clusters).
_ "k8s.io/client-go/plugin/pkg/client/auth/gcp"
// load the oidc plugin (required to authenticate with OpenID Connect).
_ "k8s.io/client-go/plugin/pkg/client/auth/oidc"
// load authentication plugin for obtaining credentials from cloud providers.
_ "k8s.io/client-go/plugin/pkg/client/auth"
)

func main() {
Expand Down
8 changes: 2 additions & 6 deletions cmd/argoexec/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,8 @@ import (
"os"

"github.com/argoproj/argo/cmd/argoexec/commands"
// load the azure plugin (required to authenticate against AKS clusters).
_ "k8s.io/client-go/plugin/pkg/client/auth/azure"
// load the gcp plugin (required to authenticate against GKE clusters).
_ "k8s.io/client-go/plugin/pkg/client/auth/gcp"
// load the oidc plugin (required to authenticate with OpenID Connect).
_ "k8s.io/client-go/plugin/pkg/client/auth/oidc"
// load authentication plugin for obtaining credentials from cloud providers.
_ "k8s.io/client-go/plugin/pkg/client/auth"
)

func main() {
Expand Down
5 changes: 2 additions & 3 deletions cmd/workflow-controller/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,8 @@ import (
log "github.com/sirupsen/logrus"
"github.com/spf13/cobra"
"k8s.io/client-go/kubernetes"
_ "k8s.io/client-go/plugin/pkg/client/auth/azure"
_ "k8s.io/client-go/plugin/pkg/client/auth/gcp"
_ "k8s.io/client-go/plugin/pkg/client/auth/oidc"
// load authentication plugin for obtaining credentials from cloud providers.
_ "k8s.io/client-go/plugin/pkg/client/auth"
"k8s.io/client-go/tools/clientcmd"

wfclientset "github.com/argoproj/argo/pkg/client/clientset/versioned"
Expand Down
8 changes: 2 additions & 6 deletions test/e2e/fixtures/e2e_suite.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,8 @@ import (
"k8s.io/apimachinery/pkg/runtime/schema"
"k8s.io/client-go/dynamic"

// load the azure plugin (required to authenticate against AKS clusters).
_ "k8s.io/client-go/plugin/pkg/client/auth/azure"
// load the gcp plugin (required to authenticate against GKE clusters).
_ "k8s.io/client-go/plugin/pkg/client/auth/gcp"
// load the oidc plugin (required to authenticate with OpenID Connect).
_ "k8s.io/client-go/plugin/pkg/client/auth/oidc"
// load authentication plugin for obtaining credentials from cloud providers.
_ "k8s.io/client-go/plugin/pkg/client/auth"

"github.com/stretchr/testify/suite"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
Expand Down