Three containers run on two networks. web must reach api; tools must not.
text
frontend backend
web, tools apiLook up api from tools, which is only on frontend:
sh
docker exec tools nslookup apiConnect web to backend without restarting it, then check that it resolves and reaches api:
sh
docker network connect backend web
docker exec web getent hosts api
docker exec web curl -s apiClients will use the name catalog for this service. Give api that alias on backend:
sh
docker network disconnect backend api
docker network connect --alias catalog backend api
docker exec web curl -s catalogLeave tools on frontend only.