Skip to content

Instantly share code, notes, and snippets.

View LeSpocky's full-sized avatar

Alexander Dahl LeSpocky

View GitHub Profile
@LeSpocky
LeSpocky / check-domain-connect.sh
Last active December 17, 2015 08:49
Little shell script to check if a domain is still connected. Run with cron job!
#!/bin/sh
if whois $1 | grep -i status | grep -q connect
then
echo "$1 still connected" >/dev/null
else
echo "*** The domain $1 is not connected! ***"
fi
changed=$(whois $1 | grep -i changed)
old_changed=$(cat ~/var/domain_changed_${1})