this post was submitted on 01 Sep 2026
84 points (98.8% liked)

Selfhosted

61855 readers
453 users here now

A place to share alternatives to popular online services that can be self-hosted without giving up privacy or locking you into a service you don't control.

Rules:

Detailed Rules Post

  1. Be civil.

  2. No spam.

  3. Posts are to be related to self-hosting.

  4. Don't duplicate the full text of your blog or readme if you're providing a link.

  5. Submission headline should match the article title.

  6. No trolling.

  7. Promotion posts require active participation, with an account that is at least 30 days old. F/LOSS without a paywall has exceptions, with requirements. See the rules link for details. Tags [CBH] or [AIP] are required, see the links in Rule 8 for details.

  8. AI-related discussions and AI-involved promotional posts have additional requirements for tagging, as noted in Rule 7 and the AI & Promotional Post Expanded Rules post, and find example disclosures here.

Resources:

Any issues on the community? Report it using the report flag.

Questions? DM the mods!

founded 3 years ago
MODERATORS
 

Every public request to one of my sites used to go through a Cloudflare tunnel. I had a cloudflared deployment in my cluster, some routing rules, and everything just worked. And it was free! But that bugged me. TANSTAAFL right? The whole point of selfhosting is to not rely on big cloud company, and there are few bigger than Cloudflare. And Cloudflare’s tunnels decrypt every single packet, so they see everything you do. I really don’t like that.

So I’ve replaced Cloudflare tunnels with Erwan Leboucher’s towonel, a selfhosted tunnel implementation. I still have my DNS on Cloudflare, but no data is moving through them any more.

...

top 24 comments
sorted by: hot top controversial new old
[–] Shimitar@downonthestreet.eu 19 points 1 day ago (8 children)

I don't get the need for those tunnels.

Wouldn't a simple wireguard setup be enough un less you are behind CG-NAT?

Wireguard it's there, free, open source, doesn't rely on any external server or company...

What does these "tunnels" actually add?

[–] stratself 5 points 1 day ago

It bundles WireGuard transport layer and a SNI reverse proxy natively, along with optional authentication. Good enough for beginners or people who need quick deployments.

[–] K3can@lemmy.radio 4 points 1 day ago* (last edited 1 day ago) (1 children)

That's exactly the use case for "tunnels": allowing public, incoming connections behind CGNAT.

Wireguard requires a public IP on at least one side of the connection and only allows private access. If you want to host a blog or website AND you're behind CGNAT, then a "tunnel" service is a very easy solution.

Edit: my previous blog post on the topic: https://blog.k3can.us/posts/2025/feb/2025-02-21_cloudflarefort/

[–] Undaunted@feddit.org 5 points 1 day ago (1 children)

But going with a self-hosted approach like Towonel, you need a server with a public IP too. And I think what the commenter meant is, if you already have that, you can just setup a WireGuard connection to that public server, so that it can route the traffic to your local network.

[–] K3can@lemmy.radio 1 points 1 day ago* (last edited 1 day ago)

Oh, maybe I misunderstood? It sounded like he didn't understand what advantage a "tunnel" could provide.

If your server is behind CGNAT, you need a TURN-style "tunnel" to allow incoming connections. If you have your own remote server with a public IP, then you can absolutely use that and create the tunnel using wireguard (or openvpn, ssh, etc).

I just mentioned CF in my blog post because it's probably the most popular solution.

The point is, if you have CGNAT, you need to create that "tunnel" somehow if you want to allow incoming connections.

[–] MangoPenguin@lemmy.blahaj.zone 2 points 23 hours ago (1 children)

What does these “tunnels” actually add?

Ease of deployment / time savings generally. You can certainly do it yourself with wireguard and a reverse proxy.

[–] non_burglar@lemmy.world 1 points 22 hours ago

They are saying wireguard alone, no reverse proxy. No exposing any services at all to the outside, just tunnel in with WG and access locally.

[–] hexagonwin@lemmy.today 3 points 1 day ago

