databricks / click

The "Command Line Interactive Controller for Kubernetes"
Apache License 2.0
1.49k stars 84 forks source link

OpenID Connect support #118

Open rcny opened 5 years ago

rcny commented 5 years ago

Hello!

Just stumbled upon this really amazing tool, but it's impossible for me to use it in my daily job routines because of lack of the OIDC authn. Is there any possibility for this authn strategy to appear in Click in the foreseeable future?

[some-context] [some-ns] [none] > nodes
No update command specified, can't update
Couldn't get an authentication token. You can try exiting Click and running a kubectl command against the cluster to refresh it. Also please report this error on the Click github page.
Server Error: nodes is forbidden: User "system:anonymous" cannot list resource "nodes" in API group "" at the cluster scope

User configuration from my kubeconfig file (values were edited):

- name: mrcat
  user:
    auth-provider:
      config:
        client-id: blah
        client-secret: wow
        id-token: blah
        idp-certificate-authority-data: wow
        idp-issuer-url: https://blah
        refresh-token: wow
      name: oidc
ITman1 commented 4 years ago

I do use OIDC thanks to this small hack: https://github.com/ITman1/click/commit/b3c41cdbc43579876fe935b1c20f58d0b51e01dc It is of course not viable solution because it does not refresh tokens so you have to do auth again - time to time...