Environment
Windows 11 Pro 22H2, Docker Desktop 4.15.1 using WSL2 backend. Project workspace located at C:\Users\alice\Projects\app and bind-mounted into containers with -v C:\Users\alice\Projects\app:/app. Windows Defender Controlled Folder Access (CFA) is enabled under corporate baseline.
Symptoms
Inside containers, processes fail to write files to the host bind mount with EACCES / 'permission denied' errors when creating logs/temp files. Reads are allowed. Host NTFS ACLs unchanged. Disabling Controlled Folder Access instantly restores write functionality.
Observations
Windows Defender event logs show 'Controlled folder access blocked' for processes com.docker.backend.exe and wslhost.exe attempting to write to protected folder. Adding 'Docker Desktop' as an allowed app intermittently fails after reboot; some helper binaries run from ephemeral paths so CFA blocks them unpredictably.
Already attempted
Tried resetting Docker Desktop, re-creating mounts, reinstalling Docker, and adding common Docker executables to CFA allowed list (docker-desktop.exe, com.docker.backend.exe). Allow-list entries do not persist for some helper processes. Moving project folder to C:\Projects temporarily resolves the issue.
Question
How can I safely allow containerized workloads to write to host folders without disabling CFA globally and avoid intermittent CFA blocking of Docker helper processes?
Verified community troubleshooting
No answers yet..
Incident analysis
Most likely causes
Summary
Suggested Fixes
Continue troubleshooting
Related troubles
Matched from the title, description and tags
- Servers28% match
After a kernel upgrade Docker containers get 'permission denied' writing to bind-mounted volumes (overlay2/overlayfs change)
Open0 answers - Linux23% match
Docker containers see config file permission change after editor 'atomic save' — bind-mounted file temporarily unreadable until container restart
Open0 answers - Windows20% match
WSL2 loses DNS name resolution when Windows connects to corporate VPN — works by IP only
Open1 answer