mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-22 04:25:18 +00:00
lxc: support setting host-side IP addresses/routes
(This patch had been pushed earlier in commit cd5c9f21ded4f8e6216eba02b8795f70503ab404, but was reverted in commit 1549f16832ca23918b651fb4985a2e9f257cd429 because it had been accidentally pushed during the freeze for release 2.0.0)
This commit is contained in:
parent
d83cac49e3
commit
187920273c
@ -304,6 +304,14 @@ virLXCProcessSetupInterfaceTap(virDomainDefPtr vm,
|
||||
if (virNetDevSetOnline(parentVeth, true) < 0)
|
||||
goto cleanup;
|
||||
|
||||
if (virDomainNetGetActualType(net) == VIR_DOMAIN_NET_TYPE_ETHERNET) {
|
||||
/* Set IP info for the host side, but only if the type is
|
||||
* 'ethernet'.
|
||||
*/
|
||||
if (virNetDevIPInfoAddToDev(parentVeth, &net->hostIP) < 0)
|
||||
goto cleanup;
|
||||
}
|
||||
|
||||
if (net->filter &&
|
||||
virDomainConfNWFilterInstantiate(vm->uuid, net) < 0)
|
||||
goto cleanup;
|
||||
|
Loading…
x
Reference in New Issue
Block a user