Watch files and translate the changes into salt events
depends: |
|
---|---|
Caution: |
Using generic mask options like open, access, ignored, and closed_nowrite with reactors can easily cause the reactor to loop on itself. To mitigate this behavior, consider setting the disable_during_state_run flag to True in the beacon configuration. |
note: |
The inotify beacon only works on OSes that have inotify kernel support. |
Watch the configured files
Example Config
beacons: inotify: - files: /path/to/file/or/dir: mask: - open - create - close_write recurse: True auto_add: True exclude: - /path/to/file/or/dir/exclude1 - /path/to/file/or/dir/exclude2 - /path/to/file/or/dir/regex[a-m]*$: regex: True - coalesce: True
The mask list can contain the following events (the default mask is create, delete, and modify):
The mask can also contain the following options:
Validate the beacon configuration
© 2019 SaltStack.
Licensed under the Apache License, Version 2.0.
https://docs.saltstack.com/en/latest/ref/beacons/all/salt.beacons.inotify.html