Related to microsoft/vscode-remote-release#1935
Attach to Running Container, nothing happens
This is the Docker extension's viewlet. That should support ssh:// with the current release (https://github.com/microsoft/vscode-docker/issues/646). Moving there.
@joaomoreno Can you provide repro steps and what version of VS Code and vscode-docker you're using?
This was the latest VS Code Insider and latest vscode-docker from 6 days ago. I don't have access to the machine right now. I tested it on a fresh VM: install VS Code, Docker extension, Docker for Windows, Git for Windows, create SSH key, make sure you can ssh from Command Prompt solely using the key. Once all of that is done, simply configure the remote docker setting to the ssh:// format.
I am experiencing the exact same thing as @diablodale.
I was able to eliminate the "openssh-ssh-agent" error messages by starting the "ssh-agent" service in Windows 10: I found this helpful: https://stackoverflow.com/questions/52113738/starting-ssh-agent-on-windows-10-fails-unable-to-start-ssh-agent-service-erro
I am perplexed by this as I am able to run docker -H ssh://user@ip ps from Powershell and WSL just fine.
Additionally, I see theses messages if I open the vscode developer tools from Help:
mainThreadExtensionService.ts:66 Error: All configured authentication methods failed
Ok, so I figured it out for my purposes -- finally.
My situation was practically identical to what @diablodale describes.
SOLUTION
Even though you have your keys setup and you can do example commands like docker -H ssh://user@ip ps, you can still run into auth issues because this extension is specifically making using of the "ssh-agent" under the hood.
_IMPORTANT: Don't get these steps confused with similar things that can be done in WSL. Things done in WSL do not affect the outcome. This extension does not use WSL under the hood even if you have your terminal configured to use WSL. You must have it setup through the means the Windows OS uses._
\\.\pipe\openssh-ssh-agent in the message.<windows user folder>/.ssh/. ssh-add from powershell. This was the last part that I was missing and why I would get All configured authentication methods failedIn the end, would be nice if these errors were caught and the users were notified of the GUI of what actions might be needed.
I agree with @zifik. There's nothing we can realistically do about the fact that our dependencies (dockerode, ssh2 Node packages) require an auth agent, at least not in the short term, but we can warn the user if they have an SSH DOCKER_HOST but no agent set up. A Learn More link to the Wiki page on SSH setup would probably also help.
We have improved the warnings for this in Docker extension version 1.0.0.
Most helpful comment
Ok, so I figured it out for my purposes -- finally.
My situation was practically identical to what @diablodale describes.
SOLUTION
Even though you have your keys setup and you can do example commands like
docker -H ssh://user@ip ps, you can still run into auth issues because this extension is specifically making using of the "ssh-agent" under the hood._IMPORTANT: Don't get these steps confused with similar things that can be done in WSL. Things done in WSL do not affect the outcome. This extension does not use WSL under the hood even if you have your terminal configured to use WSL. You must have it setup through the means the Windows OS uses._
\\.\pipe\openssh-ssh-agentin the message.<windows user folder>/.ssh/.ssh-addfrom powershell. This was the last part that I was missing and why I would getAll configured authentication methods failedIn the end, would be nice if these errors were caught and the users were notified of the GUI of what actions might be needed.