forked from DGNum/lab-infra
40 lines
569 B
Nix
40 lines
569 B
Nix
|
{ pkgs, ... }:
|
||
|
|
||
|
let
|
||
|
substitutions = {
|
||
|
inherit (pkgs)
|
||
|
bash
|
||
|
colmena
|
||
|
coreutils
|
||
|
nvd
|
||
|
git
|
||
|
jq
|
||
|
;
|
||
|
};
|
||
|
|
||
|
mkShellScript =
|
||
|
name:
|
||
|
(pkgs.substituteAll (
|
||
|
{
|
||
|
inherit name;
|
||
|
src = ./. + "/${name}.sh";
|
||
|
dir = "/bin/";
|
||
|
isExecutable = true;
|
||
|
|
||
|
checkPhase = ''
|
||
|
${pkgs.stdenv.shellDryRun} "$target"
|
||
|
'';
|
||
|
}
|
||
|
// substitutions
|
||
|
));
|
||
|
|
||
|
scripts = [
|
||
|
"cache-node"
|
||
|
"check-deployment"
|
||
|
"launch-vm"
|
||
|
"list-nodes"
|
||
|
];
|
||
|
in
|
||
|
|
||
|
builtins.map mkShellScript scripts
|