Giter Club home page Giter Club logo

ddnser's Introduction

DDNSer

DDNSer a simple way to update DNS records with your current public IP address.

Supports the following DNS providers:

  • Cloudflare
  • More to come...

Prerequisites

  • Node
  • Yarn

Environment variables

Name Description Value
DDNSER_CRON_SCHEDULE If this is specified then the script will run according with the CRON specified (e.g. */5 * * * * for every 5 minutes) "" (optional)
CLOUDFLARE_API_BASE_URL Cloudflare API url https://api.cloudflare.com/client/v4
CLOUDFLARE_API_TOKEN The Cloudflare API token ""
CLOUDFLARE_DNS_ZONE_NAME The Cloudflare DNS zone name (e.g. example.com) ""
CLOUDFLARE_DNS_RECORD_NAMES The Cloudflare DNS record names (e.g. example.com\,*.example.com). The value is a comma-separated list of DNS records to update. You will also need to escape the commas with a backslash (\). ""

Building the Docker image

# Build & push the image
docker build --platform linux/amd64 -t ${YOUR_REGISTRY}/ddnser:${YOUR_CURRENT_VERSION} .
docker image push ${YOUR_REGISTRY}/ddnser:${YOUR_CURRENT_VERSION}

# Example:
# docker build --platform linux/arm64/v8 -t gamote/ddnser:0.0.4 .
# docker image push gamote/ddnser:0.0.4

To build for multiple platforms, you need to enable experimental features in Docker.

docker buildx create --use

# Build & push the image
docker buildx build --platform linux/amd64,linux/arm64 --push -t ${YOUR_REGISTRY}/ddnser:${YOUR_CURRENT_VERSION} .

# Example:
docker buildx build --platform linux/amd64,linux/arm64 --push -t gamote/ddnser:0.0.4 .

Running the Docker image

sudo docker run -d \
  --restart=unless-stopped \
  -e DDNSER_CRON_SCHEDULE="*/5 * * * *" \
  -e CLOUDFLARE_API_TOKEN="YOUR_KEY" \
  -e CLOUDFLARE_DNS_ZONE_NAME="domain.com" \
  -e CLOUDFLARE_DNS_RECORD_NAMES="domain.com" \
  --name=gamote_ddnser_cloudflare \
  gamote/ddnser:0.0.4

✨Roadmap

  • Add support for more DNS and Public IP providers
  • Add more documentation on how to use it and how to interact with providers
  • Provide recommendations, best practices for using this tool and mention limitations (e.g. possible rate limits, downtime, etc.)
  • Add more configuration options for the consumers
  • Build multi-arch Docker images
  • Add tests
  • Make the core a npm package and use it in the Helm chart
  • Improve versioning and release process
  • Mention that the secrets can also be provided via a .env file

ddnser's People

Contributors

gamote avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.