Direct DDNS from Synology to Cloudflare.
This script is designed to run under the task scheduler that comes with Synology NAS DDNS. It uses API calls to update a DNS record directly on Cloudflare. It has been tested on DS918 running DSM 7.2.
- Configured via management
- No external scripts
- No third party sites
- No command line changes
- No other dependancies
Cloudflare provide instructions on how to implement DDNS directly with API calls here. This is script implements that interface.
Fork the respository and raise an issue. Then commit your changes and refer to the PR in the issue.
- Currently active DNS domain hosted on Cloudflare
- Zone API Key (instructions below)
- Zone ID (instructions below)
- DDNS record (instructions below)
This updates a Cloudflare DNS record with the current public IP address if it has changed. It does this by storing the last IP update in /tmp/nasip.txt and checking it each time it runs.
It exits with an error status on any API/Task error OR the IP address has changed. This should trigger an email to the admin with the details of the error OR notifying them the IP address has changed. No IP changes means their are no notifications.
Read the pre-installation steps to prepare for task installation. These steps are mandatory
Read the installation guide to deploy the DDNS on your Sydnology NAS.
Please follow the testing steps after the install to ensure it is working as expected.
If you cannot resolve the problem raise an issue in Github or in the discussion thread on Synology website.