This is a pre-production deployment of Warehouse, however changes made here WILL affect the production instance of PyPI.
Latest Version Dependencies status unknown Test status unknown Test coverage unknown
Project Description

Overview

A low-cost, dynamic-DNS client using Amazon’s Route53 (currently $.50/zone).

Based on code from How and why I’m not running my own DNS.

Installation

Use PyPI:

$ sudo pip install awsdd

Prerequisites

You must already have an A-record for your domain name in the Route53 zone. In order to be able to remove the record, prior to creating a new one (if the IP has changed), we need to know the TTL value of the current record, which is used by the boto library to identify the current record.

If you see the following error, it might mean that the TTL disagreed from our default:

boto.route53.exception.DNSServerError: DNSServerError: 400 Bad Request
<?xml version="1.0"?>
<ErrorResponse xmlns="https://route53.amazonaws.com/doc/2013-04-01/"><Error><Type>Sender</Type><Code>InvalidChangeBatch</Code><Message>Tried to delete resource record set [name='dustinhome.us.', type='A'] but the values provided do not match the current values</Message></Error><RequestId>be44faea-f41c-11e3-a846-5921f19aa715</RequestId></ErrorResponse>

In this case, try looking-up your current TTL value in the Route53 console, and setting it into the ADD_OLD_TTL environment variable.

Settings

awsdd needs your AWS API credentials, the zone-ID, and the domain name that you’re updating. All of these things can either be defined as environment variables or passed as command-line parameters. Our convention is to provide the AWS credentials via the environment (which is common), and pass the rest as parameters.

The command-line parameters can be found via command-line help. The supported environment variables are these, and shouldn’t need an explanation:

  • USER_DOMAIN
  • ZONE_ID
  • ACCESS_KEY_ID
  • SECRET_ACCESS_KEY

Usage

It’s straight-forward. Just pass it the right information:

$ ADD_ACCESS_KEY_ID=XXXXXXXXXX ADD_SECRET_ACCESS_KEY=YYYYYYYYYY awsdd -d <domain name> -z <zone ID>

Scheduling

There are a lot of different ways to choose how to get the configuration values into awsdd and some people might also have different preferences for how often it runs. So, we leave it to the user to schedule it into Cron.

For your convenience, this is an example of such a job, which updates every four hours:

0 */4 * * * /usr/local/bin/awsdd -d <domain name> -z <zone ID> -a <access key> -s <secret key>

NOTE: The command was previously called “add_update”. As seen here, it has been renamed to “awsdd”.

Debugging

By setting the DEBUG environment variable to “1”, you’ll get some more verbosity:

2014-06-14 19:46:47,057 - add.aws - DEBUG - Updating DNS for domain [ddd.eee].
2014-06-14 19:46:47,057 - add.aws - DEBUG - Fetching current IP.
2014-06-14 19:46:47,077 - requests.packages.urllib3.connectionpool - INFO - Starting new HTTP connection (1): wtfismyip.com
2014-06-14 19:46:47,281 - requests.packages.urllib3.connectionpool - DEBUG - "GET /text HTTP/1.1" 200 13
2014-06-14 19:46:47,281 - add.aws - DEBUG - Current IP: [49.139.31.75]
2014-06-14 19:46:47,581 - add.aws - DEBUG - Current DNS value: [1.2.3.4]
2014-06-14 19:46:47,716 - add.aws - INFO - IP update complete.
Release History

Release History

0.2.3

This version

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.2.2

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.2.1

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.2.0

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

Download Files

Download Files

TODO: Brief introduction on what you do with files - including link to relevant help section.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
awsdd-0.2.3-py2-none-any.whl (13.6 kB) Copy SHA256 Checksum SHA256 2.7 Wheel Jun 15, 2014
awsdd-0.2.3.tar.gz (4.7 kB) Copy SHA256 Checksum SHA256 Source Jun 15, 2014

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS HPE HPE Development Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting