access containers by network interface #25568
Replies: 3 comments
-
I'm asking this because, although I can use the ping command from the terminal to reach the containers, I have an application that needs to access containers like this, over multiple network interfaces. However, Podman seems to only use the first interface it finds in the container. So far, the only solution I've found is to manually set the IPs of the containers I want to reach, but that doesn't work well in dynamic network configurations. Is there a better way to handle this? |
Beta Was this translation helpful? Give feedback.
-
The |
Beta Was this translation helpful? Give feedback.
-
Thank you, this clarified why it didnt work |
Beta Was this translation helpful? Give feedback.
-
I want to find out if i can specify network interfaces when accesing containers.
Lets say i have the following setup:
2 networks: network1 and network2.
3 containers: container1 present in network1 and network2, container2 present in network1 and container3 present in network2.
In Docker, from container1, i can ping the other 2 containers by specifying the container name and the network interface, like this: ping container2.network1
While in Podman i can still ping both containers in each network with no problem, by just pinging by container name, i would like to be able to speficy the network like in Docker. is there any way to do that?
Beta Was this translation helpful? Give feedback.
All reactions