microsoft / vscode-remote-release

Visual Studio Code Remote Development: Open any folder in WSL, in a Docker container, or on a remote machine using SSH and take advantage of VS Code's full feature set.
https://aka.ms/vscode-remote
Other
3.67k stars 293 forks source link

[Remote-SSH Bug]: Failed to open old devcontainer after open a new one #9311

Closed yangkghjh closed 6 months ago

yangkghjh commented 11 months ago

Is there an existing issue for this bug?

Required Troubleshooting Steps

Connect Locally

It connects successfully

->

No response

Expected Behavior

No response

Steps To Reproduce

  1. Open project a in devcontainer a on remote server
  2. Open project b in devcontainer b on remote server in another window
  3. Reload project a window, failed to open
  4. Remove devcontainer a and reopen, it works
  5. Devcontainer b failed to open

Remote-SSH Log

Remote-SSH Log

``` [1011 ms] Dev Containers 0.327.0 over Remote - SSH 0.107.1 in VS Code 1.85.1 (0ee08df0cf4527e40edc9aa28f4b5bd38bbff2b2). [1010 ms] Start: 正在解析远程 [1024 ms] Start: Run: /bin/sh [1028 ms] Start: Run in host: echo ~ [1074 ms] /home/biny [1074 ms] [1075 ms] Start: Run in host: id -un [1118 ms] biny [1118 ms] [1118 ms] Start: Run in host: (command -v getent >/dev/null 2>&1 && getent passwd 'biny' || grep -E '^biny|^[^:]*:[^:]*:biny:' /etc/passwd || true) [1162 ms] userEnvProbe: loginInteractiveShell (default) [1163 ms] userEnvProbe: not found in cache [1163 ms] userEnvProbe shell: /bin/zsh [1805 ms] userEnvProbe PATHs: Probe: '~/miniconda3/bin:/home/linuxbrew/.linuxbrew/bin:/home/linuxbrew/.linuxbrew/sbin:/home/biny/.local/share/zinit/polaris/bin:/home/biny/.krew/bin:/home/biny/.krew/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/home/biny/ws/dev_tools/src/branches/hci/media_build/.build/.lib/m64/bin:/home/biny/go/bin:/home/biny/.local/bin:/home/biny/sdk/go1.19/bin:/home/biny/ws/dev_tools/src/branches/hci/media_build/.build/.lib/m64/bin:/home/biny/go/bin:/home/biny/.local/bin:/home/biny/sdk/go1.19/bin:/home/biny/.local/script' Container: None [1809 ms] Setting up container for folder or workspace: /home/biny/ws/wss/vod [1810 ms] Host authority: ssh-remote+10.100.1.108 [1810 ms] Start: Run: wsl -l -v [1922 ms] Start: Run: wsl -d Ubuntu -e /bin/sh -c echo ~ [2117 ms] Start: Run: wsl -d Ubuntu -e /bin/sh -c cd '/root' && /bin/sh [2125 ms] Start: Run in host: id -un [2242 ms] root [2242 ms] [2242 ms] Start: Run in host: (command -v getent >/dev/null 2>&1 && getent passwd 'root' || grep -E '^root|^[^:]*:[^:]*:root:' /etc/passwd || true) [2244 ms] Start: Run in host: echo ~ [2245 ms] /root [2245 ms] [2245 ms] Start: Run in host: test -x '/root/.vscode-remote-containers/bin/0ee08df0cf4527e40edc9aa28f4b5bd38bbff2b2/node' [2246 ms] [2246 ms] [2246 ms] Start: Run in host: test -f '/root/.vscode-remote-containers/dist/vscode-remote-containers-server-0.327.0.js' [2247 ms] [2247 ms] [2251 ms] userEnvProbe: loginInteractiveShell (default) [2251 ms] userEnvProbe: not found in cache [2251 ms] userEnvProbe shell: /usr/bin/zsh [2852 ms] userEnvProbe PATHs: Probe: '/root/miniconda3/bin:/root/miniconda3/condabin:/root/.local/share/zinit/polaris/bin:/home/linuxbrew/.linuxbrew/bin:/home/linuxbrew/.linuxbrew/sbin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/usr/lib/wsl/lib:/mnt/c/Program Files (x86)/AdoptOpenJDK/jdk-8.0.282.8-hotspot/bin:/mnt/c/Windows/system32:/mnt/c/Windows:/mnt/c/Windows/System32/Wbem:/mnt/c/Windows/System32/WindowsPowerShell/v1.0:/mnt/c/Windows/System32/OpenSSH:/mnt/c/Program Files (x86)/NVIDIA Corporation/PhysX/Common:/mnt/c/Program Files/NVIDIA Corporation/NVIDIA NvDLISR:/mnt/c/Program Files/Git/cmd:/mnt/c/Program Files/nodejs:/mnt/c/Program Files/WireGuard:/mnt/c/WINDOWS/system32:/mnt/c/WINDOWS:/mnt/c/WINDOWS/System32/Wbem:/mnt/c/WINDOWS/System32/WindowsPowerShell/v1.0:/mnt/c/WINDOWS/System32/OpenSSH:/mnt/c/Users/YB/AppData/Local/Microsoft/WindowsApps:/mnt/c/Users/YB/AppData/Local/Programs/Microsoft VS Code/bin:/mnt/c/Users/YB/AppData/Roaming/npm:/mnt/c/Users/YB/AppData/Roaming/Code/User/globalStorage/ms-vscode-remote.remote-containers/cli-bin:/mnt/c/Users/YB/AppData/Local/Programs/Microsoft VS Code Insiders/bin:/mnt/c/Users/YB/AppData/Local/Microsoft/WinGet/Packages/UderzoSoftware.SpaceSniffer_Microsoft.Winget.Source_8wekyb3d8bbwe:/root/go/sdk/go1.18.3/bin:/root/go/bin:/root/miniconda3/bin:/root/dev/dev_tools/src/branches/hci/media_build/.build/.lib/m64/bin:/bin:/root/.local/script' Container: None [2855 ms] Start: Check Docker is running [2855 ms] Start: Run: docker version --format {{.Server.APIVersion}} [2902 ms] Server API version: 1.41 [2903 ms] Start: Run: docker volume ls -q [2951 ms] Start: Run: docker ps -q -a --filter label=vsch.local.folder=/home/biny/ws/wss/vod --filter label=vsch.quality=stable [2998 ms] Start: Run: docker ps -q -a --filter label=devcontainer.local_folder=/home/biny/ws/wss/vod --filter label=devcontainer.config_file=/home/biny/ws/wss/vod/.devcontainer/devcontainer.json [3046 ms] Start: Run: docker inspect --type container 99af555a6e7f [3093 ms] Start: Run: docker ps -q -a --filter label=devcontainer.local_folder=/home/biny/ws/wss/vod [3138 ms] Start: Run: docker inspect --type container 99af555a6e7f [3183 ms] Start: Run: docker exec -i -u root 99af555a6e7f297fce36d4b15bf397d1a96963afcd06659c0df7c6c1c8f90ca1 /bin/sh -c echo "Container already running. Keep-alive process started." ; export VSCODE_REMOTE_CONTAINERS_SESSION=026f718c-b403-41cf-8c75-2ede8a0b7f091702629828739 ; /bin/sh [3186 ms] Start: Run: /home/biny/.vscode-server/bin/0ee08df0cf4527e40edc9aa28f4b5bd38bbff2b2/node /home/biny/.vscode-remote-containers/dist/dev-containers-cli-0.327.0/dist/spec-node/devContainersSpecCLI.js read-configuration --workspace-folder /home/biny/ws/wss/vod --id-label devcontainer.local_folder=/home/biny/ws/wss/vod --id-label devcontainer.config_file=/home/biny/ws/wss/vod/.devcontainer/devcontainer.json --log-level debug --log-format json --config /home/biny/ws/wss/vod/.devcontainer/devcontainer.json --mount-workspace-git-root [3282 ms] Container already running. Keep-alive process started. [2443 ms] @devcontainers/cli 0.54.1. Node.js v18.15.0. linux 5.15.0-91-generic x64. [2443 ms] Start: Run: git rev-parse --show-cdup [2450 ms] Start: Run: docker ps -q -a --filter label=devcontainer.local_folder=/home/biny/ws/wss/vod --filter label=devcontainer.config_file=/home/biny/ws/wss/vod/.devcontainer/devcontainer.json [2479 ms] Start: Run: docker inspect --type container 99af555a6e7f [3797 ms] Start: Run: /home/biny/.vscode-server/bin/0ee08df0cf4527e40edc9aa28f4b5bd38bbff2b2/node /home/biny/.vscode-remote-containers/dist/dev-containers-cli-0.327.0/dist/spec-node/devContainersSpecCLI.js up --container-session-data-folder /tmp/devcontainers-026f718c-b403-41cf-8c75-2ede8a0b7f091702629828739 --workspace-folder /home/biny/ws/wss/vod --workspace-mount-consistency cached --id-label devcontainer.local_folder=/home/biny/ws/wss/vod --id-label devcontainer.config_file=/home/biny/ws/wss/vod/.devcontainer/devcontainer.json --log-level debug --log-format json --config /home/biny/ws/wss/vod/.devcontainer/devcontainer.json --default-user-env-probe loginInteractiveShell --mount type=volume,source=vscode,target=/vscode,external=true --skip-post-create --update-remote-user-uid-default on --mount-workspace-git-root [3011 ms] @devcontainers/cli 0.54.1. Node.js v18.15.0. linux 5.15.0-91-generic x64. [3011 ms] Start: Run: docker buildx version [3078 ms] github.com/docker/buildx v0.8.2-docker 6224def4dd2c3d347eee19db595348c50d7cb491 [3078 ms] [3078 ms] Start: Resolving Remote [3081 ms] Start: Run: git rev-parse --show-cdup [3450 ms] Start: Run: docker ps -q -a --filter label=devcontainer.local_folder=/home/biny/ws/wss/vod --filter label=devcontainer.config_file=/home/biny/ws/wss/vod/.devcontainer/devcontainer.json [3480 ms] Start: Run: docker inspect --type container 99af555a6e7f [3512 ms] Start: Inspecting container [3512 ms] Start: Run: docker inspect --type container 99af555a6e7f297fce36d4b15bf397d1a96963afcd06659c0df7c6c1c8f90ca1 [3542 ms] Start: Run in container: /bin/sh [3544 ms] Start: Run in container: uname -m [3598 ms] x86_64 [3598 ms] [3598 ms] Start: Run in container: (cat /etc/os-release || cat /usr/lib/os-release) 2>/dev/null [3599 ms] NAME="Ubuntu" VERSION="14.04.5 LTS, Trusty Tahr" ID=ubuntu ID_LIKE=debian PRETTY_NAME="Ubuntu 14.04.5 LTS" VERSION_ID="14.04" HOME_URL="http://www.ubuntu.com/" SUPPORT_URL="http://help.ubuntu.com/" BUG_REPORT_URL="http://bugs.launchpad.net/ubuntu/" [3599 ms] [3600 ms] Start: Run in container: (command -v getent >/dev/null 2>&1 && getent passwd 'root' || grep -E '^root|^[^:]*:[^:]*:root:' /etc/passwd || true) [3601 ms] Start: Run in container: test -f '/var/devcontainer/.patchEtcEnvironmentMarker' [3602 ms] [3602 ms] [3602 ms] Start: Run in container: test -f '/var/devcontainer/.patchEtcProfileMarker' [3603 ms] [3603 ms] [4526 ms] Start: Run: docker inspect --type container 99af555a6e7f297fce36d4b15bf397d1a96963afcd06659c0df7c6c1c8f90ca1 [4577 ms] Start: Run: /home/biny/.vscode-server/bin/0ee08df0cf4527e40edc9aa28f4b5bd38bbff2b2/node /home/biny/.vscode-remote-containers/dist/dev-containers-cli-0.327.0/dist/spec-node/devContainersSpecCLI.js read-configuration --workspace-folder /home/biny/ws/wss/vod --id-label devcontainer.local_folder=/home/biny/ws/wss/vod --id-label devcontainer.config_file=/home/biny/ws/wss/vod/.devcontainer/devcontainer.json --container-id 99af555a6e7f297fce36d4b15bf397d1a96963afcd06659c0df7c6c1c8f90ca1 --log-level debug --log-format json --config /home/biny/ws/wss/vod/.devcontainer/devcontainer.json --include-merged-configuration --mount-workspace-git-root [3787 ms] @devcontainers/cli 0.54.1. Node.js v18.15.0. linux 5.15.0-91-generic x64. [3787 ms] Start: Run: git rev-parse --show-cdup [3793 ms] Start: Run: docker inspect --type container 99af555a6e7f297fce36d4b15bf397d1a96963afcd06659c0df7c6c1c8f90ca1 [4746 ms] Start: Inspecting container [4746 ms] Start: Run: docker inspect --type container 99af555a6e7f297fce36d4b15bf397d1a96963afcd06659c0df7c6c1c8f90ca1 [4797 ms] Start: Run in container: /bin/sh [4800 ms] Start: Run in container: uname -m [4894 ms] x86_64 [4894 ms] [4894 ms] Start: Run in container: (cat /etc/os-release || cat /usr/lib/os-release) 2>/dev/null [4938 ms] NAME="Ubuntu" VERSION="14.04.5 LTS, Trusty Tahr" ID=ubuntu ID_LIKE=debian PRETTY_NAME="Ubuntu 14.04.5 LTS" VERSION_ID="14.04" HOME_URL="http://www.ubuntu.com/" SUPPORT_URL="http://help.ubuntu.com/" BUG_REPORT_URL="http://bugs.launchpad.net/ubuntu/" [4938 ms] [4938 ms] Start: Run in container: (command -v getent >/dev/null 2>&1 && getent passwd 'root' || grep -E '^root|^[^:]*:[^:]*:root:' /etc/passwd || true) [4982 ms] Start: Setup shutdown monitor [4983 ms] Forking shutdown monitor: c:\Users\YB\.vscode\extensions\ms-vscode-remote.remote-containers-0.327.0\dist\shutdown\shutdownMonitorProcess \\.\pipe\vscode-remote-containers-366147af-854d-4c23-820e-5188652173a7-sock singleContainer Debug c:\Users\YB\AppData\Roaming\Code\logs\20231215T162747\window1\exthost\ms-vscode-remote.remote-containers 1702629829482 [4994 ms] Start: Run in container: test -d /root/.vscode-server [5038 ms] [5038 ms] [5038 ms] Start: Run in container: test ! -f '/root/.vscode-server/data/Machine/.writeMachineSettingsMarker' && set -o noclobber && mkdir -p '/root/.vscode-server/data/Machine' && { > '/root/.vscode-server/data/Machine/.writeMachineSettingsMarker' ; } 2> /dev/null [5082 ms] [5082 ms] [5082 ms] Exit code 1 [5082 ms] Start: Run in container: cat /root/.vscode-server/data/Machine/settings.json [5126 ms] { } [5126 ms] [5126 ms] Start: Run in container: test -d /root/.vscode-server/bin/0ee08df0cf4527e40edc9aa28f4b5bd38bbff2b2 [5170 ms] [5170 ms] [5170 ms] Start: Run in container: test -d /vscode/vscode-server/bin/linux-x64/0ee08df0cf4527e40edc9aa28f4b5bd38bbff2b2 [5218 ms] [5218 ms] [5219 ms] Start: Run in container: touch '/vscode/vscode-server/bin/linux-x64/0ee08df0cf4527e40edc9aa28f4b5bd38bbff2b2' [5219 ms] Start: Launching Dev Containers helper. [5219 ms] ssh-agent: SSH_AUTH_SOCK not set on remote host. [5220 ms] ssh-agent: SSH_AUTH_SOCK not set on local host. [5220 ms] ssh-agent: SSH_AUTH_SOCK in container (/tmp/vscode-ssh-auth-8fd446d0-f0ae-462e-a3b7-9974e8301f9f.sock) forwarded to local host (\\.\pipe\openssh-ssh-agent). [5220 ms] X11 forwarding: DISPLAY not set on remote host. [5220 ms] X11 forwarding: DISPLAY not set on local host. [5266 ms] [5266 ms] [5267 ms] Start: Run in container: test -e /tmp/.X11-unix/X0 [5310 ms] [5310 ms] [5310 ms] Start: Run in container: test -e /tmp/.X11-unix/X1 [5354 ms] [5354 ms] [5354 ms] Start: Run in container: test -e /tmp/.X11-unix/X2 [5398 ms] [5398 ms] [5399 ms] Start: Run in container: test -e /tmp/.X11-unix/X3 [5442 ms] [5442 ms] [5442 ms] Start: Run in container: test -e /tmp/.X11-unix/X4 [5486 ms] [5486 ms] [5486 ms] Start: Run in container: test -e /tmp/.X11-unix/X5 [5530 ms] [5530 ms] [5530 ms] Exit code 1 [5530 ms] Start: Run in container: mkdir -p '/tmp/.X11-unix' [5578 ms] [5578 ms] [5578 ms] X11 forwarding: DISPLAY in container (:5) forwarded to wsl host (:0). [5578 ms] Start: Run in container: gpgconf --list-dir agent-socket [5622 ms] [5622 ms] /bin/sh: 17: gpgconf: not found [5622 ms] Exit code 127 [5622 ms] gpg-agent: No agent-socket found in container. [5622 ms] Start: Run in container: command -v docker >/dev/null 2>&1 [5666 ms] [5666 ms] [5666 ms] Start: Run in container: /bin/sh [5667 ms] userEnvProbe: loginInteractiveShell (default) [5667 ms] Start: Run in container: test -f '/tmp/devcontainers-026f718c-b403-41cf-8c75-2ede8a0b7f091702629828739/env-loginInteractiveShell.json' [5671 ms] [5672 ms] [5672 ms] Exit code 1 [5672 ms] userEnvProbe: not found in cache [5672 ms] userEnvProbe shell: /bin/bash [5673 ms] Start: Run in container: echo ~ [5681 ms] Start: Run in container: # Test for /root/.ssh/known_hosts and ssh [5726 ms] /root/.ssh/known_hosts exists [5726 ms] [5726 ms] Exit code 1 [5726 ms] /root [5726 ms] [5727 ms] Start: Run in container: command -v git >/dev/null 2>&1 && git config --system --replace-all credential.helper '!f() { /root/.vscode-server/bin/0ee08df0cf4527e40edc9aa28f4b5bd38bbff2b2/node /tmp/vscode-remote-containers-8fd446d0-f0ae-462e-a3b7-9974e8301f9f.js git-credential-helper $*; }; f' || true [5727 ms] Start: Run in container: cat <<'EOF-/tmp/vscode-remote-containers-8fd446d0-f0ae-462e-a3b7-9974e8301f9f.js' >/tmp/vscode-remote-containers-8fd446d0-f0ae-462e-a3b7-9974e8301f9f.js [5770 ms] [5771 ms] [5771 ms] [5771 ms] [5772 ms] Start: Run in container: for pid in `cd /proc && ls -d [0-9]*`; do { echo $pid ; readlink /proc/$pid/cwd || echo ; readlink /proc/$pid/ns/mnt || echo ; cat /proc/$pid/stat | tr " [5843 ms] Start: Run in container: cat '/root/.vscode-server/bin/0ee08df0cf4527e40edc9aa28f4b5bd38bbff2b2/product.json' [5843 ms] Start: Run in container: cat ~/.docker/config.json || echo "{ [5886 ms] { "credsStore": "dev-containers-6ede3dbf-5e8d-4774-aa51-ac5080c13a00" } [5887 ms] [5887 ms] Extension host agent is already running. [5888 ms] Start: Run in container: cat '/root/.vscode-server/data/Machine/.devport-0ee08df0cf4527e40edc9aa28f4b5bd38bbff2b2' 2>/dev/null [5934 ms] 45479 [5934 ms] [5934 ms] Start: Run in container: mkdir -p /usr/local/bin && cat <<'EOF-/usr/local/bin/docker-credential-dev-containers-8fd446d0-f0ae-462e-a3b7-9974e8301f9f' >/usr/local/bin/docker-credential-dev-containers-8fd446d0-f0ae-462e-a3b7-9974e8301f9f [5978 ms] [5978 ms] [5978 ms] Start: Run in container: cat '/root/.vscode-server/data/Machine/.connection-token-0ee08df0cf4527e40edc9aa28f4b5bd38bbff2b2' [6022 ms] 2e6af8f1-6632-40e0-a87f-f20e8eda684f [6022 ms] [6022 ms] Start: Run in container: chmod +x /usr/local/bin/docker-credential-dev-containers-8fd446d0-f0ae-462e-a3b7-9974e8301f9f [6023 ms] Port forwarding for container port 45479 starts listening on local port. [6024 ms] Port forwarding local port 52551 to container port 45479 [6070 ms] [6070 ms] [6071 ms] Start: Run in container: mkdir -p ~/.docker && cat <<'EOF-/usr/local/bin/docker-credential-dev-containers-8fd446d0-f0ae-462e-a3b7-9974e8301f9f' >~/.docker/config.json [6072 ms] Start: Run in container: # Test for /root/.gitconfig and git [6119 ms] /root/.gitconfig exists [6119 ms] [6119 ms] Exit code 1 [6120 ms] [6120 ms] [6121 ms] Start: Run in container: cat <<'EOF-/tmp/vscode-remote-containers-server-8fd446d0-f0ae-462e-a3b7-9974e8301f9f.js' >/tmp/vscode-remote-containers-server-8fd446d0-f0ae-462e-a3b7-9974e8301f9f.js_1702629835602 [6124 ms] Start: Run in container: # Cleaning up git config [6170 ms] [6170 ms] [6171 ms] [6171 ms] [6171 ms] Start: Run in container: command -v git >/dev/null 2>&1 && git config --global --replace-all credential.helper '!f() { /root/.vscode-server/bin/0ee08df0cf4527e40edc9aa28f4b5bd38bbff2b2/node /tmp/vscode-remote-containers-8fd446d0-f0ae-462e-a3b7-9974e8301f9f.js git-credential-helper $*; }; f' || true [6214 ms] [6215 ms] [6437 ms] userEnvProbe PATHs: Probe: '/usr/local/go/bin:/root/go/bin:/opt/BullseyeCoverage/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/go/bin' Container: '/usr/local/go/bin:/root/go/bin:/opt/BullseyeCoverage/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin' [6437 ms] Start: Run in container: mkdir -p '/tmp/devcontainers-026f718c-b403-41cf-8c75-2ede8a0b7f091702629828739' && cat > '/tmp/devcontainers-026f718c-b403-41cf-8c75-2ede8a0b7f091702629828739/env-loginInteractiveShell.json' << 'envJSON' [6482 ms] [6482 ms] [6495 ms] Port forwarding connection from 52553 > 52551 > 45479 in the container. [6495 ms] Start: Run in container: /root/.vscode-server/bin/0ee08df0cf4527e40edc9aa28f4b5bd38bbff2b2/node -e [6614 ms] Port forwarding 52553 > 52551 > 45479 stderr: Error: connect ECONNREFUSED 127.0.0.1:45479 at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1494:16) [6658 ms] Port forwarding 52553 > 52551 > 45479 stderr: Remote close with error [6658 ms] Port forwarding 52553 > 52551 > 45479 terminated with code 1 and signal null. [6659 ms] Port forwarding 52553 > 52551 > 45479: Local close [6662 ms] Start: 重新连接尝试 1 [6662 ms] Start: Run: docker inspect --type container 99af555a6e7f297fce36d4b15bf397d1a96963afcd06659c0df7c6c1c8f90ca1 [6670 ms] Port forwarding connection from 52562 > 52551 > 45479 in the container. [6670 ms] Start: Run in container: /root/.vscode-server/bin/0ee08df0cf4527e40edc9aa28f4b5bd38bbff2b2/node -e [6750 ms] Port forwarding 52562 > 52551 > 45479 stderr: Error: connect ECONNREFUSED 127.0.0.1:45479 at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1494:16) [6751 ms] Port forwarding 52562 > 52551 > 45479 stderr: Remote close with error [6755 ms] Port forwarding 52562 > 52551 > 45479 terminated with code 1 and signal null. [6755 ms] Port forwarding 52562 > 52551 > 45479: Local close [6766 ms] Port forwarding connection from 52563 > 52551 > 45479 in the container. [6766 ms] Start: Run in container: /root/.vscode-server/bin/0ee08df0cf4527e40edc9aa28f4b5bd38bbff2b2/node -e [6847 ms] Port forwarding 52563 > 52551 > 45479 stderr: Error: connect ECONNREFUSED 127.0.0.1:45479 at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1494:16) [6890 ms] Port forwarding 52563 > 52551 > 45479 stderr: Remote close with error [6890 ms] Port forwarding 52563 > 52551 > 45479 terminated with code 1 and signal null. [6891 ms] Port forwarding 52563 > 52551 > 45479: Local close [6895 ms] Start: 重新连接尝试 2 [6895 ms] Start: Run: docker inspect --type container 99af555a6e7f297fce36d4b15bf397d1a96963afcd06659c0df7c6c1c8f90ca1 [6902 ms] Port forwarding connection from 52564 > 52551 > 45479 in the container. [6902 ms] Start: Run in container: /root/.vscode-server/bin/0ee08df0cf4527e40edc9aa28f4b5bd38bbff2b2/node -e [6984 ms] Port forwarding 52564 > 52551 > 45479 stderr: Error: connect ECONNREFUSED 127.0.0.1:45479 at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1494:16) [6984 ms] Port forwarding 52564 > 52551 > 45479 stderr: Remote close with error [6988 ms] Port forwarding 52564 > 52551 > 45479 terminated with code 1 and signal null. [6989 ms] Port forwarding 52564 > 52551 > 45479: Local close [7000 ms] Port forwarding connection from 52567 > 52551 > 45479 in the container. [7001 ms] Start: Run in container: /root/.vscode-server/bin/0ee08df0cf4527e40edc9aa28f4b5bd38bbff2b2/node -e [7084 ms] Port forwarding 52567 > 52551 > 45479 stderr: Error: connect ECONNREFUSED 127.0.0.1:45479 at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1494:16) [7126 ms] Port forwarding 52567 > 52551 > 45479 stderr: Remote close with error [7126 ms] Port forwarding 52567 > 52551 > 45479 terminated with code 1 and signal null. [7127 ms] Port forwarding 52567 > 52551 > 45479: Local close [7131 ms] Start: 重新连接尝试 3 [7131 ms] Start: Run: docker inspect --type container 99af555a6e7f297fce36d4b15bf397d1a96963afcd06659c0df7c6c1c8f90ca1 [7138 ms] Port forwarding connection from 52568 > 52551 > 45479 in the container. [7138 ms] Start: Run in container: /root/.vscode-server/bin/0ee08df0cf4527e40edc9aa28f4b5bd38bbff2b2/node -e [7218 ms] Port forwarding 52568 > 52551 > 45479 stderr: Error: connect ECONNREFUSED 127.0.0.1:45479 at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1494:16) [7219 ms] Port forwarding 52568 > 52551 > 45479 stderr: Remote close with error [7223 ms] Port forwarding 52568 > 52551 > 45479 terminated with code 1 and signal null. [7224 ms] Port forwarding 52568 > 52551 > 45479: Local close [7234 ms] Port forwarding connection from 52572 > 52551 > 45479 in the container. [7235 ms] Start: Run in container: /root/.vscode-server/bin/0ee08df0cf4527e40edc9aa28f4b5bd38bbff2b2/node -e [7318 ms] Port forwarding 52572 > 52551 > 45479 stderr: Error: connect ECONNREFUSED 127.0.0.1:45479 at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1494:16) [7362 ms] Port forwarding 52572 > 52551 > 45479 stderr: Remote close with error [7362 ms] Port forwarding 52572 > 52551 > 45479 terminated with code 1 and signal null. [7362 ms] Port forwarding 52572 > 52551 > 45479: Local close [7367 ms] Start: 重新连接尝试 4 [7367 ms] Start: Run: docker inspect --type container 99af555a6e7f297fce36d4b15bf397d1a96963afcd06659c0df7c6c1c8f90ca1 [7374 ms] Port forwarding connection from 52573 > 52551 > 45479 in the container. [7374 ms] Start: Run in container: /root/.vscode-server/bin/0ee08df0cf4527e40edc9aa28f4b5bd38bbff2b2/node -e [7455 ms] Port forwarding 52573 > 52551 > 45479 stderr: Error: connect ECONNREFUSED 127.0.0.1:45479 at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1494:16) [7455 ms] Port forwarding 52573 > 52551 > 45479 stderr: Remote close with error [7459 ms] Port forwarding 52573 > 52551 > 45479 terminated with code 1 and signal null. [7460 ms] Port forwarding 52573 > 52551 > 45479: Local close [7471 ms] Port forwarding connection from 52574 > 52551 > 45479 in the container. [7471 ms] Start: Run in container: /root/.vscode-server/bin/0ee08df0cf4527e40edc9aa28f4b5bd38bbff2b2/node -e [7559 ms] Port forwarding 52574 > 52551 > 45479 stderr: Error: connect ECONNREFUSED 127.0.0.1:45479 at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1494:16) [7602 ms] Port forwarding 52574 > 52551 > 45479 stderr: Remote close with error [7602 ms] Port forwarding 52574 > 52551 > 45479 terminated with code 1 and signal null. [7603 ms] Port forwarding 52574 > 52551 > 45479: Local close [7615 ms] Port forwarding connection from 52575 > 52551 > 45479 in the container. [7616 ms] Start: Run in container: /root/.vscode-server/bin/0ee08df0cf4527e40edc9aa28f4b5bd38bbff2b2/node -e [7698 ms] Port forwarding 52575 > 52551 > 45479 stderr: Error: connect ECONNREFUSED 127.0.0.1:45479 at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1494:16) [7742 ms] Port forwarding 52575 > 52551 > 45479 stderr: Remote close with error [7742 ms] Port forwarding 52575 > 52551 > 45479 terminated with code 1 and signal null. [7743 ms] Port forwarding 52575 > 52551 > 45479: Local close ```

