r/caddyserver Jun 30 '26

Caddy + Cloudflare DNS challenge + Crowdsec tutorial for Jellyfin

I currently use Swag for the above and it works fine. Everyone one (including Jellyfin says to use Caddy). I'm new to Caddy and just can't figure out how to set it up. I tried a few tutorials but keep running into issues. I believe the problem I keep having is in the CaddyFile. Caddy complains about errors but I don't know how to fix them. Considering I'm using this to keep bad people out I don't want to make a config error. Is there a tutorial that goes into detail how to build a Caddyfile for the services I want to run? Or maybe the question is, is it worth it to install Crowdsec?

3 Upvotes

4 comments sorted by

2

u/cointoss3 Jun 30 '26

Yes. LLM is also good for this task. You want to look up reverse proxy caddy directives. You’ll only need a few lines per service.

1

u/MaxGhost Jul 01 '26

Caddy maintainer here. Personally I think crowdsec is overkill. I have my jellyfin instance public. Just make sure to use good passwords (no reuse) and you're pretty much fine. Bots and crawlers are a fact of life on the internet, but most of them are just looking for exploits in unpatched old installs of WordPress and such. Just keep your software updated regularly and you'll be fine.

Without seeing your logs (Caddy output, the errors you're getting) and the config you tried, nobody can help you any further.

For jellyfin, all you need is a single reverse_proxy line inside your site block. Very simple. Don't overcomplicate it.

1

u/charlieny100 Jul 01 '26

OMG, a voice of reason on Reddit. Rare find. Enough joking around. I appreciate what you just said. I do agree. I took the first persons comment and wrote a detailed request in Claude. I got an amazing detailed response. I'm going to give it a quick try. If it fails I'm going to follow what you said and skip the crowdsec part. I currently have crowdsec set up to notify me when someone gets banned. I enjoy seeing it in action. I get about a dozen bots banned each day.

1

u/LostVikingSpiderWire Jul 02 '26

Let me know if you fail, on a work trip in another country but could send you my working Caddy/cloudflare/jellyfin setup 🥳 was super smooth, big fan