There is consul server in docker.
vote-consul-server:
image: consul:1.7.2
environment:
CONSUL_BIND_INTERFACE: eth0
ports:
- "${CONSUL_PORT}:8500"
It generates hosts for registred applications. The main problem is that anothers applications can't communicate between each other if they are not in docker.
For example: I have config-service (docker with consul), user-service(IDE). When user-service starts, it asks for configurations from config-server, but consul gives not correct link (available only in docker network).
c.c.c.ConfigServicePropertySourceLocator : Fetching config from server at : http://83a6c7ab12d0:8888/
How to publish all links from consul(docker)?