summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2014-02-03 11:54:55 -0200
committerSilvio Rhatto <rhatto@riseup.net>2014-02-03 11:54:55 -0200
commit239bea3a2b3fa9ebb0de7343d53dc420b57a8e3f (patch)
treebe8d6b8359047e6ba7c9830bcd20a6f85a162947
parent95198a8ccd422a4360907a76a24efabda17c51af (diff)
downloadpuppet-domain_check-239bea3a2b3fa9ebb0de7343d53dc420b57a8e3f.tar.gz
puppet-domain_check-239bea3a2b3fa9ebb0de7343d53dc420b57a8e3f.tar.bz2
Fix .org lookup
-rwxr-xr-xfiles/domain-check5
1 files changed, 4 insertions, 1 deletions
diff --git a/files/domain-check b/files/domain-check
index 89a39f8..ec5be77 100755
--- a/files/domain-check
+++ b/files/domain-check
@@ -301,7 +301,10 @@ check_domain_status()
# The whois Expiration data should resemble the following: "Expiration Date: 09-may-2008"
# for .in, .info, .org domains
- if [ "${TLDTYPE}" == "in" -o "${TLDTYPE}" == "info" -o "${TLDTYPE}" == "org" ];
+ if [ "${TLDTYPE}" == "org" ];
+ then
+ DOMAINDATE=`cat ${WHOIS_TMP} | ${AWK} '/Registry Expiry Date:/ { print $4 }' | cut -d':' -f2`
+ elif [ "${TLDTYPE}" == "in" -o "${TLDTYPE}" == "info" ];
then
DOMAINDATE=`cat ${WHOIS_TMP} | ${AWK} '/Expiration Date:/ { print $2 }' | cut -d':' -f2`
elif [ "${TLDTYPE}" == "biz" ]; # for .biz domain