That’s for running on a nonstandard port for the external interface - what you type in the web browser - not for internal routing.
I’d still recommend the use of unix sockets for the [Caddy || nginx] → Discourse.nginx connection if you’re doing 2 containers.
If you can figure out how to do multisite, of course, that’ll get you just one container and everything is fine.