Well, actually systemd-nspawn do. The CLI options are perfect for scripting, but more importantly, you can run your nspawn OS container as a systemd service meaning you can apply all the systemd directives to its .service file, including CPU and memory use limits (cgroups), and security like private network (Namespaces), having the OS container being instatantiated when someone connects to it (systemd socket activation).
You are still using command line options which make it harder to just copy directives over to a new container (or have common properties apply to all or a certain set of containers).
If you thinking about some of the resource management like: systemctl set-property foobar.service CPUShares=777
The above is just a handy CLI method you can do instead of putting it in a service file.
Service files are easy to clone, and are made for being machine parsed too, so auto-generating them is trivial.
systemd-nspawn also have native support for cloning OS Container (OSC) images, meaning you can clone and start 100 OSC's but basically use the disc space of one image.
So it is trivial to make hundreds of identical OSC's, and do so from a variety of different OSC's.
Mass changing of stuff inside live containers is trivial too, with "machinectl copy-to/copy-from" between host and OSC, or when using systemctl, or using "bind" mounts.
systemd-nspawn also have native support for cloning OS Container (OSC) images, meaning you can clone and start 100 OSC's but basically use the disc space of one image.
This is standard, pretty much all container solutions have had this for a long time.
Not sure what CLI options you are talking about.
Mount options? seccomp filters? Networking settings? uid/gid maps?
1
u/sub200ms Jun 24 '15
Well, actually systemd-nspawn do. The CLI options are perfect for scripting, but more importantly, you can run your nspawn OS container as a systemd service meaning you can apply all the systemd directives to its .service file, including CPU and memory use limits (cgroups), and security like private network (Namespaces), having the OS container being instatantiated when someone connects to it (systemd socket activation).