cross-posted from: https://quokk.au/c/networking/p/1292781/how-to-bypass-cgnat-for-cheap-or-free

My current internet provider does not allow me to opt out of cgnat. So I don’t have a public ip to connect to my home server from outside.

What is a good way to still connect to my home server?

Do I need to setup some VPN like headscale on cloudflare and use that to acces my network?

What if I want to host a website and make it availavle publicly?

  • Torn Apart By Dogs@lemmy.blahaj.zone
    link
    fedilink
    English
    arrow-up
    0
    ·
    20 days ago

    use docker compose to spin up a cloudflared tunnel container and that will do what you want most easily. the docs are on cloudflare’s site. it’s a client-initiated tunnel to their front-end and you point your domain at their internal address that is your tunnel. its not difficult but ymmv. its basic networking for understanding the parts and processes involved in running a reverse proxy behind that too. the tunnel is the easiest part imnsho. setting up your certs and waf and security are gonna be the more difficult pieces.

    • AloneDownUnder@quokk.auOP
      link
      fedilink
      English
      arrow-up
      0
      ·
      20 days ago

      I’m using nixos, so I could setup cloudflared in my nix config. But yeah. I would need to setup the certs and look into that to make it work.

      • Torn Apart By Dogs@lemmy.blahaj.zone
        link
        fedilink
        English
        arrow-up
        0
        ·
        19 days ago

        traefik works well with docker and doing both http and DNS acme proofs with many providers. tunnel, point DNS to tunnel, set up reverse proxy, first container is whoami, once that’s reachable, configure traefix to give whoami a cert. rinse and repeat for each service. make it easy on yourself and also use a client cert so only a cert holder gets in. otherwise do a waf. I’m for hire BTW.

    • daveyOsborn@infosec.pub
      link
      fedilink
      English
      arrow-up
      0
      ·
      10 days ago

      Oof… I would hope the OP does not have to resort to joining Cloudflare’s privacy-abusing walled garden. Is that really his only option (short of subscribing to some external service)?

      What about dynamic dns using afraid.org? OP’s router checks in with afraid.org which then updates a hostname to point to the IP of the moment. I’m not sure how long a CGNAT IP assignment lasts but whatever that is, couldn’t the ddns service be ping’d periodically just short of whatever window of time that is?