These are chat archives for docker/swarm

8th
Dec 2016
am0nshi
@am0nshi
Dec 08 2016 16:24

hi guys. can any one help with next situation - we got separate network on each swarm node(node1.docker.ovm/virbr0, node2.docker.ovm/virbr0, node3.docker.ovm/virbr0, ...), and when we deploy project via UCP panel, we use compose file to resolve all dependencies between our services. the problem is, while we deploy compose.yml, we don't know on which node we will be deployed, and code like

version: '2'
services:
  gatewaystaging:
    image: dtr.docker.ovm/ovm/gateway:latest
    ports:
      - "5899:5899"
    networks:
      - node5.docker.ovm/virbr0
networks:
  node5.docker.ovm/virbr0:
    external: true

fails each time when we deploy not on 5-th node. if we use just virbr0 interface, we got error like network unknown. Has anybody any ideas how to organize mnemonics or smth else, to get inside container network interface virbr0, but on each instance their own virbr0 ?