profile
viewpoint

Ask questionsConnect to remote docker daemon when using "Remote - SSH" extension

The Remote - SSH extension

This week, the Remote Development pack was released to Insiders. This allows you to open up a VSCode window as if it were running on the remote host. I have been using the Remote - SSH extension to connect to a server and it works beautifully.

Expected vscode-docker behaviour

When I install the vscode-docker extension, it should be installed to the remote VSCode installation.
When opening a remote (SSH) vscode session, vscode-docker should list images/containers from the docker daemon on the remote host.

Actual vscode-docker behaviour

The extension is installed locally and lists my local containers/images.

Summary

It would be fantastic if these two extensions could work together so that I can view my remote docker container/images while I'm developing remotely over SSH and my local ones when working locally.

I don't think this effects the Remote - WSL and Remote - Containers extensions as developers tend to use the local Docker daemon in these environment anyway (either via opening TCP port 2375 or by using some form of DinD).

Potentially related to #216 & #646.

microsoft/vscode-docker

Answer questions pd93

@PabloSzx's workaround fixes the problem for me on "Remote - SSH" sessions, but unfortunately it also breaks "Remote - WSL". (probably a separate issue). A slight improvement on this would be to force the docker extension to be installed on SSH sessions only:

    "remote.SSH.defaultExtensions": [
        "peterjausovec.vscode-docker"
    ]

But I can't get this to work either 😞

Unfortunately, this does mean my previous suggestion of setting "extensionKind" in the package.json might break the extension when running via "Remote - WSL" and "Remote - Container"?

useful!

Related questions

Error Message: connect EACCES /var/run/docker.sock hot 3
Error Message: connect EACCES /var/run/docker.sock hot 1
Debug not running hot 1
Error:connect ENOENT //.pipe/docker_engine hot 1
Error:connect ENOENT //.pipe/docker_engine hot 1
In order to use an SSH DOCKER_HOST on OS X and Linux, you must configure an ssh-agent. - vscode-docker hot 1
In order to use an SSH DOCKER_HOST on OS X and Linux, you must configure an ssh-agent. hot 1
Improve error message when docker has not been found- ENOENT //./pipe/docker_engine hot 1
VSCode: "No matching resources found." when using with Azure Container Registry extension hot 1
Starting container process caused "process_linux.go:297: applying cgroup configuration for process caused \"open hot 1
Error:connect ENOENT //.pipe/docker_engine hot 1
browse to containers step gives 401 error hot 1
Error Message: connect EACCES /var/run/docker.sock hot 1
Docker Machine crashes when managing Docker containers with vscode-docker plugin hot 1
source:https://uonfu.com/
Github User Rank List