systemd.nspawn: fix missing suffix

Fix files placed in `/etc/systemd/nspawn/` missing `.nspawn` suffix
This commit is contained in:
Giumo X. Clanjor (哆啦比猫/兰威举) 2017-07-04 21:12:47 +08:00 committed by GitHub
parent 51c481bdcc
commit 87cbb86214

View file

@ -110,7 +110,7 @@ in {
config =
let
units = mapAttrs' (n: v: nameValuePair "${n}.nspawn" (instanceToUnit n v)) cfg;
units = mapAttrs' (n: v: let nspawnFile = "${n}.nspawn"; in nameValuePair nspawnFile (instanceToUnit nspawnFile v)) cfg;
in mkIf (cfg != {}) {
environment.etc."systemd/nspawn".source = generateUnits "nspawn" units [] [];