summaryrefslogtreecommitdiff
path: root/shell.nix
diff options
context:
space:
mode:
authorGregor Kleen <gkleen@yggdrasil.li>2022-11-07 20:51:39 +0100
committerGregor Kleen <gkleen@yggdrasil.li>2022-11-07 20:51:39 +0100
commit0e9f1e85cd8c6f9d546ef88e971043b909017170 (patch)
tree5cb4d14df7594ef123f20d82cb2ec423b6bca744 /shell.nix
parentf563ddece04adfd8d80d4e984405f5c70a6c94f3 (diff)
downloadnixos-0e9f1e85cd8c6f9d546ef88e971043b909017170.tar
nixos-0e9f1e85cd8c6f9d546ef88e971043b909017170.tar.gz
nixos-0e9f1e85cd8c6f9d546ef88e971043b909017170.tar.bz2
nixos-0e9f1e85cd8c6f9d546ef88e971043b909017170.tar.xz
nixos-0e9f1e85cd8c6f9d546ef88e971043b909017170.zip
...
Diffstat (limited to 'shell.nix')
-rw-r--r--shell.nix35
1 files changed, 28 insertions, 7 deletions
diff --git a/shell.nix b/shell.nix
index 6ada761e..14125d02 100644
--- a/shell.nix
+++ b/shell.nix
@@ -1,8 +1,29 @@
1{ pkgs ? import <nixpkgs> {}, deploy-rs, nvfetcher }: 1{ system, self, deploy-rs, nvfetcher, mach-nix, leapseconds, ... }:
2let 2let
3 tai64dec = pkgs.writeShellScriptBin "tai64dec" '' 3 pkgs = self.legacyPackages.${system};
4 echo $((16#$(${pkgs.daemontools}/bin/tai64n <<<"" | ${pkgs.coreutils}/bin/tail -c +2 | ${pkgs.coreutils}/bin/head -c 16))) 4
5 ''; 5 ca = mach-nix.lib.${system}.buildPythonPackage {
6 pname = "ca";
7 src = ./tools/ca;
8 version = "0.0.0";
9 ignoreDataOutdated = true;
10
11 requirements = ''
12 cryptography >=38.0.0
13 fqdn
14 atomicwrites
15 leapseconddata
16 xkcdpass
17 '';
18
19 _.cryptography.buildInputs = with pkgs; [ openssl ];
20
21 postInstall = ''
22 wrapProgram $out/bin/ca \
23 --set-default LEAPSECONDS_FILE ${leapseconds} \
24 --prefix PATH : ${pkgs.lib.makeBinPath (with pkgs; [sops])}
25 '';
26 };
6in pkgs.mkShell { 27in pkgs.mkShell {
7 name = "nixos"; 28 name = "nixos";
8 nativeBuildInputs = with pkgs; [ 29 nativeBuildInputs = with pkgs; [
@@ -10,10 +31,10 @@ in pkgs.mkShell {
10 wireguard-tools 31 wireguard-tools
11 gup 32 gup
12 nftables 33 nftables
13 deploy-rs 34 deploy-rs.packages.${system}.deploy-rs
14 tai64dec
15 knot-dns 35 knot-dns
16 yq 36 yq
17 nvfetcher 37 nvfetcher.defaultPackage.${system}
38 ca
18 ]; 39 ];
19} 40}