-
Notifications
You must be signed in to change notification settings - Fork 5.7k
Open
Labels
Description
Description
In my Windows 11 Pro 24H2 the CLI command docker run -it --name ub -v ./work-folder:/etc/app/workFolder ubuntu bash is working on any other terminals like powershell/cmd/Ubuntu (wsl) but behaving abnormal while executed in Git Bash.
Executing the command in Git Bash:
- Creates a folder named
work-folder;Cin current working dir of host machine - Mounts the dir named
\Program Files\Git\etc\app\workFolderbut in root dir of the container machine
Steps To Reproduce
- In Windows 11 Pro 24H2 with Git Bash and docker desktop installed
- Open any dir and open Git Bash in it
- run the docker CLI command
docker run -it --name ub -v ./work-folder:/etc/app/workFolder ubuntu bashin Git Bash - You will see the folder named
work-folder;Cis created in current working dir and mounted the folder in root dir of container named'\Program Files\Git\etc\app\workFolder'
Compose Version
Docker Compose version v2.40.3-desktop.1
Docker Environment
Client:
Version: 29.1.3
Context: desktop-linux
Debug Mode: false
Plugins:
ai: Docker AI Agent - Ask Gordon (Docker Inc.)
Version: v1.17.1
Path: C:\Program Files\Docker\cli-plugins\docker-ai.exe
buildx: Docker Buildx (Docker Inc.)
Version: v0.30.1-desktop.1
Path: C:\Program Files\Docker\cli-plugins\docker-buildx.exe
compose: Docker Compose (Docker Inc.)
Version: v2.40.3-desktop.1
Path: C:\Program Files\Docker\cli-plugins\docker-compose.exe
debug: Get a shell into any image or container (Docker Inc.)
Version: 0.0.45
Path: C:\Program Files\Docker\cli-plugins\docker-debug.exe
desktop: Docker Desktop commands (Docker Inc.)
Version: v0.2.0
Path: C:\Program Files\Docker\cli-plugins\docker-desktop.exe
extension: Manages Docker extensions (Docker Inc.)
Version: v0.2.31
Path: C:\Program Files\Docker\cli-plugins\docker-extension.exe
init: Creates Docker-related starter files for your project (Docker Inc.)
Version: v1.4.0
Path: C:\Program Files\Docker\cli-plugins\docker-init.exe
mcp: Docker MCP Plugin (Docker Inc.)
Version: v0.34.0
Path: C:\Program Files\Docker\cli-plugins\docker-mcp.exe
model: Docker Model Runner (Docker Inc.)
Version: v1.0.2
Path: C:\Program Files\Docker\cli-plugins\docker-model.exe
offload: Docker Offload (Docker Inc.)
Version: v0.5.33
Path: C:\Program Files\Docker\cli-plugins\docker-offload.exe
pass: Docker Pass Secrets Manager Plugin (beta) (Docker Inc.)
Version: v0.0.21
Path: C:\Program Files\Docker\cli-plugins\docker-pass.exe
sandbox: Docker Sandbox (Docker Inc.)
Version: v0.6.0
Path: C:\Program Files\Docker\cli-plugins\docker-sandbox.exe
sbom: View the packaged-based Software Bill Of Materials (SBOM) for an image (Anchore Inc.)
Version: 0.6.0
Path: C:\Program Files\Docker\cli-plugins\docker-sbom.exe
scout: Docker Scout (Docker Inc.)
Version: v1.18.3
Path: C:\Program Files\Docker\cli-plugins\docker-scout.exe
Server:
Containers: 5
Running: 0
Paused: 0
Stopped: 5
Images: 6
Server Version: 29.1.3
Storage Driver: overlayfs
driver-type: io.containerd.snapshotter.v1
Logging Driver: json-file
Cgroup Driver: cgroupfs
Cgroup Version: 2
Plugins:
Volume: local
Network: bridge host ipvlan macvlan null overlay
Log: awslogs fluentd gcplogs gelf journald json-file local splunk syslog
CDI spec directories:
/etc/cdi
/var/run/cdi
Discovered Devices:
cdi: docker.com/gpu=webgpu
Swarm: inactive
Runtimes: io.containerd.runc.v2 nvidia runc
Default Runtime: runc
Init Binary: docker-init
containerd version: 1c4457e00facac03ce1d75f7b6777a7a851e5c41
runc version: v1.3.4-0-gd6d73eb8
init version: de40ad0
Security Options:
seccomp
Profile: builtin
cgroupns
Kernel Version: 6.6.87.2-microsoft-standard-WSL2
Operating System: Docker Desktop
OSType: linux
Architecture: x86_64
CPUs: 4
Total Memory: 7.698GiB
Name: docker-desktop
ID: 9a2542e7-7d82-4735-bd08-df846aac428e
Docker Root Dir: /var/lib/docker
Debug Mode: false
HTTP Proxy: http.docker.internal:3128
HTTPS Proxy: http.docker.internal:3128
No Proxy: hubproxy.docker.internal
Labels:
com.docker.desktop.address=npipe://\\.\pipe\docker_cli
Experimental: false
Insecure Registries:
hubproxy.docker.internal:5555
::1/128
127.0.0.0/8
Live Restore Enabled: false
Firewall Backend: iptable
Anything else?
Tried this configuration also with docker-compose.yaml but didn't work.