Building Containers in vscode causes problems with binding workspaces

host: W11
vscode: 1.85.1 (system setup)
dev containers: 0.327.0
Docker: 4.62.1
WSL2: 2.0.14.0
Ubuntu 22.04 backend

I am trying to build a devcontainer in vscode and I keep getting an error that my workspace does not exist when building my container. I think it has something to do with line in the log file:

[746 ms] Setting up container for folder or workspace: /mnt/wsl/docker-desktop-bind-mounts/Ubuntu-22.04/73478a00ab3a41eea6f3a5cbb393aa4ce6f4b96cc3118588be772b259b2d659d

And then I have this in my vscode file explorer
image

wsl seems to be creating a random directory and trying to mount the directory. I am not sure why this is happening

Steps to reproduce:

  1. start docker desktop
  2. open a devcontainer in vscode
  3. have “Execute in WSL” select in dev container setting selected
  4. hit reopen in dev container

Excepted Behavior’s
The directory reopens in its container with a workspace named as the directory

I am not sure what is causing this issue, if it is WSL, Docker, VScode. All three, does anyone know what could be causing this issue?

1 Like