I have been facing a strange issue with Docker Desktop on Windows 11 using the WSL2 backend. Whenever my laptop goes into sleep mode and wakes back up, the containers still appear as running, but the applications inside them stop responding properly. Browser requests start timing out, localhost ports stop working randomly, and communication between containers becomes unstable even though Docker itself does not fully crash.
The problem mostly happens with my Node.js development setup for a Morse code translator project that uses multiple containers together. I have a frontend container, backend API, and reverse proxy running at the same time. After the system resumes from sleep, hot reload stops working, WebSocket connections fail, and logs begin showing errors like ECONNRESET and proxy timeout issues. Restarting a single container usually does not help.
I checked Docker logs, Windows Event Viewer, and WSL status, but I could not find a clear explanation. Sometimes running wsl --shutdown and restarting Docker Desktop temporarily fixes the issue, but it eventually comes back after another sleep cycle. I also noticed the vmmemWSL process starts consuming very high CPU during this state, and Docker becomes slower than normal.
I tried several troubleshooting steps including reinstalling Docker Desktop, disabling resource saver mode, resetting Docker to factory defaults, recreating containers, and moving the project files into the Linux filesystem instead of the Windows filesystem. Performance improved slightly, but the networking issue still happens randomly after suspend or hibernation.
Another confusing thing is that this problem only happens on Windows with Docker Desktop and WSL2. I tested the same containers on a native Linux machine and everything worked normally even after sleep and resume cycles. That makes me think the issue could be related to WSL virtual networking or Windows power management rather than the containers themselves.
Has anyone else experienced Docker Desktop networking failures after Windows sleep mode while using WSL2? I would appreciate any suggestions related to Docker settings, WSL configuration, or Windows networking fixes that could make the containers stable after resume events.