Updated notify example script
This commit is contained in:
3
DraftNotify
Normal file
3
DraftNotify
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
##Custom notify
|
||||||
|
echo '#!/bin/sh' > /opt/MonitNotify.sh
|
||||||
|
echo 'curl "https://<gotifyurl>/message?token=<APIToken>" -F "title=[$MONIT_HOST] $1" -F "message=$MONIT_SERVICE $MONIT_DESCRIPTION" -F "priority=5"' >> /opt/MonitNotify.sh
|
||||||
20
draft
20
draft
@@ -1,20 +0,0 @@
|
|||||||
#genapplist
|
|
||||||
monit
|
|
||||||
#GenericConfig
|
|
||||||
if [ ! -d "/var/lib/monit" ] ; then mkdir -p /var/lib/monit; fi
|
|
||||||
|
|
||||||
|
|
||||||
if [ "$shortdist" = "ubu1804" ] || [ "$shortdist" = "ubu2004" ] || [ "$shortdist" = "deb10" ] ; then
|
|
||||||
monitconf=/etc/monit/monitrc
|
|
||||||
elif [ "$shortdist" = "el8" ]; then
|
|
||||||
monitconf=/etc/monitrc
|
|
||||||
rm -rf /etc/monit.d
|
|
||||||
fi
|
|
||||||
|
|
||||||
unset monitconf
|
|
||||||
mkdir -p /etc/monit/conf.d
|
|
||||||
|
|
||||||
|
|
||||||
##Custom notify
|
|
||||||
echo '#!/bin/sh' > /opt/MonitNotify.sh
|
|
||||||
echo 'curl "https://gass1.bprieshof.ovh/push/message?token=AwadzwYHS9lrHwo" -F "title=[$MONIT_HOST] $1" -F "message=$MONIT_SERVICE $MONIT_DESCRIPTION" -F "priority=5"' >> /opt/MonitNotify.sh
|
|
||||||
Reference in New Issue
Block a user