minitor/sample-config.yml

30 lines
979 B
YAML
Raw Normal View History

2018-02-16 02:10:19 +00:00
check_interval: 30
2018-02-15 01:54:42 +00:00
2018-02-14 23:37:15 +00:00
monitors:
2018-02-16 02:10:19 +00:00
- name: My Website
2018-07-16 00:30:01 +00:00
command: [ 'curl', '-s', '-o', '/dev/null', 'https://minitor.mon' ]
alert_down: [ log, mailgun_down, sms_down ]
alert_up: [ log, email_up ]
2018-02-16 02:10:19 +00:00
check_interval: 30
alert_after: 3
2018-02-18 04:45:37 +00:00
alert_every: -1 # Defaults to -1 for exponential backoff
2018-02-14 23:37:15 +00:00
alerts:
2018-07-16 00:30:01 +00:00
email_up:
command: [ sendmail, "me@minitor.mon", "Recovered: {monitor_name}", "We're back!" ]
mailgun_down:
2018-02-16 02:10:19 +00:00
command: >
curl -s -X POST
2018-02-17 01:49:33 +00:00
-F subject="Alert! {monitor_name} failed"
2018-02-16 02:10:19 +00:00
-F from="Minitor <minitor@minitor.mon>"
-F to=me@minitor.mon
-F text="Our monitor failed"
https://api.mailgun.net/v3/minitor.mon/messages
2018-02-17 01:49:33 +00:00
-u "api:${MAILGUN_API_KEY}"
2018-07-16 00:30:01 +00:00
sms_down:
2018-02-16 02:10:19 +00:00
command: >
curl -s -X POST -F "Body=Failure: {monitor_name} has failed"
-F "From=${AVAILABLE_NUMBER}" -F "To=${MY_PHONE}"
"https://api.twilio.com/2010-04-01/Accounts/${ACCOUNT_SID}/Messages"
-u "${ACCOUNT_SID}:${AUTH_TOKEN}"