mirror of
https://github.com/a-stoyanov/zabbix-domain-expiry.git
synced 2025-12-14 18:32:30 +00:00
Merge 9ee33efb6c into 9b8e1279fb
This commit is contained in:
commit
4f1b4bc428
1 changed files with 4 additions and 0 deletions
|
|
@ -217,6 +217,10 @@ run_whois() {
|
|||
$whois ${server:+-h $server} "$domain" > "$outfile" 2>&1 && error=$? || error=$?
|
||||
[ -s "$outfile" ] || die "$STATE_UNKNOWN" "State: UNKNOWN ; Domain $domain doesn't exist or no WHOIS server available."
|
||||
|
||||
if grep -qi "billing period had finished" "$outfile"; then
|
||||
die "$STATE_CRITICAL" "State: EXPIRED ; Domain is in billing grace period (already expired but renewable)"
|
||||
fi
|
||||
|
||||
if grep -q -e "No match for" -e "NOT FOUND" -e "NO DOMAIN" "$outfile"; then
|
||||
die "$STATE_UNKNOWN" "State: UNKNOWN ; Domain $domain doesn't exist."
|
||||
fi
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue