Commit da20f325 authored by Vitaly Lipatov's avatar Vitaly Lipatov

createbytask.int.sh: set correct mail in monit config

parent 567a551e
...@@ -20,6 +20,9 @@ assure $NAME ...@@ -20,6 +20,9 @@ assure $NAME
assure $AUSER assure $AUSER
assure $ACONF assure $ACONF
# TODO: external config
ADMINEMAIL=lav@etersoft.ru
# copied from nginx-etersoft's apache2 generating # copied from nginx-etersoft's apache2 generating
# new file -> old file # new file -> old file
rewrite_if_changed() rewrite_if_changed()
...@@ -122,8 +125,9 @@ check process httpd2 with pidfile /var/run/httpd2/httpd.pid ...@@ -122,8 +125,9 @@ check process httpd2 with pidfile /var/run/httpd2/httpd.pid
EOF EOF
subst "s|monit:secretword|monit:Dip74iFwwP12|g" /etc/monitrc subst "s|monit:secretword|monit:Dip74iFwwP12|g" /etc/monitrc
subst "s|set mailserver localhost|set mailserver mail.etersoft.ru port 587|g" /etc/monitrc subst "s|^set mailserver .*|set mailserver smtp.azbyka.ru port 587|g" /etc/monitrc
subst "s|set alert root@localhost|set alert lav@etersoft.ru|g" /etc/monitrc subst "s|set alert root@localhost.*|set alert $ADMINEMAIL|g" /etc/monitrc
subst "s|from: root@localhost|from: noreply+monit-$AUSER@azbyka.ru|g" /etc/monitrc
# only on { timeout, action, nonexist } # only on { timeout, action, nonexist }
subst "s|use address 127.0.0.1|use address 0.0.0.0|g" /etc/monitrc subst "s|use address 127.0.0.1|use address 0.0.0.0|g" /etc/monitrc
serv monit reload serv monit reload
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment