Traefik for internal apps

Should you use Traefik for internal apps? Short answer, no. Long answer, yes, with some thought behind it. Mainly, what apps, why, and is it worth it?

So, traefik is really nice for internal services, since you have multiple services in the same host machine, as you do with multiple docker apps running amok. Traefik can help you with giving you nicer domain names, and not to worry on, what port what service is when you can prefix them nicely; nodered.domain.tld, homeassistant.domain.tld, etc.

This all sounds nice and nifty, and it is, but then, mobile firefox, at least for me, wants https traffik, for some weird reason, and no amount of configuration will make that go away, maybe it’s just me, but it’s annoying.

But with traefik, and dns challenge, you can have SSL with internal domain names (which letsencrypt usually doesn’t allow). Even this is really nice, with some configuration, but then you start to encounter difficulties.

Internal routing

It’s probably again, something I’m not good at, which is docker internal routing in the same machine. Since, when you have https, and you start to mess up with the available ports (since all traffic should go trough traefik) stuff starts to hurt.

Docker will want to use internal ip-addresses, routing stuff around the web wont work, so stuff never arrives at traefik. And everything just becomes really difficult. For some of the apps.

With some services, everything works, like magic, but with others, internal routing is really really difficult. And with me wanting to have everything working, quite fast, and if something doesn’t work, I tend to toss it out.

I think I’ve installed Traefik in my smart home machine, 3 times now. Always it works, but always there’s something. And like I said, I don’t want there to be something on my smart home machine. That thing should work like a machine, without any hiccups, without any worries.

But hard stuff is where the fun is

But it is what it is, when things are hard, there’s room for improvement, and if everything would be easy, it wouldn’t be as much fun.

So again, I have traefik installed in all of my machines, with the idea that, everything will work in the end. And I might just have to make sure to revert what I’ve started, if things don’t work at first, and then continue some other time.

But maybe, this time, I will have the patience to make everything work like charm. Even if it takes a while to learn how to do everything.