Windows Firewall is blocking my attempt to allows Docker for Windows to share C: on windows 10 machine.
Works fine when Windows Firewall off. When its on I get
I was not using any third party firewalls when running into this error. I was convinced it was a Windows Firewall issue, though disabling Windows Firewall did not work for me. I finally found this blog post after much research: Docker on windows 10 error: A firewall is blocking file Sharing ...
It ended up NOT having to do with the built in Windows Firewall.
The Fix
- Uncheck File and Printer Sharing for Microsoft Networks from the vEthernet (DockerNAT) network adapter (you can find the connection in the Windows Network and Sharing Center).
- Recheck it and make sure it is enabled.
As stated in one other answer Docker doesn't play nice with a VPN. If you're using Nordvpn you have to disable "Invisibility on LAN" and probably "Internet Kill Switch".
If you've done so it should work even with the VPN active.
In my case, I disabled "Block TCP 445" on Windows Defender Firewall with Advanced Security and it worked. Then enabled it again after setting shared drives on Docker.
I had same issue with F-secure, DeepGuard was blocking the Docker service. My solution was:
Open F-secure client and click "Tasks"
Choose "Allow a program to start"
Choose from list "com.docker.service" and press "Remove"
After that restart Docker client and try to apply for file share.
Also very good troubleshoot guide here: Error: A firewall is blocking file sharing between Windows and the containers
My G drive stopped being shared with Docker after a recent Windows 10 update. I was getting the same problem saying it was blocked by the Windows firewall when attempting to reshare it.
Then I had tried to solve this issues by couple of suggestion but i cant resolve that issue after that I have tried to Reset credentials below of Shared Drives and my issue was solved.
So If you want then you can try to do this-
Everything everyone posted DID NOT WORK for me.
THIS DID.
I installed the EDGE release. I then went to WINDOWS DEFENDER and disabled the firewall for DOCKER NAT. (not my actual ethernet adapter, just the docker nat)
Once I disabled windows defender/firewall THAT way it worked fine.
ugh. really hopes that helps some of you!