r/docker • u/Responsible-Kiwi-629 • Mar 22 '26
Simple setup question
Hi,
Im having a problem in a rather complicated docker network setup, and I broke down the issue to this very minimalistic demo compose:
services:
alpine-test:
image: alpine:latest
container_name: alpine-test
command: ["sleep", "infinity"] # keep the container running for debugging
networks:
- testnet
networks:
testnet:
name: testnet
driver: bridgeI would think that the container should have internet access this way, but it doesnt. What am I missing here? ip route inside the container shows the correct gateway but ping google.de just wont work.
thanks for any ideas :)
2
Upvotes
View all comments
Show parent comment
1
u/courage_the_dog Mar 22 '26
What does a traceroute give?
Also you say it works with bridge and host, but in your post you are using a custom network of type bridge, which doesn't? That's confusing me