Following the example of docker-compose where there are web and load balancer containers
load balancer service name is LB and web service name is WEB
everything is working fine.
My question here is when I scale web using the command
docker-compose scale web=5
It starts 5 instances of the web service.
Is it possible for these instances to know the ip address of other instances started before them so that they can talk to each other for some configuration changes.
If yes, How and If no, what is the work around since my webapp should know the ipaddresses of all other nodes to work out some configuration details.
Thanks
Harneet