Anything else?

No response

chrmarti commented 11 months ago

Could you share the configuration of the two devcontainers? (devcontainer.json, Dockerfile, etc.)

yangkghjh commented 11 months ago

Two devcontainers cloned from same git repo, only difference in devcontainer.json is the name:

{
    "name": "vod",
    "image": "xxx:v1.0.3-1",
    "features": {
    },
    "mounts": [
        {
            "source": "/var/run/docker.sock",
            "target": "/var/run/docker.sock",
            "type": "bind"
        },
        {
            "source": "${env:HOME}/.kube",
            "target": "/root/.kube",
            "type": "bind"
        },
        {
            "source": "${env:HOME}/.ssh",
            "target": "/root/.ssh",
            "type": "bind"
        },
        {
            "source": "${env:REF}",
            "target": "${env:REF}",
            "type": "bind"
        },
        {
            "source": "media_build_zinit",
            "target": "/root/.local/share/zinit/",
            "type": "volume"
        },
        {
            "source": "media_build_go",
            "target": "/root/go",
            "type": "volume"
        },
        {
            "source": "media_build_vscode",
            "target": "/root/.vscode-server",
            "type": "volume"
        },
        {
            "source": "${localWorkspaceFolder}/.data",
            "target": "/data",
            "type": "bind"
        },
        {
            "source": "${localWorkspaceFolder}/.log",
            "target": "/var/log",
            "type": "bind"
        }
    ],
    "customizations": {
        "vscode": {
            "extensions": [
                "golang.go",
                "ms-vscode.cpptools",
                "ms-azuretools.vscode-docker",
                "ms-vscode.cpptools-themes",
                "github.copilot-labs",
                "eamodio.gitlens",
                "redhat.vscode-yaml",
                "ms-kubernetes-tools.vscode-kubernetes-tools",
                "ms-python.python",
                "qiumingge.cpp-check-lint",
                "github.copilot-nightly",
                "github.copilot-chat",
                "ibm.output-colorizer",
                "berublan.vscode-log-viewer"
            ]
        }
    },
    "containerEnv": {
        "GOPROXY": "https://goproxy.io,direct"
    }
}
vscodenpa commented 7 months ago

Hey @chrmarti, this issue might need further attention.

@yangkghjh, you can help us out by closing this issue if the problem no longer exists, or adding more information.

chrmarti commented 7 months ago

Are the two devcontainer.json files distinct or is it the same file with the name changed? The container belonging to a config file is identified by the devcontainer.json's path, so one of the two devcontainer.json files needs to go in a subfolder of the .devcontainer folder.

yangkghjh commented 7 months ago

Struct of two workspace:

.
├── ws1
│   ├── .devcontainer -> tools/.devcontainer
│   ├── mainrepo
│   └── tools
│       └── .devcontainer
└── ws2
    ├── .devcontainer -> tools/.devcontainer
    ├── mainrepo
    └── tools
        └── .devcontainer

FYI: I got around this issue by using docker-compose.

chrmarti commented 7 months ago

Where are the docker-compose.yml located? Do the two configurations end up using the same container? Does it work when you don't use symlinks?

vscodenpa commented 6 months ago

This issue has been closed automatically because it needs more information and has not had recent activity. See also our issue reporting guidelines.

Happy Coding!