I setup dynamic dns through cloudflare with a service that runs on my server. Only downside is if the server crashes and my ip changes I’m SOL until I can get the server back up and running manually, or manually change the ip in cloudflare.
I think you can have a service like
ddclient
running on your server that will automatically push updates to Cloudflare on the hour (or whatever timeframe you set). I haven’t done it on a server before, but just an OPNSense firewall that has some simple configs for setting up the Dynamic DNS system.I just used this systemd script: https://github.com/fernvenue/cloudflare-ddns
That’s a good “manual” way where you just check for an IP change every 30 seconds and send a POST request using
curl
to Cloudflare if there’s a change. Basically every other service you can find will do this in some other more convoluted way lol.
Duck DNS?
You can also set up your own that just updates the record when your IP changes. You’d want something like OpenWRT or OPNSense for that though.
You could also just set up a cheap VPS with a static IP and install a tunnel manager/reverse proxy on it. That way you never expose your local network directly and don’t need to worry about Dynamic DNS. That’s like $5/month tho
this was the first one I tried, but duckdns.org is not resolving for me. some kind of outage?
∞ 🏳️⚧️Edie [it/its, she/her, fae/faer, love/loves, ze/hir, des/pair, none/use name, undecided]@hexbear.netEnglish5·21 days agoWorks fine for me
there is some kind of outage at least on quad9 and googleDNS (quad8)
I did a dig against cloudflare (1.1.1.1) and got an A record but the other two are failing
∞ 🏳️⚧️Edie [it/its, she/her, fae/faer, love/loves, ze/hir, des/pair, none/use name, undecided]@hexbear.netEnglish3·21 days agoselfhosted unbound stay winning
What are you trying to do? Do you want to host a public server or are you trying to get a public IP to access your private server off your network?
site-to-site VPN but one end occasionally changes IP
Ah, alright. Then the existing suggestions are probably your best bet. Unfortunately, I still use
for r/selfhosted, and the subreddit put me onto a service called tailscale, a wire guard tunnel that is free for personal use. You can check it out if you like but for large network the ddns is probably for the best.
You’re doing it wrong.
Spend ten bucks on a year of a really small vps with an ipv4 address. Use some kind of overlay network style vpn with the vps as the only thing you need to actually “see” from the internet.
The solution I just described is extremely fault tolerant and has great uptime. It works for you everywhere with no custom dns (so even behind a nat router or using some doh provider).
Stop using dynamic dns it’s no longer a good solution for anyone.
In my other post I said you’re doing it wrong and you should spend ten bucks on a vps with a public ip to use as a gatekeeper to your network.
But what if you had more than ten bucks?
If you have about a buck more you can register a .xyz domain for a year and be on the real dns, with all the benefits that entails!
If you’re a real high roller and can spare eleven bucks per annum over the top of your dirt cheap tiny server, you can get a .com address and be normal.
So think about it this way: would you prefer to just be on normal dns instead of having to fuck around with dyndns and all the weird problems it has? Would you like it enough to spend 92 cents a month? Porkbun and lowendbox are the place to start looking.
Here are some domains available for less than three bucks as of the time of this post:
Flatus.lol
Cumfart.lol