]> git.ipfire.org Git - thirdparty/systemd.git/commit - src/nspawn/nspawn-network.c
nspawn: add new --network-zone= switch for automatically managed bridge devices
authorLennart Poettering <lennart@poettering.net>
Fri, 6 May 2016 19:00:27 +0000 (21:00 +0200)
committerLennart Poettering <lennart@poettering.net>
Mon, 9 May 2016 13:45:31 +0000 (15:45 +0200)
commit22b28dfdc78680a5c03e6af3b0ce6bc96f8174a1
treede1324b7d10f1a27d73d5823187d4bcbf981a5ae
parentef76dff225a00008fe0edd1f528c9096f1a91179
nspawn: add new --network-zone= switch for automatically managed bridge devices

This adds a new concept of network "zones", which are little more than bridge
devices that are automatically managed by nspawn: when the first container
referencing a bridge is started, the bridge device is created, when the last
container referencing it is removed the bridge device is removed again. Besides
this logic --network-zone= is pretty much identical to --network-bridge=.

The usecase for this is to make it easy to run multiple related containers
(think MySQL in one and Apache in another) in a common, named virtual Ethernet
broadcast zone, that only exists as long as one of them is running, and fully
automatically managed otherwise.
src/nspawn/nspawn-gperf.gperf
src/nspawn/nspawn-network.c
src/nspawn/nspawn-network.h
src/nspawn/nspawn-settings.c
src/nspawn/nspawn-settings.h
src/nspawn/nspawn.c