All Projects → thatjpk → Cloudflare Ddns

thatjpk / Cloudflare Ddns

Licence: bsd-3-clause
Script for dynamically updating a CloudFlare DNS record. (Deprecated)

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to Cloudflare Ddns

Warp Plus Cloudflare
Script for getting unlimited GB on Warp+ ( https://1.1.1.1/ )
Stars: ✭ 381 (+240.18%)
Mutual labels:  dns, cloudflare
Sooty
The SOC Analysts all-in-one CLI tool to automate and speed up workflow.
Stars: ✭ 867 (+674.11%)
Mutual labels:  automation, dns
Encrypted Dns
Configuration profiles for DNS HTTPS and DNS over TLS for iOS 14 and MacOS Big Sur
Stars: ✭ 455 (+306.25%)
Mutual labels:  dns, cloudflare
Roguesploit
Powerfull Wi-Fi trap!
Stars: ✭ 262 (+133.93%)
Mutual labels:  automation, dns
Docker Traefik Cloudflare Companion
Automatically Create CNAME records for containers served by Traefik
Stars: ✭ 59 (-47.32%)
Mutual labels:  dns, cloudflare
Cloudflare Sync
A nice to have, MIT-licensed tool for using Cloudflare as a dynamic DNS provider.
Stars: ✭ 269 (+140.18%)
Mutual labels:  dns, cloudflare
V3n0m Scanner
Popular Pentesting scanner in Python3.6 for SQLi/XSS/LFI/RFI and other Vulns
Stars: ✭ 847 (+656.25%)
Mutual labels:  dns, cloudflare
DnsTube
Access your computer from anywhere. DnsTube is a Windows .NET dynamic DNS client for Cloudflare.
Stars: ✭ 137 (+22.32%)
Mutual labels:  dns, cloudflare
Piholecloudflared
Raspberry Pi setup with Pi-Hole, CloudflareD, DHCP as the ultimate Ad-blocker
Stars: ✭ 57 (-49.11%)
Mutual labels:  dns, cloudflare
Lexicon
Manipulate DNS records on various DNS providers in a standardized way.
Stars: ✭ 1,028 (+817.86%)
Mutual labels:  dns, cloudflare
cfdns
Command line tool for manipulating DNS of CloudFlare hosted domains
Stars: ✭ 20 (-82.14%)
Mutual labels:  dns, cloudflare
Cloudflare Dyndns
CloudFlare Dynamic DNS client
Stars: ✭ 69 (-38.39%)
Mutual labels:  dns, cloudflare
AdGuard-WireGuard-Unbound-Cloudflare
The Ultimate Network Security Guide 🔒 Protection | 🔎 Privacy | 🚀 Performance on home network 24/7 🕛 Accessible anywhere 🌏
Stars: ✭ 160 (+42.86%)
Mutual labels:  dns, cloudflare
Undetected Chromedriver
Custom Selenium Chromedriver | Zero-Config | Passes ALL bot mitigation systems (like Distil / Imperva/ Datadadome / CloudFlare IUAM)
Stars: ✭ 365 (+225.89%)
Mutual labels:  automation, cloudflare
flareon
🦊A cloudflare DNS over HTTPs resolver client library.
Stars: ✭ 14 (-87.5%)
Mutual labels:  dns, cloudflare
Godns
A dynamic DNS client tool supports AliDNS, Cloudflare, Google Domains, DNSPod, HE.net & DuckDNS & DreamHost, etc, written in Go.
Stars: ✭ 784 (+600%)
Mutual labels:  dns, cloudflare
HostSpider
Domain information gathering tool
Stars: ✭ 61 (-45.54%)
Mutual labels:  dns, cloudflare
cup
CUP - Cloudflare (DNS) Updater Program
Stars: ✭ 30 (-73.21%)
Mutual labels:  dns, cloudflare
Bash Toolkit
Este proyecto esá destinado a ayudar a los sysadmin
Stars: ✭ 13 (-88.39%)
Mutual labels:  automation, dns
Cloudflare Cli
CLI utility managing CloudFlare services using CloudFlare API
Stars: ✭ 61 (-45.54%)
Mutual labels:  dns, cloudflare

cloudflare-ddns

Deprecated: Since I no longer use this I don't have much motivation to deal with issues/PRs. Feel free to check out Ethaligan's fork.

Introduction

A script for dynamically updating a CloudFlare DNS record. I use CloudFlare to host DNS for a domain and I wanted to point an A record in that domain to a host who's IP address changes occasionally. CloudFlare has an API to do this, so this happened.

Dependencies

You'll need a python interpreter and the following libraries:

You can install them with pip :

pip install -r requirements.txt

Usage

First, a few assumptions:

  • You have a CloudFlare account.
  • You're using CloudFlare to host DNS for a domain you own.
  • You have an A record in CloudFlare you intend to dynamically update.

To use this utility, create a copy of the config.yaml.template file (and remove .template from the filename). Create one template per each record / domain pair you intend to update. For example, I might have two configuration files: site_naked.yaml that updates the A record for the naked (no www prefix) domain site.not, and a second config, site_www.yaml that updates the A record for www.site.not.

To do a one-off update of your DNS record, simply run python cloudflare_ddns.py config_file_name.yaml from your terminal. The script will determine your public IP address and automatically update the CloudFlare DNS record along with it.

If the program encounters an issue while attempting to update CloudFlare's records, it will print the failure response CloudFlare returns. Check your configuration file for accurate information and try again.

Because dynamic IPs can change regularly, it's recommended that you run this utility periodically in the background to keep the CloudFlare record up-to-date.

Just add a line to your crontab and let cron run it for you at a regular interval.

# Every 15 minutes, check the current public IP, and update the A record on CloudFlare.
*/15 * * * * /path/to/code/cloudflare_ddns.py /path/to/code/config.yaml >> /var/log/cloudflare_ddns.log

This example will update the record every 15 minutes. You'll want to be sure that you insert the correct paths to reflect were the codebase is located. The redirection (>>) to append to a log file is optional, but handy for debugging if you notice the DNS record is not staying up-to-date. The script tries to print something useful to stdout any time it runs. If you find the "unchanged" messages too chatty, set quiet to true in the config and stdout will only get messages when the IP actually changed, or when there's an error.

If you want to learn more about the CloudFlare API, you can read on here.

Credits and Thanks

  • CloudFlare for having an API and otherwise generally being cool.
  • icanhazip.com for making grabbing your public IP from a script super easy.
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].