DDNS service for Route53 via Serverless and AWS Lambda
JavaScript
Permalink
Failed to load latest commit information.
.gitignore
LICENSE new project commit Jul 9, 2016
README.md
handler.js
serverless.env.yml upgrade to serverless 1.0 beta2 Sep 4, 2016
serverless.yml

README.md

Serverless Route53 DDNS Service

This is a serverless service that provides DDNS functionality for AWS Route53.

Serverless v1 does not yet support environment variables, so this service is not yet secure. Anyone with the right non-secret URL could use it to update your Dynamic DNS entries.

To use it, you need a Route53 hosted zone and an IAM role with access to update it. This policy works:

{
  "Version": "2012-10-17",
  "Statement": [
    {
      "Sid": "Stmt1468016031000",
      "Effect": "Allow",
      "Action": [
        "route53:ChangeResourceRecordSets"
      ],
      "Resource": [
        "arn:aws:route53:::hostedzone/ABCZONEID"
      ]
    }
  ]
}

Then all you need is a system on dynamic IP network to periodically call the function to update it. A cron job works fine for me:

30 * * * * /opt/bin/curl -q https://97r5k1bsn4.execute-api.us-east-1.amazonaws.com/dev/update?name=my.name.com&hosted_zone_id=ABCZONEID 2>&1 > /dev/null