Migrate packages to use callPackage pattern
All checks were successful
CI / build (push) Successful in 2m46s
All checks were successful
CI / build (push) Successful in 2m46s
This commit is contained in:
parent
478b8903e0
commit
15ece3585e
11 changed files with 92 additions and 62 deletions
21
packages/sops/default.nix
Normal file
21
packages/sops/default.nix
Normal file
|
@ -0,0 +1,21 @@
|
|||
{
|
||||
gitMinimal,
|
||||
nix,
|
||||
sops,
|
||||
writeShellApplication,
|
||||
...
|
||||
}:
|
||||
writeShellApplication {
|
||||
name = "sops";
|
||||
meta.description = "Run SOPS with the generated configuration";
|
||||
runtimeInputs = [
|
||||
sops
|
||||
gitMinimal
|
||||
nix
|
||||
];
|
||||
text = ''
|
||||
FLAKE_ROOT="$(git rev-parse --show-toplevel)"
|
||||
nix build --out-link "$FLAKE_ROOT/.sops.yaml" "$FLAKE_ROOT#sops-config"
|
||||
sops --config "''${FLAKE_ROOT}/.sops.yaml" "''${@}"
|
||||
'';
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue