Skip to main content

Small collection of supervisor event listeners.

Project description

Supervisor Event Listeners
===================
A small collection of supervisor event listeners that weren't available in the awesome superlance.

fseventwatcher
---------------
$ fseventwatcher --help
usage: fseventwatcher [-h] [-p [PROGRAM [PROGRAM ...]]] [-a] -f PATH
[PATH ...] [-r]
[--watched-events [{moved,created,deleted,modified} [{moved,created,deleted,modified} ...]]]
[--dither DITHER_MAX]

Supervisor TICK event listener which restarts processes if file system changes
occur between ticks.

optional arguments:
-h, --help show this help message and exit
-p [PROGRAM [PROGRAM ...]], --programs [PROGRAM [PROGRAM ...]]
Supervisor process name/s to be restarted if in
RUNNING state.
-a, --any-program Restart any supervisor processes in RUNNING state.
-f PATH [PATH ...], --paths PATH [PATH ...]
Path to watch for file system events.
-r, --recursive Watch path/s recursively.
--watched-events [{moved,created,deleted,modified} [{moved,created,deleted,modified} ...]]
Specify which file system events to watch, by default
all events will be watched.
--dither DITHER_MAX Add dither before restarting processes. Specify
maximum time to dither in seconds.


eventexec
----------
$ eventexec --help
usage: eventexec [-h] -e COMMAND [-p [PROGRAM [PROGRAM ...]]] [-a]
[--dither DITHER_MAX]

Supervisor event listener which executes a command when events are received
and optionally restarts processes on non-zero exit status.

optional arguments:
-h, --help show this help message and exit
-e COMMAND, --execute COMMAND
Command or script to execute on supervisor events.
-p [PROGRAM [PROGRAM ...]], --restart-programs [PROGRAM [PROGRAM ...]]
Supervisor process name/s to be restarted on non-zero
exit status if in RUNNING state.
-a, --restart-any-program
Restart any supervisor processes in RUNNING state on
non-zero exit status.
--dither DITHER_MAX Add dither before restarting processes. Specify
maximum time to dither in seconds.

processrestarter
-----------------
processrestarter --help
usage: processrestarter [-h] [-p [PROGRAM [PROGRAM ...]]] [-a]
[--dither DITHER_MAX]

Supervisor event listener which restarts processes on TICK events.

optional arguments:
-h, --help show this help message and exit
-p [PROGRAM [PROGRAM ...]], --programs [PROGRAM [PROGRAM ...]]
Supervisor process name/s to be restarted if in
RUNNING state.
-a, --any-program Restart any supervisor processes in RUNNING state.
--dither DITHER_MAX Add dither before restarting processes. Specify
maximum time to dither in seconds.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

supervisor-event-listeners-0.0.1.tar.gz (3.9 kB view hashes)

Uploaded Source

Built Distribution

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page