Hi, I wanted to host a personal Lemmy instance online (for just myself, I don’t think I can take the upkeep for other users - please let me know if this is not possible) and wanted to understand how to “attach” a CDN service to it.

The idea behind doing this is that I’m in the US but I’m looking to host a server in Europe. I am looking into Cloudflare’s free CDN service, but it would be great if someone could point me towards how I can configure this setup to speed up the loading time for my Lemmy instance (which is going to be far away from me, geographically).

I would also like to know about your setups and how you have hosted Lemmy.

Thanks!

  • kinttach@lemmy.world
    link
    fedilink
    English
    arrow-up
    0
    ·
    1 year ago

    Setting your nameservers is simply a requirement for Cloudflare. While they theoretically could work via CNAME – they don’t. On the other hand, their DNS is really nice and is free.

    When you use their DNS, for each DNS record, you have the option to proxy traffic through Cloudflare. The proxy is what enables their CDN (and many other features such as forwarding, rewriting URLs, DDoS protection, automatic HTTPS certificates, and so on). It’s a simple on/off switch for each DNS record if you don’t want to proxy a particular host.

    • MigratingtoLemmy@lemmy.worldOP
      link
      fedilink
      English
      arrow-up
      1
      ·
      1 year ago

      Thank you, that would mean that technically there is no need for cloudflare to ask one to change their default nameservers to cloudflare’s nameservers - it’s just that they want to run their analytics on the data transmitted in exchange for free services. I understand now. I believe some of the paid plans allow for one to use CNAMEs, which makes sense.

      Thanks, now I understand. I will need to read more on the networking tech behind a Cloudflare based reverse-proxy setup (and maybe even set up my own through another VPS box someday). I’ll go through the docs, thanks again!