Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s
51 lines
1.0 KiB
Nix
51 lines
1.0 KiB
Nix
{
|
|
replaceVarsWith,
|
|
perl,
|
|
shadow,
|
|
util-linux,
|
|
installShellFiles,
|
|
configurationDirectory ? "/etc/nixos-containers",
|
|
stateDirectory ? "/var/lib/nixos-containers",
|
|
nixosTests,
|
|
path,
|
|
}:
|
|
replaceVarsWith {
|
|
name = "nixos-container";
|
|
dir = "bin";
|
|
isExecutable = true;
|
|
src = ./nixos-container.pl;
|
|
|
|
replacements = {
|
|
perl = perl.withPackages (p: [
|
|
p.FileSlurp
|
|
p.IPCRun
|
|
]);
|
|
su = "${shadow.su}/bin/su";
|
|
lib = "${path + "/lib"}";
|
|
|
|
inherit configurationDirectory stateDirectory util-linux;
|
|
};
|
|
|
|
passthru = {
|
|
tests = {
|
|
inherit (nixosTests)
|
|
containers-imperative
|
|
containers-ip
|
|
containers-tmpfs
|
|
containers-ephemeral
|
|
containers-unified-hierarchy
|
|
;
|
|
};
|
|
};
|
|
|
|
nativeBuildInputs = [ installShellFiles ];
|
|
|
|
postInstall = ''
|
|
installShellCompletion --cmd nixos-container \
|
|
--bash ${./nixos-container-completion.sh} \
|
|
--fish ${./nixos-container-completion.fish}
|
|
'';
|
|
|
|
meta.mainProgram = "nixos-container";
|
|
}
|