Open jarrett-confrey opened 3 years ago
@jarrett-confrey thanks for reaching out to us! Could you please attach the logs from /tmp/Bridge To Kubernetes (or send them at BridgeToKubernetes@microsoft.com) as well? That should help us in understanding what's going on
@amsoedal i have emailed the relevant logs to BridgeToKubernetes@microsoft.com. please let me know if theres anything else i can do to help get the the bottom of the issue. thanks!
@jarrett-confrey thanks for sending those! Could you confirm that kubectl get po
works for you? I know you said the kubernetes CLI is working, but what we're doing under the hood should be the same thing.
@amsoedal sure thing, thanks for looking into this! yes kubectl get po
works for me, i do have my namespace specified in my kube config though so its more equivalent to kubectl get po --namespace MY_NAMESPACE
. i am able to successfully get pods using the node kubernetes client without needing to do anything special besides specifying my namespace as well. i do not have permission to access the default namespace if that matters at all
@jarrett-confrey thanks for the details! Because our tools rely on the c# kubernetes client, I've opened an issue to clarify with them whether it could be a dependency issue (https://github.com/kubernetes-client/csharp/issues/624). I'll keep investigating and keep you posted
i was able to fix the issue with https://github.com/kubernetes-client/csharp/pull/633
@jarrett-confrey that's awesome! It'll take a little while for us to pull in the changes to the c# kubernetes client, but is your kubeconfig working now that the token is refreshed?
@amsoedal the issue was that my token did not need to be refreshed, it has a long life and the check for expiration was incorrect. i did not get the refresh working but kubernetes calls such as listing pods are now working for me. ill have to double check but i suspect that im not able refresh the long lived token in my environment. i believe i have seen similar refresh issues with other kubernetes clients when my token expires
what does the timeline for this kind of change looks like?
Oh I see, makes sense. Thanks for clarifying. Once your PR is merged and they release a new version including your change, we should be able to release our version including that update within a few weeks.
@amsoedal sounds good, thank you. it appears that Bridge to Kubernetes
is close source with no change log. is there a way to know when the csharp kubernetes client has been bumped in your project and when that change has been released to the vscode marketplace? im happy to test any beta versions. thanks!
@jarrett-confrey yes, we're currently closed source (although this will hopefully change in a few months). I can update this thread when the change is complete :) thanks for your patience!
@amsoedal i saw that there was a bridge to kubernetes update today but im still facing the issue. any chance kubernetes-client
can be updated to contain my fix? thanks!
@jarrett-confrey The fix for kubernetes-client is not yet released in the recent update. It would be released in a week or two. Thanks!
@rakeshvanga @amsoedal i see that there was a bridge to kubernetes update on 7/8/2021 but im still seeing the issue. can you confirm if the fix is in 1.0.120210709
or not? if not do you know when the fix might go out? im eager to try out this plugin. thanks!
Hi @jarrett-confrey, I'm so sorry for the long wait. I just made the change to bump the package and it should go out as part of our next release. If you prefer, I can email you with some beta bits as soon as this gets checked in. Thanks so much for your patience!
hey @amsoedal a wouldnt mind testing out a beta, thanks!
Hi @jarrett-confrey, these are the steps:
code
Let me know how it works for you! Thanks!
@amsoedal i finally got a chance to test this but i am seeing the same issue. are you sure that this is using the correct kubernetes cshap client version that includes my fix?
@jarrett-confrey did you test using the steps above or using the latest extension? The staging bits should have them, but for the latest extension the very latest changes have only been flighted to 25% of users so far.
Describe the bug
when i start vscode i see a spinner next to kubernetes in the status bar. after a couple seconds the spinner turns into a warning symbol. if i click on kubernetes in the status bar at this point i see
Failed to refresh the kubeconfig token: Operation returned an invalid status code 'Unauthorized'
.OR
in the kubernetes cluster explorer when i right click on a pod and select
Debug (Local Tunnel)
i see the sameFailed to refresh the kubeconfig token: Operation returned an invalid status code 'Unauthorized'
at the bottom right of the screen. all the other functions in the pod right click menu appear to work fine. kubectl cli works fine. the npm module @kubernetes/client-node works fine. auth-provider is gangway/dex oidcTo Reproduce
start vscode and click on kubernetes in the status bar
OR
right click on a pod and select
Debug (Local Tunnel)
.Logs
Environment Details
Client used: VS Code Client's version: 1.0.120210507 Operating System: macOS 11.3.1 (20E241)
Additional context
im super excited to try out this feature, thanks for all the hard work!