Add get-domain-status.py script, readme updates.

master
jowj 4 years ago
parent 8a143f7436
commit 9c5d75d5e4

@ -1,4 +1,16 @@
# right now there is not support for .club.
# this has been released on master, but hasn't been pushed to pypi yet.
# this is fucking stupid, but ok, lets just get it working for .net for now.
import whois
import datetime
whois.query('jowj.net')
whois.query('awful.club')
sites_to_check = [
'jowj.net',
]
current_year = datetime.datetime.today().year
for site in sites_to_check:
expire_year = whois.query(site).expiration_date.year
if expire_year - current_year <= 1:
pass # throw an alert, check into sending email / sending to slack

@ -16,6 +16,12 @@ using the whois package, get the status of my domains. send an email under the f
- the domain is < 90 days away from expiring
- the SSL is < 30 days away from expiring
### todo:
- [ ] wait until the .club tld support is merged in, add my other domains to the list of shit to check
- [ ] add SSL checking to the script
- [ ] add email / slack alerting to the script.
- [ ] eventually move this to the `arke` project so that its deployed to my servers and alerted on consistently
# DWIM naming history
dwim comes from someone in the history of LISP. i like the connotation of doing what /i/, in particular, mean, rather than the general 'try and figure out what i mean' that it has in history.

Loading…
Cancel
Save