microsoft / mindaro

Bridge to Kubernetes - for Visual Studio and Visual Studio Code
MIT License
307 stars 106 forks source link

JSON-RPC connection with the remote party was lost before the request could complete #140

Closed creste closed 3 years ago

creste commented 3 years ago

Describe the bug After clicking "Bridge to Kubernetes" and selecting "Local Kube Config" for my Cluster source I see an error that says "The JSON-RPC connection with the remote party was lost before the request could complete." When I click "Refresh", sometimes I see the error again and sometimes the error goes away but I still don't see any way to select my kubernetes cluster.

To Reproduce Click "Bridge to Kubernetes": image

This is what I see: image

After clicking "Refresh" I see this: image

Logs 2021-03-26T20-13-01.7670592.log

Environment Details Client used (VS Code/Visual Studio): Visual Studio 2019 VS: Visual Studio version --> 16.9.2 Operating System: Windows 10 Pro 10.0.19042

I'm trying to connect to a local kubernetes cluster running in minikube. I am able to successfully connect to the cluster using kubectl.

Additional context I read https://github.com/microsoft/mindaro/issues/129. I am using minikube, so I removed all "extensions" from my kubeconfig. The problem remains.

I read https://github.com/microsoft/mindaro/issues/25#issuecomment-688641944 which indicated I should make sure nothing is listening in port 80. I confirmed nothing is listening on port 80. That comment also said to make sure my hosts file is writeable. I've tried running Visual Studio as an administrator but still saw the problem.

creste commented 3 years ago

I fixed this problem by installing the Azure Development workload using the Visual Studio Installer. I didn't realize that was a prerequisite to using Bridge to Kubernetes.

daniv-msft commented 3 years ago

Thanks @creste for logging this issue and happy that you found the solution.

@danegsta Could you please confirm this is a requirement in Visual Studio to install the Azure Development workload? I don't believe we're mentioning that in the doc, so if it is we should update that.