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

panic: No Auth Provider found for name "oidc" #345

Closed
r0fls opened this issue Dec 15, 2017 · 2 comments
Closed

panic: No Auth Provider found for name "oidc" #345

r0fls opened this issue Dec 15, 2017 · 2 comments

Comments

@r0fls
Copy link

r0fls commented Dec 15, 2017

The out of cluster config example no longer works for me. I believe it was recently so I'm not sure what changed. I get this error:

panic: No Auth Provider found for name "oidc"

goroutine 1 [running]:
main.main()
        /Users/raphael.deem/Documents/code/go/src/list-proms/main.go:53 +0x60d

I am able to list the nodes:

$ kubectl get nodes | wc -l
      10

I tried doing coreos/tectonic-forum#99 (comment)

But then I just get this, as expected:

$ go build                                                                                       
# _/Users/raphael.deem/Documents/code/list-proms                                                                      
./main.go:14:2: imported and not used: "k8s.io/client-go/plugin/pkg/client/auth/oidc"   
@ericchiang
Copy link
Contributor

The format is

import (
     _ "k8s.io/client-go/plugin/pkg/client/auth/oidc"
)

@r0fls
Copy link
Author

r0fls commented Dec 16, 2017

whoops, thank you!

@r0fls r0fls closed this as completed Dec 16, 2017
ripta added a commit to ripta/kops that referenced this issue Jul 24, 2018
Without this change, kops connections using OIDC to the cluster will
receive this error message:

  cannot build kube client for "$CLUSTER_NAME": No Auth Provider found
  for name "oidc"

kubernetes/client-go#345 suggests importing `.../client/auth/oidc`.
Looking at the code one level above, `.../client/auth` will actually
handle loading all known auth plugins for us.
ripta added a commit to ripta/kops that referenced this issue Jul 24, 2018
Without this change, for example, kops connections using OIDC to the
cluster will receive this error message:

> cannot build kube client for "$CLUSTER_NAME": No Auth Provider found
> for name "oidc"

kubernetes/client-go#345 suggests importing the package path
`plugin/pkg/client/auth/oidc` from `client-go`, but looking at the code
`plugin/pkg/client/auth` will actually handle loading all known auth
plugins for us.
ripta added a commit to ripta/kops that referenced this issue Jul 24, 2018
Without this change, for example, kops connections using OIDC to the
cluster will receive this error message:

> cannot build kube client for "$CLUSTER_NAME": No Auth Provider found
> for name "oidc"

kubernetes/client-go#345 suggests importing the package path
`plugin/pkg/client/auth/oidc` from `client-go`, but looking at the code
`plugin/pkg/client/auth` will actually handle loading all known auth
plugins for us.
ripta added a commit to ripta/kops that referenced this issue Jul 25, 2018
Without this change, for example, kops connections using OIDC to the
cluster will receive this error message:

> cannot build kube client for "$CLUSTER_NAME": No Auth Provider found
> for name "oidc"

kubernetes/client-go#345 suggests importing the package path
`plugin/pkg/client/auth/oidc` from `client-go`, but looking at the code
`plugin/pkg/client/auth` will actually handle loading all known auth
plugins for us.
HarikrishnanBalagopal added a commit to HarikrishnanBalagopal/move2kube that referenced this issue Nov 14, 2020
client-go isn't properly importing openid connect.
This causes the call to get an API client to fail always.
Fix: add a blank import as suggested in the github issue:
kubernetes/client-go#345

also refatored CLI by removing globals.

Signed-off-by: Harikrishnan Balagopal <[email protected]>
HarikrishnanBalagopal added a commit to HarikrishnanBalagopal/move2kube that referenced this issue Nov 14, 2020
client-go isn't properly importing openid connect.
This causes the call to get an API client to fail always.
Fix: add a blank import as suggested in the github issue:
kubernetes/client-go#345

also refatored CLI by removing globals.

Signed-off-by: Harikrishnan Balagopal <[email protected]>
ashokponkumar pushed a commit to konveyor/move2kube that referenced this issue Nov 14, 2020
client-go isn't properly importing openid connect.
This causes the call to get an API client to fail always.
Fix: add a blank import as suggested in the github issue:
kubernetes/client-go#345

also refatored CLI by removing globals.

Signed-off-by: Harikrishnan Balagopal <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants