docker / for-win

Bug reports for Docker Desktop for Windows
https://www.docker.com/products/docker#/windows
1.86k stars 289 forks source link

WSL bind mount point fails to render files using HTTP service ... #13453

Closed ghost closed 1 year ago

ghost commented 1 year ago

Actual behavior

On Windows 10 Professional latest version + latest WSL2 version (wsl --upgrade). I am using the default WSL distro.

docker run --rm --name nginx-test -v "%CD%"/tmp:/usr/share/nginx/html:rw -p 8080:80 -d nginx Using any browser (Chrome latest to date), returns "403 Forbidden".

I check the directory and file permissions internal to the Linux mount point (755).

This exact configuration works on MacOS and Linux without a problem -- essentially, I can see a file listing in the /usr/share/nginx/html directory.

It looks like it's a bind mount problem/configuration.

Expected behavior

I should simply see a directory listing of my of the file contents in the /usr/share/nginx/html.

Information

Output of & "C:\Program Files\Docker\Docker\resources\com.docker.diagnose.exe" check

Steps to reproduce the behavior

  1. Pretty simple: docker run --rm --name nginx-test -v "%CD%"/tmp:/usr/share/nginx/html:rw -p 8080:80 -d nginx
  2. Use a browser to hit http://localhost:8080/

    [2023-05-11T03:48:00.636157400Z][com.docker.diagnose.exe][I] set path configuration to OnHost Starting diagnostics

[PASS] DD0027: is there available disk space on the host? [PASS] DD0028: is there available VM disk space? [SKIP] DD0002: does the bootloader have virtualization enabled? [SKIP] DD0018: does the host support virtualization? [PASS] DD0001: is the application running? [SKIP] DD0022: is the Virtual Machine Platform Windows Feature enabled? [SKIP] DD0021: is the WSL 2 Windows Feature enabled? [PASS] DD0024: is WSL installed? [PASS] DD0025: are WSL distros installed? [PASS] DD0026: is the WSL LxssManager service running? [PASS] DD0029: is the WSL 2 Linux filesystem corrupt? [PASS] DD0035: is the VM time synchronized? [PASS] DD0017: can a VM be started? [PASS] DD0016: is the LinuxKit VM running? [PASS] DD0011: are the LinuxKit services running? [PASS] DD0004: is the Docker engine running? [PASS] DD0015: are the binary symlinks installed? [PASS] DD0031: does the Docker API work? [PASS] DD0013: is the $PATH ok? [PASS] DD0003: is the Docker CLI working? [PASS] DD0005: is the user in the docker-users group? [PASS] DD0038: is the connection to Docker working? [FAIL] DD0014: are the backend processes running? 1 error occurred:

[PASS] DD0007: is the backend responding? [PASS] DD0008: is the native API responding? [FAIL] DD0009: is the vpnkit API responding? open \.\pipe\dockerVpnKitDiagnostics: The system cannot find the file specified. [PASS] DD0010: is the Docker API proxy responding? [SKIP] DD0006: is the Docker Desktop Service responding? [SKIP] DD0030: is the image access management authorized? [PASS] DD0033: does the host have Internet access? [PASS] DD0002: does the bootloader have virtualization enabled? [PASS] DD0018: does the host support virtualization? [PASS] DD0001: is the application running? [PASS] DD0022: is the Virtual Machine Platform Windows Feature enabled? [PASS] DD0021: is the WSL 2 Windows Feature enabled? [PASS] DD0024: is WSL installed? [PASS] DD0025: are WSL distros installed? [PASS] DD0026: is the WSL LxssManager service running? [PASS] DD0029: is the WSL 2 Linux filesystem corrupt? [PASS] DD0035: is the VM time synchronized? [PASS] DD0017: can a VM be started? [PASS] DD0016: is the LinuxKit VM running? [PASS] DD0011: are the LinuxKit services running? [PASS] DD0004: is the Docker engine running? [PASS] DD0015: are the binary symlinks installed? [PASS] DD0031: does the Docker API work? [PASS] DD0032: do Docker networks overlap with host IPs?

Please investigate the following 1 issue:

1 : The test: are the backend processes running? Failed with: 1 error occurred:

Not all of the backend processes are running.

ghost commented 1 year ago

We've given up on Docker Desktop for Windows. It's buggy and unstable (probably due to DD/MS WSL2 issues). We are now opting to configure Docker for WSL2 instead. So, I will be closing this issue as a result.

https://nickjanetakis.com/blog/install-docker-in-wsl-2-without-docker-desktop