Route 53 Dynamic DNS Update Client
Project description
r53ddns (Route 53 Dynamic DNS) is a simple command-line utility used to update an AWS Route 53 DNS entry with the current public IP Address of the executing host. Used to maintain DNS records which point to a dynamic address.
r53ddns utilizes the boto3 Python API to interface with AWS.
Usage
From the commandline or via systemd/cron service. A valid AWS credential file is required for the user executing the utility. This is typically placed in ~/.aws/credentials or the credentials may be specified using environment variables.
[default]
aws_access_key_id = ACCESSKEY-ID
aws_secret_access_key = SECRET-KEY
region = us-west-2
The user associated with the access key requires the following AWS permissions:
route53:ChangeResourceRecordSets
route53:ListResourceRecordSets
Optionally the following permission is required to permit SNS notifications (used with the –notify option or environment variable):
sns:Publish
An example AWS JSON Policy document might look like:
{
"Version": "2012-10-17",
"Statement": [
{
"Sid": "1",
"Effect": "Allow",
"Action": "sns:Publish",
"Resource": "arn:aws:sns:REGION:ACCT-NO:TOPIC-NAME"
},
{
"Sid": "2",
"Effect": "Allow",
"Action": [
"route53:ChangeResourceRecordSets",
"route53:ListResourceRecordSets"
],
"Resource": "arn:aws:route53:::hostedzone/ZONEID"
}
]
}
Note the Resource qualifiers should be replaced with valid Resource ARN’s if utilized.
Installation
Requirements:
Python >= 3.6.x
Using venv & pip
python3 -m venv venv
source venv/bin/activate
pip install dnsupdater
Installation as a daemon using Systemd
Create/install systemd service and timer unit files. .timer will execute the .service file periodically upon boot of the OS, and every 5 minutes thereafter.
[Unit]
Description=route53 dynamic dns update client
After=network.target
[Service]
Type=oneshot
User=awsuser
Environment="PATH=/opt/r53ddns/venv/bin"
ExecStart=/opt/r53ddns/venv/bin/dnsupdater
[Install]
WantedBy=network.target
[Unit]
Description=Execute r53ddns periodically
[Timer]
OnBootSec=1min
OnUnitActiveSec=5min
[Install]
WantedBy=timers.target
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file r53ddns-0.1.0b3.tar.gz.
File metadata
- Download URL: r53ddns-0.1.0b3.tar.gz
- Upload date:
- Size: 6.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.21.0 setuptools/39.1.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
041354ca897e584e2b9262c75e283009cf3e52dd31e9351e2615d8f53ad3515f
|
|
| MD5 |
990193aba73fdf20826d2813d20eb822
|
|
| BLAKE2b-256 |
4147eee2027f20b57645d9e91bae64a89a0f807dc3568b427757c6ac2967fa0a
|
File details
Details for the file r53ddns-0.1.0b3-py3-none-any.whl.
File metadata
- Download URL: r53ddns-0.1.0b3-py3-none-any.whl
- Upload date:
- Size: 11.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.21.0 setuptools/39.1.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c21424ef21a1a93bb6545fa863105ce29f425ac3435e48158aefbc1bd92c83fd
|
|
| MD5 |
087773e684ede44f7630d3994a9f611b
|
|
| BLAKE2b-256 |
228ed651e920951020032452475df8ad794ac8dcff52e118afd9b34bc0b1d393
|