From 81a698dabaff65a08ff2aacb43963017e026d33a Mon Sep 17 00:00:00 2001 From: Vince Tse Date: Sat, 23 Apr 2016 09:02:32 -0400 Subject: [PATCH] Allow zone detection of domains lower than 2nd level --- bin/route53-presence | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/route53-presence b/bin/route53-presence index 71c83cf..9cf370e 100755 --- a/bin/route53-presence +++ b/bin/route53-presence @@ -13,7 +13,7 @@ from boto.route53.record import ResourceRecordSets import requests def get_zone_id(hostname): - domainname = '.'.join(hostname.split('.')[-2:]) + domainname = '.'.join(hostname.split('.')[1:]) zone = conn.get_hosted_zone_by_name(domainname) if not zone: print "Sorry, you don't have access to that domain!"