Comment 13 for bug 1571967

Revision history for this message
St├ęphane Graber (stgraber) wrote :

Marking this as won't fix as while it'd fit reasonably well in the current single-bridge, distro controlled approach that we have currently, it won't fit so well with our new network management story that's landing this cycle.

New lxd will come without a bridge and then let the user add as many bridges as they want. That'll be all handled by LXD itself which doesn't have distribution knowledge and shouldn't be messing with DNS settings on the host.

The other problem with the new approach is that you may end up with a dozen bridges that will all use "lxd" as the domain. That's fine for resolution within the containers but isn't something we could really handle on the host side.

Instead, I recommend using the following ssh_config snippet that will work for all containers, regardless of bridges:
Host *.lxd
  StrictHostKeyChecking no
  UserKnownHostsFile /dev/null
  ProxyCommand nc $(lxc list -c s4 $(echo %h | sed "s/\.lxd//g") %h | grep RUNNING | cut -d' ' -f4) %p