]> git.proxmox.com Git - mirror_lxc.git/commit
start: call lxc_find_gateway_addresses early
authorThomas Parrott <thomas.parrott@canonical.com>
Thu, 4 Jul 2019 21:38:23 +0000 (22:38 +0100)
committerChristian Brauner <christian.brauner@ubuntu.com>
Fri, 5 Jul 2019 09:05:38 +0000 (11:05 +0200)
commit03ca4af8fa4bf68239b78217b5b0da24f3ae4565
tree7d9a8f22e21e4a0123becb9b68208a075022454c
parent306ca14a2969aaf4245846d579218d41578bf82b
start: call lxc_find_gateway_addresses early

This restores the lxc.net.x.ipv4.gateway = auto and
lxc.net.x.ipv6.gateway = auto functionality.

When the child is created the parent and child have different views of
struct lxc_handler since - obviously - virtual memory is duplicated. So any
changes to done by the parent that the child should see need to be IPCed to it.
For any non-actual device creation stuff this does not make much sense. This
includes finding gateway addresses. Move it back prior to clone().

Fixes #3078

Signed-off-by: Thomas Parrott <thomas.parrott@canonical.com>
[christian.brauner@ubuntu.com: non-functional changes and update commit message]
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
src/lxc/network.c
src/lxc/start.c