Documentation ¶
Overview ¶
Package dyndns dynamically updates A/AAAA DNS records on Cloudflare.
Unlike other packages, this is intended to be used as a library (e.g. alongside an http.Server). It uses Cloudflare's 1.1.1.1 to get your public IP, and API Tokens for authentication.
See:
https://blog.cloudflare.com/api-tokens-general-availability/
Usage:
func main() { go dyndns.SyncDNS("example.com", "[Zone ID]", "[Edit zone DNS Token]", time.Minute) http.HandleFunc("/", func(w http.ResponseWriter, req *http.Request) { io.WriteString(w, "Hello, world!\n") }) log.Fatal(http.ListenAndServe(":http", nil)) }
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.