Hi,
Yes this is the expected behaviour. There are 2 solution:
- pin the task group to specific node via constraints
- setup a fronting proxy to forward traffic, you'll need to setup consul and use service stanza. There are several load balancers with native consul support, like fabio, traefik. Or you can use nginx with consul-template. Istio and linkerd are probably way too complicated for your requirement.
The latter one is the best way if you have more service that needs to be exposed to the internet, however the first one is the simplest solution with no dependencies
Yan.