Cloudflare Installation

 Well, now the million-dollar question, how can I make my website accessible to everyone? My ISP doesn't provide a public IPv4, so I thought about using a DDNS service like No-IP or the one included in Google Domains . However, I encountered another problem; my ISP uses double NAT, meaning my IPv4 could only be accessible to other users on my ISP. I realized I had a public IPv6 (although I believe it's also dynamic), so I added all my domains in AAAA records pointing to my IPv6 in the DNS. It worked for a moment, this way I didn't have to open ports on my router because that IP was unique to my PC. But there was a serious issue; my site was inaccessible to any network that didn't have IPv6 enabled (for example, my school's network).

My sites remained like this until one day I discovered a video by Network Chuck talking about Cloudflare Tunnels. I followed the instructions in his video, with a few small changes :3

I wanted to create the tunnel from the terminal and not in the panel, so I followed the instructions in the docs Create a locally-managed tunnel (CLI) · Cloudflare Zero Trust docsfor creating a locally-managed tunnel (CLI).

Afterwards, I found it very complicated to write the entire command to start my tunnel, so I created this script to execute it with 'mytunnel' (remember to make it executable).

It was also challenging to write the entire command to add my subdomain to the DNS, so I made this script.

Finally, I didn't want to have a terminal where the tunnel was always running, especially because I had to disconnect the SSH. So, I turned it into a service to start at system boot (remember to enable your service).

No comments:

Post a Comment

Soporte para archivos en Shield Cipher

 Muy bien, me ha costado un poco pero por fin hace dos semanas he implementado la encriptación de archivos con ShieldCipher :3 He tenido alg...