mirror of
https://github.com/samuelclay/NewsBlur.git
synced 2025-04-13 09:42:01 +00:00
Adding monit for work server.
This commit is contained in:
parent
7ae3692957
commit
a79d0fa6be
2 changed files with 17 additions and 0 deletions
12
config/monit_work.conf
Normal file
12
config/monit_work.conf
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
set daemon 120
|
||||||
|
|
||||||
|
set logfile /var/log/monit.log
|
||||||
|
|
||||||
|
set eventqueue
|
||||||
|
basedir /var/monit # set the base directory where events will be stored
|
||||||
|
slots 100 # optionally limit the queue size
|
||||||
|
|
||||||
|
# If no feeds have been queued in the last minute, something is wrong
|
||||||
|
check file newsblur.log with path /srv/newsblur/logs/newsblur.log
|
||||||
|
if timestamp > 2 minutes then exec "/usr/bin/supervisorctl reload"
|
||||||
|
as uid root and gid root
|
5
fabfile.py
vendored
5
fabfile.py
vendored
|
@ -476,6 +476,11 @@ def config_monit_app():
|
||||||
sudo('echo "START=yes" > /etc/default/monit')
|
sudo('echo "START=yes" > /etc/default/monit')
|
||||||
sudo('/etc/init.d/monit restart')
|
sudo('/etc/init.d/monit restart')
|
||||||
|
|
||||||
|
def config_monit_work():
|
||||||
|
put('config/monit_work.conf', '/etc/monit/conf.d/work.conf', use_sudo=True)
|
||||||
|
sudo('echo "START=yes" > /etc/default/monit')
|
||||||
|
sudo('/etc/init.d/monit restart')
|
||||||
|
|
||||||
def config_monit_redis():
|
def config_monit_redis():
|
||||||
sudo('chown root.root /etc/init.d/redis')
|
sudo('chown root.root /etc/init.d/redis')
|
||||||
sudo('chmod a+x /etc/init.d/redis')
|
sudo('chmod a+x /etc/init.d/redis')
|
||||||
|
|
Loading…
Add table
Reference in a new issue