Skip to content

Instantly share code, notes, and snippets.

@ksatirli
Created September 9, 2017 16:05
Show Gist options
  • Save ksatirli/7edad2a430aa203beb7418240ee22c8c to your computer and use it in GitHub Desktop.
Save ksatirli/7edad2a430aa203beb7418240ee22c8c to your computer and use it in GitHub Desktop.
AWS: Route 53 Update Contact Details
#!/bin/bash
DOMAINS=(example.com example.net)
CONTACT="FirstName=Clifford,LastName=Smith,ContactType=COMPANY,OrganizationName=Method,AddressLine1=Sample Lane 123,City=Amsterdam,CountryCode=NL,ZipCode=1234 AB,PhoneNumber=+31.123456789,Email=clifford@withmethod.example"
for DOMAIN in "${DOMAINS[@]}"
do
echo "going to update domain ${DOMAIN}"
aws \
--region="us-east-1" \
--profile "withmethod" \
route53domains \
update-domain-contact \
--domain-name "${DOMAIN}" \
--admin-contact "${CONTACT}" \
--registrant-contact "${CONTACT}" \
--tech-contact "${CONTACT}"
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment