diff --git a/docker-configs/supervisord.conf b/docker-configs/supervisord.conf index 90622dd..6d719c4 100644 --- a/docker-configs/supervisord.conf +++ b/docker-configs/supervisord.conf @@ -11,6 +11,7 @@ redirect_stderr=true command=python /opt/freedmr/bridge_master.py -c freedmr.cfg stopwaitsecs=30 autorestart=true +priority=2 [program:proxy] stdout_logfile=/dev/fd/1 @@ -19,6 +20,7 @@ redirect_stderr=true command=python /opt/freedmr/hotspot_proxy_v2.py stopwaitsecs=30 autorestart=true +priority=1 [program:playback] stdout_logfile=/dev/fd/1 @@ -26,3 +28,4 @@ stdout_logfile_maxbytes=0 redirect_stderr=true command=/opt/freedmr/playback.py -c loro.cfg autorestart=true +priority=3 diff --git a/hotspot_proxy_v2.py b/hotspot_proxy_v2.py index e840530..ba9f5a4 100644 --- a/hotspot_proxy_v2.py +++ b/hotspot_proxy_v2.py @@ -26,6 +26,7 @@ import os from setproctitle import setproctitle from datetime import datetime import Pyro5.api +import signal # Does anybody read this stuff? There's a PEP somewhere that says I should do this. __author__ = 'Simon Adlem - G7RZU' @@ -363,8 +364,8 @@ if __name__ == '__main__': reactor.stop() #Install signal handlers - signal.signal(signal.SIGTERM, sig_handler) signal.signal(signal.SIGINT, sig_handler) + signal.signal(signal.SIGTERM, sig_handler) #readState()