1.0.0 • Published 8 years ago

supervisord-reactor v1.0.0

Weekly downloads
1
License
MIT
Repository
-
Last release
8 years ago

supervisord-reactor

Run command on supervisord events.

Why

I dont want to include everytime that example python app in my app

Install

npm i -g supervisord-reactor

Usage

[eventlistener:hciup]
events=PROCESS_STATE_RUNNING
command=supervisord-reactor --event PROCESS_STATE_RUNNING "curl slackhook?message=myapp%20is%20running"

Usecases

Make sure your bluetooth device is up

Unfortunately bluez 5 does not set hci devices to "up" state automatically but you need to do it manually (or use @reboot in cron).

[program:ble-app]
command=noble test.js

[eventlistener:hciup]
events=PROCESS_STATE_RUNNING
command=/usr/local/bin/supervisord-reactor --event "PROCESS_STATE_RUNNING" "hciconfig hci0 up"

License

MIT