Free DDNS with Cloudflare and a cronjob
41–50 of 202 posts
Re: Free DDNS with Cloudflare and a cronjob
#42Since my IP hardly changes, I went from DDNS to an email notifying me when the IP changes with this cron: old_ip=`cat ~/.prev_ip` my_ip=`ifconfig em0 | awk '/inet/ {print $2}' 2>&1` my_email=me@example.com if [ "$my_ip" != "$old_ip" ]; then echo $my_ip > ~/.prev_ip echo $my_ip | mail -r $my_email -s "New IP: $my_ip" $my_email fi
It’s also trivial if you run your own nsd/bind instance.
Re: Free DDNS with Cloudflare and a cronjob
#43Re: Free DDNS with Cloudflare and a cronjob
#44Earlier quoted context omitted.
https://www.cloudflare.com/cdn-cgi/trace will return your ip.
The (above) shared url leveraging the cloudflare.com domain name seems to show ip v6 address, while I've noticed that the following defaults to showing ip v4 address: https://1.1.1.1/cdn-cgi/trace Pick your poison as you wish - either is great! :-)
curl -4 https://www.cloudflare.com/cdn-cgi/trace
curl -6 https://www.cloudflare.com/cdn-cgi/trace
Also the reason that the 1.1.1.1 one shows only IPv4 address is because 1.1.1.1 is itself an IPv4 address. So any connection to it will have to be using IPv4.Re: Free DDNS with Cloudflare and a cronjob
#45Instead of using DDNS, I have been using Cloudflare tunnels to expose my home services to the internet. The setup is much simpler and it seems like it's more secure too You specify a port and point it to a subdomain and it just immediately works, no maintenance necessary. The daemon only needs to be installed once with a simple terminal command
There are some limitations such as: – TLS termination mandatorily happens at Cloudflare (i.e. your traffic is mitm'ed). That's because this free product is meant as a gateway drug (aka a loss leader) to Cloudflare's WAF/Anti-DDOS products (which require TLS termination to happen on their side for technical reasons). – Other TCP protocols (including SSH) require every client to run the software too. So if you were thi…
But on the flip side, this allows you to have a nice certificate on your outside connection without having to fiddle with letsencrypt or whathaveyou.
Re: Free DDNS with Cloudflare and a cronjob
#46If only this didn't require an API token with write access to the entire domain. Please Cloudflare, let us grant access to specific (or regexp!) records
Re: Free DDNS with Cloudflare and a cronjob
#47[1] - https://openwrt.org/packages/pkgdata/ddns-scripts-cloudflare
Re: Free DDNS with Cloudflare and a cronjob
#48I used ddclient with Cloudflare for years with no issues. Recently upgraded my home router and the manufacturer operates a free dynamic dns service enabled with a toggle button. I have a cname record in my domain’s dns records pointing to the dynamic dns entry. I actually don’t even need that anymore. All the services I run at home are only for immediate family so only available remotely via a Wireguard vpn connectio…
Mikrotik at least has that DDNS functionality. It is really nice feature.
Re: Free DDNS with Cloudflare and a cronjob
#49Instead of using DDNS, I have been using Cloudflare tunnels to expose my home services to the internet. The setup is much simpler and it seems like it's more secure too You specify a port and point it to a subdomain and it just immediately works, no maintenance necessary. The daemon only needs to be installed once with a simple terminal command
There are some limitations such as: – TLS termination mandatorily happens at Cloudflare (i.e. your traffic is mitm'ed). That's because this free product is meant as a gateway drug (aka a loss leader) to Cloudflare's WAF/Anti-DDOS products (which require TLS termination to happen on their side for technical reasons). – Other TCP protocols (including SSH) require every client to run the software too. So if you were thi…