Docker: Connectivity between Physical Machine - VM -Docker container -
i have started have experimentation docker. on windows host have virtual machine holds docker container. want have communication between host , container or may other vms , container.
- host ip 192.168.2.10 subnet mask 255.255.255.0
- vm ip 192.168.254.130 subnet mask 255.255.255.0
- container gets ip 172.17.0.13
i have seen few blogs talking bridging still not sure , how that. not networking stuff.
a little guidance help.
thanks
edit: followed bridge-building not understand ip range give bridge, so, gave 192.168.254.1/24. command ip addr show bridge0
shows state unknown
.
i'll assume using docker on windows linux host running on virtualbox. note default docker-machine
creates nat adapter (with port forward) , host-only adapter, tricky different machines talk correct ip.
as answered adrian typically "publish" ports port forwarding, if container has communicate via many ports , running 1 such container / host easier start container via docker run --net host ...
, way host's ethernet adapters directly visible within container (as discovered here).
Comments
Post a Comment