Hacker News new | ask | show | jobs
by beestripes 771 days ago
Why traefik over nginx for my modest needs, a couple docker hosts and a few dozen containers. I use https://github.com/NginxProxyManager/nginx-proxy-manager, would traefik provide a benefit on such a small scale?
7 comments

I think https://github.com/caddyserver is the best option here. Automatic handling of SSL certs, it's incredibly lightweight, and has super clear config syntax.
If only the caddy ingress were done. I’ve been waiting years for it.
That’s exactly the situation I like Caddy in also.
I like traefik hot reload (among other things). Want to hide a service (the proxied app), a new route (a router in traefik terminology), a middleware (basic auth, https redirection, headers manipulation) ? Just drop the file and it gets automatically picked up, no need to reload traefik or that vhost.

Truth is: I don't like nginx syntax and traefik is/was shiny :]. I went in for the LE renewal and containers, I stayed for the configuration style.

It’s not that nice in practice. Traefik until 3.0 (which was released just a few days ago) wasn’t been able to reload TLS certificates under some circumstances: https://github.com/traefik/traefik/pull/9993

Built-in ACME support doesn’t work for me, so I still have some `systemctl restart traefik` hacks here and there.

If what you've got already works then no, I don't think you would see any benefit from switching.

The moment you need a feature which Traefik provides that isn't in Nginx is when I would consider the switch.

But what features does Traefik have that nginx doesn't?
I believe the biggest are automatic Lets Encrypt certificates and the ability to discover services and route to them based on things like Kubernetes labels.
But Certbot is already right there and most people running homelab setups don't use Kubernetes.
I also use NginxProxyManager (8 hosts) and I'm not seeing any replies to your post that would explain why caddyserver or traefik provide any benefit over NPM.
Yeah I agree with this. Nginx config is easy and you can just set it and forget it. Most of the time you're copypasting from other configs you already have anyways. Automatic LE is kinda a strange selling point when Certbot is available everywhere and supports more scenarios. Traefik's and Caddy's selling points just don't make any sense to me because they don't make anything easier than the alternatives that are already widely supported.
Traefik does certificate management for you
metrics with non enterprise nginx are very limited.