]> git.ipfire.org Git - thirdparty/lxc.git/commitdiff
lxc-net: don't start by default inside lxc
authorAntonio Terceiro <terceiro@debian.org>
Wed, 2 Feb 2022 18:11:02 +0000 (15:11 -0300)
committerStéphane Graber <stgraber@ubuntu.com>
Tue, 22 Feb 2022 04:05:24 +0000 (23:05 -0500)
When lxc is installed inside an lxc container, trying to bring up
lxc-net with the default parameters will conflict with the networking
setup for lxc on the host. This breaks all networking inside the
container where lxc is installed.

Signed-off-by: Antonio Terceiro <terceiro@debian.org>
config/init/systemd/lxc-net.service.in

index 6ed8cd82bb5b046effecc649e9c95394bc488d84..a615d8b2d2045958f9e39fb05382d045bd8ac6bf 100644 (file)
@@ -3,6 +3,7 @@ Description=LXC network bridge setup
 After=network-online.target
 Before=lxc.service
 Documentation=man:lxc
+ConditionVirtualization=!lxc
 
 [Service]
 Type=oneshot