inotify with NFS

后端 未结 5 1000
忘了有多久
忘了有多久 2020-11-27 03:25

I\'ve recently created a dropbox system using inotify, watching for files created in a particular directory. The directory I\'m watching is mounted from an NFS server, and i

5条回答
  •  囚心锁ツ
    2020-11-27 03:31

    To anyone who has come across this question in the search for an answer of why bind mounting on Docker will not detect file changes from host directory (for hot reloading of an app), it's because the propagation of file changes between host and container is not communicated to the container kernel.

    Only changes from the container itself is communicated to the kernel. Solution for this is to have your live reload utility turn on "polling mode" instead of using fsnotify.

提交回复
热议问题