Skip to content

Instantly share code, notes, and snippets.

@rhtyd rhtyd/updateddns
Created Jan 9, 2016

Embed
What would you like to do?
CloudFlare DDNS
cfuser=you@email.com
cfkey=cf-key-here
zoneid=some-zoneid
dnsrec=dns-record-id
domain=somedomain.com
curl -X PUT "https://api.cloudflare.com/client/v4/zones/$zoneid/dns_records/$dnsrec" \
-H "X-Auth-Email: $cfuser" \
-H "X-Auth-Key: $cfkey" \
-H "Content-Type: application/json" \
--data '{"id":"'$dnsrec'","type":"A","name":"'$domain'","content":"'`curl -s http://icanhazip.com`'"}'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.