Hi All, 

As I run scalr on a machine in my garage I came up with the following 
solution to sync dns changes within scalr to route 53. 

I'd imagine as some of you are far more 1337 than me there are better ways 
to do this but so far it works pretty well on my setup. 



Step 1 - Install cli53 >>>> https://github.com/barnybug/cli53

Step 2 - Create Update Script for whichever domain (this isn't a 
particularly clever or indeed error checking script, 

WARNING - I only have A records on your.domain.here which relate to scalr, 
no MX or anything so I purge all records.This will WIPE your current DNS 
config on route53 on whichever domain..... please use with caution...

#!/bin/bash
#

# Route 53 Updater Cron

# Quick purge / update

cli53 rrpurge --wait --confirm your.domain.here
cli53 import your.domain.here --file 
/path/to/scalr//namedb/your.domainzonefile.here.db



Step 3 - insert job into cron for however often you want to push updates. I 
use 5 mins. 



Now there are certainly better ways to do this, cli53 can list all domains 
amazon handles so you could check for the domain then create if necessary. 
Also you could run a loop to update all your.domainzones.here.db found in 
the named directories but I've not got the time! A good step would be to 
only update A records if there are changes between scalr and route53 but my 
bash skills are lacking. 

If anyone has improvements on this concept it could prove useful for 
people. Also I would probably steal it back. 

Kind regards, 

Dan






-- 
You received this message because you are subscribed to the Google Groups 
"scalr-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to