docker-windows-volume-watcher icon indicating copy to clipboard operation
docker-windows-volume-watcher copied to clipboard

Only "attrib" event is ever sent to inotify

Open aawilson opened this issue 7 years ago • 3 comments

I know this is probably inherent in using "stat" and "chmod" as the propagation technique, but the point stands. It would be nice if events like close_write, modify and so forth could be distinguished.

aawilson avatar Nov 14 '17 22:11 aawilson

Sidenote, this seems to double-up the events, meaning that a single file-save is sending "attrib" twice to the notifier.

aawilson avatar Nov 14 '17 22:11 aawilson

Hi @aawilson , sorry for such a huge delay with response (I'm currently use Windows extremly rarely, but finally got some time to look into this).

I'm currently not aware about any feasible way to send modify inotify event to container. However, we can forward close_write event with help of touch instead of chmod (unfortunately this will require introduction of short timeout to prevent event loop, so this approach feels very hacky to me). Could you suggest any better way to deal with this issues?

Considering your sidenote. Do you meen events double-up for file save made from container or from host? I confirm this issue for file save made from container. But I can't reproduce it when I watch file with inotifywait -m from container and modify it with notepad (or notepad++, or Atom) from Windows host. Could you provide more details about your setup?

merofeev avatar Dec 26 '17 19:12 merofeev

It's been a while and I abandoned this approach, so I'll have to poke around again to try to reproduce, let's see where I get.

aawilson avatar Dec 27 '17 15:12 aawilson