Merge pull request #167208 from devplayer0/fix/missing-systemd-nspawn-options

nixos/systemd/nspawn: Add missing nspawn unit options
This commit is contained in:
Sandro 2022-05-05 22:58:59 +02:00 committed by GitHub
commit 836c52e625
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -16,7 +16,7 @@ let
"LimitNOFILE" "LimitAS" "LimitNPROC" "LimitMEMLOCK" "LimitLOCKS" "LimitNOFILE" "LimitAS" "LimitNPROC" "LimitMEMLOCK" "LimitLOCKS"
"LimitSIGPENDING" "LimitMSGQUEUE" "LimitNICE" "LimitRTPRIO" "LimitRTTIME" "LimitSIGPENDING" "LimitMSGQUEUE" "LimitNICE" "LimitRTPRIO" "LimitRTTIME"
"OOMScoreAdjust" "CPUAffinity" "Hostname" "ResolvConf" "Timezone" "OOMScoreAdjust" "CPUAffinity" "Hostname" "ResolvConf" "Timezone"
"LinkJournal" "LinkJournal" "Ephemeral" "AmbientCapability"
]) ])
(assertValueOneOf "Boot" boolValues) (assertValueOneOf "Boot" boolValues)
(assertValueOneOf "ProcessTwo" boolValues) (assertValueOneOf "ProcessTwo" boolValues)
@ -26,11 +26,13 @@ let
checkFiles = checkUnitConfig "Files" [ checkFiles = checkUnitConfig "Files" [
(assertOnlyFields [ (assertOnlyFields [
"ReadOnly" "Volatile" "Bind" "BindReadOnly" "TemporaryFileSystem" "ReadOnly" "Volatile" "Bind" "BindReadOnly" "TemporaryFileSystem"
"Overlay" "OverlayReadOnly" "PrivateUsersChown" "Overlay" "OverlayReadOnly" "PrivateUsersChown" "BindUser"
"Inaccessible" "PrivateUserOwnership"
]) ])
(assertValueOneOf "ReadOnly" boolValues) (assertValueOneOf "ReadOnly" boolValues)
(assertValueOneOf "Volatile" (boolValues ++ [ "state" ])) (assertValueOneOf "Volatile" (boolValues ++ [ "state" ]))
(assertValueOneOf "PrivateUsersChown" boolValues) (assertValueOneOf "PrivateUsersChown" boolValues)
(assertValueOneOf "PrivateUserOwnership" [ "off" "chown" "map" "auto" ])
]; ];
checkNetwork = checkUnitConfig "Network" [ checkNetwork = checkUnitConfig "Network" [