microsoft / microsoft/vscode-remote-release

Current Docker context not used when connected to SSH server

Open
#6,114 21 comments 9 reactions 1 assignee View on GitHub

@chrmarti is already working on this.

Since Jan 3, 2022.

bug containers
Dominant language
Dockerfile
Stars
4.2k
Forks
470
Avg merge
1d 1h
Merged PRs (30d)
1

Description

  • VSCode Version: 1.63.2
  • Local OS Version: Windows 11
  • Remote OS Version: Ubuntu 20.04
  • Remote Extension/Connection Type: Remote SSH + Remote Containers
  • Logs:
    [14769 ms] Remote-Containers 0.209.6 in VS Code 1.63.2 (899d46d82c4c95423fb7e10e68eba52050e30ba3).
    [14769 ms] Start: Run: ssh 10.0.62.168 /bin/sh -c /bin/sh
    [14784 ms] Start: Run in host: id -un
    [15100 ms] patel_zeel
    [15100 ms]
    [15101 ms] Start: Run in host: cat /etc/passwd
    [15106 ms] Start: Run in host: echo ~
    [15111 ms] /home/patel_zeel
    [15111 ms]
    [15112 ms] Start: Run in host: test -x '/home/patel_zeel/.vscode-remote-containers/bin/899d46d82c4c95423fb7e10e68eba52050e30ba3/node'
    [15116 ms]
    [15116 ms]
    [15116 ms] Exit code 1
    [15117 ms] Start: Run in host: test -x '/home/patel_zeel/.vscode-server/bin/899d46d82c4c95423fb7e10e68eba52050e30ba3/node'
    [15120 ms]
    [15121 ms]
    [15121 ms] Start: Run in host: test -f '/home/patel_zeel/.vscode-server/bin/899d46d82c4c95423fb7e10e68eba52050e30ba3/node_modules/node-pty/package.json'
    [15124 ms]
    [15125 ms]
    [15125 ms] Start: Run in host: test -f '/home/patel_zeel/.vscode-remote-containers/dist/vscode-remote-containers-server-0.209.6.js'
    [15131 ms]
    [15131 ms]
    [15135 ms] userEnvProbe: loginInteractiveShell (default)
    [15135 ms] userEnvProbe shell: /bin/bash
    [17145 ms] Start: Run in Host: /bin/sh
    [17155 ms] Start: Run in container: for pid in cd /proc && ls -d [0-9]*; do { echo $pid ; readlink /proc/$pid/cwd ; readlink /proc/$pid/ns/mnt ; cat /proc/$pid/stat | tr "
    [21595 ms] userEnvProbe is taking longer than 2 seconds. Process tree:
    397624: /bin/bash -lic '/home/patel_zeel/.vscode-server/bin/899d46d82c4c95423fb7e10e68eba52050e30ba3/node' -p '"b1c1586b5db1908f0d9c56651a18942c" + JSON.stringify(process.env) + "b1c1586b5db1908f0d9c56651a18942c"'
    397640: zsh
    [25146 ms] userEnvProbe is taking longer than 10 seconds. Avoid waiting for user input in your shell's startup scripts. Continuing.
    [25151 ms] Start: Run in Host: docker version --format {{.Server.APIVersion}}
    [25202 ms]
    [25202 ms] Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?

Steps to Reproduce:

  1. Setup rootless docker on a remote machine
  2. Connect to the remote machine with Remote-SSH
  3. Try to do: Remote-containers: Reopen in Container.

Docker rootless mode is working fine on the remote machine. I have a strong feeling that I just need to set the correct path of docker.sock (unix:///run/uid/docker.sock) instead of current: unix:///var/run/docker.sock. I am unable to figure out a way to do that.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.