Confused about custom DDNS
-
I'm trying to set up a custom DDNS updater.
The command I should run to update the IP of my domain is
curl -X PUT 'https://min.hostup.se/api/service/12345/dns/54321/records/12345678' -u 'username:password' -H 'Content-Type: application/json' -d "{\"content\": \"%IP%\"}"
I don't know how or where to enter this. It only gives me a field for an URL, but I need a lot more than just an URL.
-
Managed to write a script that updates it. I found a directory
/var/preserve
that according to some random person somewhere will survive OS updates. There doesn't seem to be much documentation on this.I've now set it as a cron job to run every hour, but it would be nice to have some kind of trigger. I feel like this whole thing could be made a lot easier inside the built-in Dynamic DNS updater.
-
Hmm, first I've heard of it. Though it's unlikely to be overwritten since it's a custom directory, no update tries to write there.
I usually out custom scripts like that in /root.