Skip to content

rohit267/cloudflare-ddns-updater

Repository files navigation

Cloudflare DNS Updater

Simple Node.js Service will update your Cloudflare DNS records whenever your IP Adreess changes. It will check for your ip address in Cloudflare and your current ip and update it as provied in fixed intervals.

Features:

  • Supports both IPv4 (A) & IPv6 (AAAA).
  • Depends on https://cloudflare.com/cdn-cgi/trace & https://www.ipify.org/

Star History

Star History Chart

Usage:

Make a config.json file with all info (in root dir of app).

{
    "auth":{
        // Create a token with Edit DNS permission: https://developers.cloudflare.com/fundamentals/api/get-started/create-token/
        "token":"CLOUDFLARE_AUTH_TOKEN",
        "email": "CLOUDFLARE_EMAIL"
    },
    "records": [
        {
            "name":"example.com",
            "type":"A",
            "proxied":false,
            // Open a domain, the ZoneId should be visible on the right panel
            "zoneId":"ZONE_ID_OF_DOMAIN"
        }
    ],
}

Docker Compose

version: '3'

services:
  cloudflare-updater:
    image: ghcr.io/rohit267/cloudflare-node-ddns:latest
    container_name: cloudflare-updater
    restart: unless-stopped
    volumes:
      - ./config.json:/app/config.json
    network_mode: "host"

About

Dynamic DNS using Cloudflare DNS

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages