26 lines
720 B
Bash
Executable File
26 lines
720 B
Bash
Executable File
#!/bin/bash
|
|
|
|
BIN_DIR=${BIN_DIR:-/usr/local/bin}
|
|
ETC_DIR=${ETC_DIR:-/usr/local/etc}
|
|
LIB_DIR=${LIB_DIR:-/usr/local/lib}
|
|
|
|
# Check host presents into zabbix
|
|
#/usr/local/bin/zabbix_create_host.sh
|
|
echo "Creating host into zabbix"
|
|
${BIN_DIR}/zabbix_create_host.sh
|
|
|
|
echo "Creating zabbix items for host"
|
|
# Get DNS records for all domain and send them into zabbix
|
|
#/usr/local/bin/zabbix_dns_records_check.sh read-json-discover
|
|
${BIN_DIR}/zabbix_dns_records_check.sh read-json-discover
|
|
|
|
echo "Getting DNS data"
|
|
|
|
DOMAIN_LIST=${DOMAIN_LIST:-"example1.com example1.org example3.ru"}
|
|
|
|
for LINE in ${DOMAIN_LIST}; do
|
|
#/usr/local/bin/zabbix_dns_records_check.sh $LINE
|
|
${BIN_DIR}/zabbix_dns_records_check.sh $LINE
|
|
done
|
|
|
|
sleep 600 |