Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/toddrob99/dh-dns
DreamHost DNS Updater (no longer maintained)
https://github.com/toddrob99/dh-dns
dns dreamhost dreamhost-api dynamic-dns prowl prowl-notifications python python3
Last synced: 3 days ago
JSON representation
DreamHost DNS Updater (no longer maintained)
- Host: GitHub
- URL: https://github.com/toddrob99/dh-dns
- Owner: toddrob99
- License: gpl-3.0
- Created: 2018-05-20T15:07:04.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2020-04-11T01:08:52.000Z (over 4 years ago)
- Last Synced: 2024-11-18T03:41:16.925Z (about 1 month ago)
- Topics: dns, dreamhost, dreamhost-api, dynamic-dns, prowl, prowl-notifications, python, python3
- Language: Python
- Homepage:
- Size: 24.4 KB
- Stars: 0
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# dh-dns
DreamHost DNS UpdaterThis project is intended to simulate dynamic DNS for DreamHost customers. It will monitor the specified domains on your DreamHost account and keep them updated when your IP public changes.
The current version support IPv4 only.
### Configuration
* Generate an API key here: https://panel.dreamhost.com/?tree=home.api
* I suggest giving access only to the DNS functions (all 3 are required)
* Paste the API key at the top of dh-dns.py (`API_KEY = "YOUR_API_KEY_GOES_HERE"`)
* Update the `DOMAINS` list at the top of dh-dns.py with the domains you want to monitor (`DOMAINS = ["dyn.example.com","test.example.com"]`)
* Update the `COMMENT` if you wish. This will be added to the DNS records if not blank (`COMMENT = "Last updated by dh-dns: {date}"`)
* Update `UPDATE_INTERVAL` if you wish to update more or less frequently. Default is 60 minutes (`UPDATE_INTERVAL = 60`)
* Update `LOG_LEVEL` if you wish to log more or less info. Available options are `WARNING`, `INFO`, `DEBUG` and each will give more info than the last (`LOG_LEVEL = "INFO"`)### Running
* Install Python (written for Python 3.5+ as of v1.4, might not work properly with earlier versions)
* Install dependent modules:
* `pip install pyprowl`
* `pip install IPy`
* `pip install requests`
* I run this on my Synology NAS as a scheduled task (at system start), using `dh-dns.sh` as the startup script### Issues/Questions/Suggestions
* Feel free to post an issue on GitHub
* If you have questions or suggestions, message me on reddit (/u/toddrob), or email me (todd at toddrob.com)### Changelog
#### v1.4
* Updated to run on Python 3.5+
* Added support for `flake8` linting and `black` formatting
* Removed `simplejson` and `urllib2` dependencies, replaced with `requests`
* Removed `Prowl` class in favor of `pyprowl` module
* Updated to use `api.ipify.org` to get current public IP#### v1.2
* Added support for Prowl notifications
* Moved dh-dns.log to logs directory, set weekly log file rotation with retention of 3 previous files (via `Logger` class)
* Add `IPy` and `simplejson` dependency installs to `dh-dns.sh` startup script#### v1.1
* Check individual domains even if last known IP matches newly-detected IP. That way if an update failed last time around, it will try again.
* Improved logging
* Added dh-dns.sh to run as a daemon on Linux (I use it on Synology)
* Updated README