Isolate service networks with Docker Compose
I don't experience same issue with similar setup to what you describe. 'A' &amp; 'B' can ping &amp; access services on 'C' just fine. Few things to look at:

Port aside, can you ping 'C' from either of the other containers?
You probably shouldn't (can't?) name containers capital 'A', 'B', 'C' if you're going to build them in docker-compose. If that's what's actually used, try more meaningful names.
Does name resolution work if you do nslookup c from either a &amp; b? It should resolve via nameserver 127.0.0.11
firewall on 'C' or service not up on c:8080?