Is this due to the network_mode: host?
Probably, yes. I think the homeassistant
container won’t exist in the network Caddy is in, so it won’t be able to connect. So you’ll need to use the host IP to connect to it, I guess.
I’m sure others have run into a similar issue with homeassistant, this isn’t something specific to Caddy, really. It’s more of a general Docker thing.