I am running a service in docker swarm with docker-compose file and am working with 1 replica. But while making it scale to 4, the clients are not connected together.
What I mean is
I want all containers to connect together. I think the problem is with the network or config file of server that must be public for all containers.
My question is
version: "3.2" services: nginx: build: context: ./nginx dockerfile: Dockerfile.dev volumes: - ./myservice/html:/app/dist ports: - "80:80" - "443:443" image: myservice_nginx:latest myservice: build: context: . dockerfile: Dockerfile.dev network_mode: "host" ports: - "9090:9090" image: myservicedocker_myservice:latest
Thank you all