How can I make kubernetes pods making the host and pods in the same LAN

10/12/2015

If I run the container by myself, I can bridge the docker container to a physical interface using pipework. But if I use kubernetes + docker, how can I bridge container to physical interface, making the host and pods in the same LAN?

-- taozix
kubernetes

1 Answer

10/20/2015

I'm guessing you are trying to expose your pod on an IP separate from your host, but in the same network (e.g. not port-mapped/NATed). This is exactly why kubernetes chose its network model. Using advanced routes in GCE (or Flannel, Weave, Calico, etc.), Pods all get their own IPs that are accessible to other Pods, and to other Hosts, without NATing.

-- CJ Cullen
Source: StackOverflow