The given problem:
Created a Java Tcp Server with Eclipse vertx(Toolkit for building
reactive,event driven)applications on JVM. The applicatino has two
Tcp Servers which are running on port numbers:
I created a Docker image and was running the application inside a
container and all works fine locally.
I want to deploy the docker container on ECS(Amazon Container
Service) and to use Network Load balancer,the question is how can i
assign different ports to different containers if in the Java code i
was setting up explicity
//tcp server 1 listens on port 5050
and how does ECS manages what ports to assign to what container?
The tcp client is always targeting one ip adress and one port number
it cannot be changed.
Go to Source