https://github.com/abeltramo/cloudflare-ddns-update
A simple bash script (and docker image) to automatically update Cloudflare DNS IP on a Dynamic DNS provider.
https://github.com/abeltramo/cloudflare-ddns-update
cloudflare-ddns cloudflare-dns-ip docker docker-image
Last synced: 2 months ago
JSON representation
A simple bash script (and docker image) to automatically update Cloudflare DNS IP on a Dynamic DNS provider.
- Host: GitHub
- URL: https://github.com/abeltramo/cloudflare-ddns-update
- Owner: ABeltramo
- Created: 2021-02-10T14:13:54.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2021-03-12T20:06:19.000Z (over 5 years ago)
- Last Synced: 2025-02-04T12:09:33.915Z (over 1 year ago)
- Topics: cloudflare-ddns, cloudflare-dns-ip, docker, docker-image
- Language: Shell
- Homepage:
- Size: 12.7 KB
- Stars: 3
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
[](https://hub.docker.com/repository/docker/abeltramo/cloudflare-ddns) [](https://hub.docker.com/repository/docker/abeltramo/cloudflare-ddns/tags?page=1&ordering=last_updated)
# Cloudflare DDNS update
Access your home network remotely via a custom domain name without a static IP!
A simple bash script to automatically update Cloudflare DNS IP on a [Dynamic DNS provider](https://www.cloudflare.com/en-gb/learning/dns/glossary/dynamic-dns/).
## Docker usage
A precompiled docker image is available on [Docker HUB](https://hub.docker.com/repository/docker/abeltramo/cloudflare-ddns). This is a multi-arch image and will run on amd64, aarch64, and armhf devices, including the Raspberry Pi.
```
docker run -d \
--name cloudflare-ddns \
--restart always \
-e "AUTH_EMAIL=asd@fgh.com" \
-e "AUTH_KEY=365....." \
-e "ZONE_IDENTIFIER=db....." \
-e "RECORD_NAME=example.com" \
abeltramo/cloudflare-ddns:latest
```
## Docker-compose
```yaml
services:
cloudflare-ddns:
container_name: cloudflare-ddns
image: abeltramo/cloudflare-ddns:latest
restart: always
environment:
- AUTH_EMAIL=asd@fgh.com
- AUTH_KEY=365.....
- ZONE_IDENTIFIER=db.....
- RECORD_NAME=example.com
- PROXIED=true #optional
```
## Environment variables
| Variable Name | Default value | Description |
|-----------------------|---------------|-----------------------------------------------------------------------------|
| AUTH_EMAIL | | The email used to login on Cloudflare |
| AUTH_KEY | | Global API key, found at: top right corner, "My profile" > "Global API Key" |
| ZONE_IDENTIFIER | | Can be found in the "Overview" tab of your domain |
| RECORD_NAME | | The full domain name to be updated |
| SLEEP_SECONDS | 900 | The interval in seconds between checks for changes in IP |
| PROXIED | false | Set to true to enable Cloudflare proxy protection |
| HEALTHCHECK_START_URL | | Set a URL to be called when the script start, used with healthchecks.io |
| HEALTHCHECK_END_URL | | Set a URL to be called when the script end, used with healthchecks.io |
| CURL_PARAMS | -sS --retry 3 | Change default CURL params, useful for debug, proxy, etc.. |