Update modules/server/containers/default.nix

This commit is contained in:
2026-06-01 17:15:31 +02:00
parent 060cbf3b31
commit 3f67ae6bba

View File

@@ -30,11 +30,14 @@ in{
effectiveCfg = { effectiveCfg = {
owner = "root:root"; owner = "root:root";
mode = "0400"; mode = "0400";
dirs = [];
} // cfg; } // cfg;
in '' in ''
${pkgs.coreutils}/bin/mkdir -p "${effectiveCfg.path}" ${pkgs.coreutils}/bin/mkdir -p "${effectiveCfg.path}"
${lib.concatMapStringsSep "\n" (dir: "${pkgs.coreutils}/bin/mkdir -p ${effectiveCfg.path}/${lib.escapeShellArg dir}") effectiveCfg.dirs}
${pkgs.coreutils}/bin/chown ${effectiveCfg.owner} "${effectiveCfg.path}" ${pkgs.coreutils}/bin/chown ${effectiveCfg.owner} "${effectiveCfg.path}"
${pkgs.coreutils}/bin/chmod ${effectiveCfg.mode} "${effectiveCfg.path}" ${pkgs.coreutils}/bin/chmod ${effectiveCfg.mode} "${effectiveCfg.path}"
'') allPathConfigs); '') allPathConfigs);
}; };