[systemd-bugs] [Bug 85464] systemd-nspawn --network-bridge breaks networking in container's host

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Tue Oct 28 15:00:16 PDT 2014


https://bugs.freedesktop.org/show_bug.cgi?id=85464

--- Comment #7 from Ed Tomlinson <edt at aei.ca> ---
And when I create the service the problem reoccurs...  

Unit]
Description=Container %i
After=network-online.target                                                     
Wants=network-online.target                                                     

[Service]
Environment="host=veth0" "peer=vhost0" "bridge=br1"
"addr=2001:4830:1100:xxxx::a/64" "target=2001:4830:1100:xxxx::2"
EnvironmentFile=/etc/nspawn.d/%i

ExecStartPre=/usr/bin/ip netns add %i
ExecStartPre=/usr/bin/ip link add $host type veth peer name $peer
ExecStartPre=/usr/bin/ip link set %i $host master $bridge
ExecStartPre=/usr/bin/ip link set $peer netns %i
ExecStartPre=/usr/bin/ip netns exec %i ip link set lo up
ExecStartPre=/usr/bin/ip netns exec %i ip addr add $addr dev $peer
ExecStartPre=/usr/bin/ip netns exec %i ip -6 route add default via $target
ExecStartPre=/usr/bin/ip netns exec %i ip link set $peer up
ExecStartPre=/usr/bin/ip link set $host up
ExecStartPre=/usr/bin/ip netns exec %i nft -f /peer/%i/etc/nftables.conf

ExecStart=/usr/bin/ip netns exec %i /usr/bin/systemd-nspawn --quiet --boot
--keep-unit --link-journal=guest --directory=/peer/%i

ExecStop=/usr/bin/machinectl poweroff %i
ExecStopPost=/usr/bin/ip netns del %i
KillMode=mixed
Type=notify
RestartForceExitStatus=133
SuccessExitStatus=133

[Install]
WantedBy=multi-user.target

PS. I hate problems like this one.  <grin>

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/systemd-bugs/attachments/20141028/3e5f9748/attachment.html>


More information about the systemd-bugs mailing list