yep, i used to use this behind a cgnat. being a broke kid i couldn't have another machine with exposed ports proxy things

[–] eodur@piefed.social 1 points 23 hours ago

Its a secure way to route the traffic from a public endpoint to your internal services without exposing your home IP address. You could do something similar with wireguard. I didn't indicate you couldn't.

I checked and this does a similar thing. You can use WG to punch out a connection, and I have before. The linked program uses quic in a similar way to WG but doesn't do any of the routing, just registers the connection to a hostname for application level forwarding.

It looks more that it provides an easy setup for an alternative.

Both methods can work on cg-nat as well since you are punching out.

[–] feannag@sh.itjust.works 1 points 1 day ago

One would be CG-NAT as you mentioned, and some people want to host for other people too, potentially including too many people/too distant/too tech illiterate to easily set up WG.

[–] Zikeji@programming.dev 1 points 1 day ago* (last edited 1 day ago) (2 children)

The benefit here is the software by design can't read your traffic - it's using SNI to route, not the host header, so SSL pass thru keeps the payload private. It's billed as shareable for that reason.

Also this is open source and you can host it yourself.

Edit: I concede BakedCatboy's point.

In either case I would probably just use FRP.

[–] Shimitar@downonthestreet.eu 5 points 1 day ago (2 children)

You missed my point?

why can't you just use a wireguard connection between your device and the server, or network?

[–] curbstickle@anarchist.nexus 3 points 1 day ago

between your device

Thats the part right there. Its for not your device to access.

Like a self- hosted website/blog for example. Or taking the complexity of "start this before you try to connect to my eBook server" for your BIL, or "OK mom, when you want to watch the home videos I converted to digital you have to do it only from your phone, press this first, then share to your TV".

That is the part I think you are missing. Use other than yourself and your own managed devices.

[–] eodur@piefed.social 1 points 23 hours ago

You mean putting your home servers on a VPN with your client devices? That wouldn't really allow for exposing public services.

[–] BakedCatboy@lemmy.ml 2 points 1 day ago (1 children)

I use a wireguard tunnel as a reverse proxy and it does ssl passthrough with sni. Termination happens on my local box and the reverse proxy host doesn't do any certs.

[–] moonpiedumplings@programming.dev 1 points 23 hours ago (1 children)

What reverse proxy are you using?

[–] BakedCatboy@lemmy.ml 1 points 23 hours ago

I use haproxy just for simplicity, with the https fronted in tcp mode with a tcp request inspect delay and acls using req_ssl_sni allows switching between multiple backend based on hostname, though if you only had 1 backend server then it could just be a raw tcp proxy. I have my stuff split between 2 local boxes that are both connected to the reverse proxy using wg so this works well for me.

[–] unitedwithme@lemmy.today 6 points 1 day ago (2 children)

Why keep DNS on Cloudflare?? Quad9 is where it's at! Supports DNSSEC, DoT or DoH, QUIC, no log, no BS.

Want it on your phone out and about (and not already using a VPN?) https://dns.quad9.com/dns-query or use the app.

[–] SteveTech@aussie.zone 5 points 23 hours ago* (last edited 23 hours ago)

I believe OP would require an authoritative DNS server, which AFAIK Quad9 is not. desec.io would be my recommendation though.

[–] eodur@piefed.social 1 points 23 hours ago

Yeah, that's a future step. I just haven't finished migrating everything.

[–] Dubois_arache@lemmy.blahaj.zone 1 points 23 hours ago* (last edited 23 hours ago) (1 children)

Most of this type of software depends on VPS or already having public ip. Pure self-hosted alternative still not known.

[–] MangoPenguin@lemmy.blahaj.zone 4 points 23 hours ago* (last edited 23 hours ago) (1 children)

Self hosted alternative is buying a static IP from your ISP I suppose. Mine is an extra $5/mo which is eh, but I'm not paying for a VPS.

[–] RepleteLocum@lemmy.blahaj.zone 1 points 22 hours ago

As far as I know an ISP has to provide one at your request in Europe. Idk if it's free.