Add basic site checks

This commit is contained in:
Salt 2021-08-08 12:35:35 -05:00
parent be7d1a24d6
commit caadf375f2

View File

@ -66,6 +66,35 @@ define service {
hostgroup_name nagios-checkhttp
}
# Manually-defined services for hosts
# web1.desu.ltd
{% for site in ["9iron.club","desu.ltd","nc.desu.ltd","git.desu.ltd"] %}
define service {
use ansible-generic-service
service_description HTTPS - {{ site }}
check_command check_http!--ssl -H {{ site }}
host_name web1.desu.ltd
}
{% endfor %}
# web2.desu.ltd
{% for site in ["cowfee.moe","tube.cowfee.moe"] %}
define service {
use ansible-generic-service
service_description HTTPS - {{ site }}
check_command check_http!--ssl -H {{ site }}
host_name web2.desu.ltd
}
{% endfor %}
# web3.desu.ltd
{% for site in ["netbox.desu.ltd","nagios.desu.ltd -e 401"] %}
define service {
use ansible-generic-service
service_description HTTPS - {{ site }}
check_command check_http!--ssl -H {{ site }}
host_name web3.desu.ltd
}
{% endfor %}
# Hostgroups
# Everything here is dynamically-generated based on tags from Netbox
{% for tag in query('netbox.netbox.nb_lookup', 'tags', api_endpoint='https://netbox.desu.ltd', token=netbox_token) %}