Docker Community Forums

Share and learn in the Docker community.

What networks get attached to my container, I see differences between stack and standalone services I create


(Sandd) #1

Hi everyone

I have some issues understanding some difference I am seeing between some containers I deploy from a stack and standalone containers.

So I have a docker-compose with some services that attach to a network I created:

 networks:
   sandd-net:
     external:
       name: test

If I do docker-inspect on a service within the stack I get this at VirtualIPs

“VirtualIPs”: [
{
“NetworkID”: “7b6pfkfc8vp2novoocv28pdqh”,
“Addr”: “10.255.6.226/16”
},
{
“NetworkID”: “kxn8a3iqzf641dt6aqnlisz0k”,
“Addr”: “10.0.0.250/24”
}
]

7b6pfkfc8vp2novoocv28pdqh is the ingress network

If I deploy a standalone service and attach it to that test network, it doesn’t attach the ingress network.

What’s the difference and what’s the scope of this? After two days of fighting with some stupid cassandra issue networking is all messed up in my head now and I want to understand this.

Thanks!