mirror of
https://github.com/fosrl/pangolin.git
synced 2026-07-17 07:04:36 -05:00
[GH-ISSUE #1225] Hot reload not working in Docker dev setup on Windows (WSL2) #31883
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @Pallavikumarimdb on GitHub (Aug 6, 2025).
Original GitHub issue: https://github.com/fosrl/pangolin/issues/1225
Description
When running the project on Windows, file changes in the local filesystem are not being detected properly, which causes issues with hot reload or other file-watching mechanisms.
Development Guide Says:

Environment
docker-composeCause
The problem is with WSL2 or native file system watchers inside Docker containers on Windows hosts.
📝 Suggested Fix
Update the project's
docker-compose.ymltemplate or provide guidance in the Development Guide for Windows users to add the following environment variables:It might slightly increase CPU usage, but for development only (not production), that’s fine.
@Pallavikumarimdb commented on GitHub (Aug 6, 2025):
@oschwartz10612 , Would you prefer updating the docker-compose.yml or should we instead document this in the Development Guide as a note for Windows users?
Happy to raise a PR based on your suggestion!
@marcschaeferger commented on GitHub (Aug 7, 2025):
@Pallavikumarimdb if all the files are located directly within the Docker WSL instance (prefered) (or another WSL instance), hot reload should work as expected. This issue typically arises due to the performance and compatibility limitations of file syncing between the Windows host and WSL2/Docker containers.
To streamline development, you can use Visual Studio Code (VSCode) to connect directly to a WSL instance. Either the "Remote - WSL" extension for VSCode or the "Remote - SSH" extension.
@Pallavikumarimdb commented on GitHub (Aug 8, 2025):
@marcschaeferger , thanks for the helpful insight! That makes sense — storing project files directly within the WSL2 instance and using VS Code's "Remote - WSL" extension would indeed avoid the need for polling.
It might be helpful to include both setup options (polling-based workaround and the recommended WSL setup) in the Development Guide for Windows users as a reference.
@marcschaeferger commented on GitHub (Aug 8, 2025):
@Pallavikumarimdb I'll update the documentation later today to include both setup options for Windows users. In the meantime, here (https://docs.docker.com/desktop/features/wsl/best-practices/) the official Docker recommendation regarding Windows and Docker hot reload/file change notification:
@oschwartz10612 commented on GitHub (Aug 16, 2025):
Closed by https://github.com/fosrl/docs-v2/pull/2 I think?