Bug 89976

Summary: RFE: nspawn: a way to configure container settings declaratively, outside of the nspawn command line
Product: systemd Reporter: Damjan Georgievski <gdamjan>
Component: generalAssignee: systemd-bugs
Status: RESOLVED FIXED QA Contact: systemd-bugs
Severity: enhancement    
Priority: medium    
Version: unspecified   
Hardware: Other   
OS: All   
Whiteboard:
i915 platform: i915 features:

Description Damjan Georgievski 2015-04-10 16:47:35 UTC
It would be nice if we had a .unit file that would support all that systemd-nspawn does. A declarative .unit file is much better and less prone to errors than a .service file with a long ExecStart=/usr/bin/systemd-nspawn ... command line.

The options from [Service] in `systemd-nspawn@.service` would be defaults, and all the systemd-nspawn could be put in a [Container] section. I'd like it to support both Boot=yes|no and ExecStart=COMMAND [ARGS...] invocations.
Comment 1 Lennart Poettering 2015-04-14 13:37:45 UTC
My plan is to add a concept of .nspawn files that can accompany container directories and contain a list of settings for them. This would then mean that the systemd-nspawn@.service file could stay unmodified for all instances, and the specific instances would be read from those container-specific settings instead.
Comment 2 Lennart Poettering 2015-09-06 16:30:04 UTC
This is implented in PR #1165 now. Which we'll hopefully merge soon.
Comment 3 Lennart Poettering 2015-09-07 09:20:47 UTC
The PR has been merged now. Closing.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.