From c3f4613074af88b48e9c8da9271dff0838e3f1cf Mon Sep 17 00:00:00 2001 From: Daniel Kempkens Date: Wed, 5 Apr 2023 13:12:40 +0200 Subject: [PATCH] attic: Enable on systems --- secret/shared/nix-netrc | Bin 0 -> 279 bytes system/hosts/Styx.nix | 5 ++++- system/hosts/attic.nix | 5 +++++ system/hosts/sail.nix | 11 +++++++---- system/nixos/attic.nix | 5 +++++ 5 files changed, 21 insertions(+), 5 deletions(-) create mode 100644 secret/shared/nix-netrc create mode 100644 system/nixos/attic.nix diff --git a/secret/shared/nix-netrc b/secret/shared/nix-netrc new file mode 100644 index 0000000000000000000000000000000000000000..fd3936e490e854ad903125116ca4dd9750ca828a GIT binary patch literal 279 zcmV+y0qFh!M@dveQdv+`0DP62xIoS0KEd~!>e_7x;hW0=7CTpW@kbFt>gqWwCY{d6 z{LS*ZUnp5z~aDh{`l6%p;B~hM;DGZqEbqiyk}q6-mWgVo~bQqk?+$ zMjw+#MO_KGpO{m3mg=pOsc_&?J3mRcr&C!hMba@kTZ$q+(n2tY<;rSVnN;?ngzb<( dPT9JCte2--XjB}#r>}8tnat@eWl#H*Y8&S+jSK() literal 0 HcmV?d00001 diff --git a/system/hosts/Styx.nix b/system/hosts/Styx.nix index b84b378..9ea6869 100644 --- a/system/hosts/Styx.nix +++ b/system/hosts/Styx.nix @@ -20,19 +20,21 @@ "https://nix-community.cachix.org" "https://wurzelpfropf.cachix.org" "https://nifoc.cachix.org" + "https://attic.cache.daniel.sx/nifoc-systems" ]; trusted-public-keys = [ "nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=" "wurzelpfropf.cachix.org-1:ilZwK5a6wJqVr7Fyrzp4blIEkGK+LJT0QrpWr1qBNq0=" "nifoc.cachix.org-1:ymuftq7RgN/lf/iWXFK8gpwDSAGFaGBeliWe9u6q8II=" + "nifoc-systems:eDDqVP5BFR6/1KvXbF9oUL8JahDdmbrsYtxlQ57LOTU=" ]; trusted-users = [ "@admin" ]; }; extraOptions = '' - post-build-hook = /Users/daniel/.config/nixpkgs/home/programs/scripts/attic-system-cache + post-build-hook = ${../../home/programs/scripts/attic-system-cache} ''; configureBuildUsers = true; @@ -70,6 +72,7 @@ environment = { darwinConfig = "$HOME/.config/nixpkgs/system/hosts/Styx.nix"; + etc."nix/netrc".source = ../../secret/shared/nix-netrc; }; services = { diff --git a/system/hosts/attic.nix b/system/hosts/attic.nix index 5823ebf..25a2537 100644 --- a/system/hosts/attic.nix +++ b/system/hosts/attic.nix @@ -32,12 +32,14 @@ in "https://nix-community.cachix.org" "https://wurzelpfropf.cachix.org" "https://nifoc.cachix.org" + "https://attic.cache.daniel.sx/nifoc-systems" ]; trusted-public-keys = [ "nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=" "wurzelpfropf.cachix.org-1:ilZwK5a6wJqVr7Fyrzp4blIEkGK+LJT0QrpWr1qBNq0=" "nifoc.cachix.org-1:ymuftq7RgN/lf/iWXFK8gpwDSAGFaGBeliWe9u6q8II=" + "nifoc-systems:eDDqVP5BFR6/1KvXbF9oUL8JahDdmbrsYtxlQ57LOTU=" ]; }; @@ -52,9 +54,12 @@ in extra-platforms = aarch64-linux keep-derivations = true keep-outputs = true + post-build-hook = ${../../home/programs/scripts/attic-system-cache} ''; }; + environment.etc."nix/netrc".source = ../../secret/shared/nix-netrc; + boot = { cleanTmpDir = true; diff --git a/system/hosts/sail.nix b/system/hosts/sail.nix index 6db5c52..f9c17e0 100644 --- a/system/hosts/sail.nix +++ b/system/hosts/sail.nix @@ -19,6 +19,8 @@ in ../nixos/atuin-sync.nix + ../nixos/attic.nix + ../nixos/anonymous-overflow.nix (import ../nixos/freshrss.nix (args // { inherit secret; })) @@ -61,16 +63,14 @@ in "https://nix-community.cachix.org" "https://wurzelpfropf.cachix.org" "https://nifoc.cachix.org" - ] ++ optionals secret.nix-cache.nifoc.enabled [ - secret.nix-cache.nifoc.s3Url + "https://attic.cache.daniel.sx/nifoc-systems" ]; trusted-public-keys = [ "nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=" "wurzelpfropf.cachix.org-1:ilZwK5a6wJqVr7Fyrzp4blIEkGK+LJT0QrpWr1qBNq0=" "nifoc.cachix.org-1:ymuftq7RgN/lf/iWXFK8gpwDSAGFaGBeliWe9u6q8II=" - ] ++ optionals secret.nix-cache.nifoc.enabled [ - secret.nix-cache.nifoc.publicKeyValue + "nifoc-systems:eDDqVP5BFR6/1KvXbF9oUL8JahDdmbrsYtxlQ57LOTU=" ]; }; @@ -85,9 +85,12 @@ in extra-platforms = aarch64-linux keep-derivations = true keep-outputs = true + post-build-hook = ${../../home/programs/scripts/attic-system-cache} ''; }; + environment.etc."nix/netrc".source = ../../secret/shared/nix-netrc; + boot = { cleanTmpDir = true; diff --git a/system/nixos/attic.nix b/system/nixos/attic.nix new file mode 100644 index 0000000..2ac317d --- /dev/null +++ b/system/nixos/attic.nix @@ -0,0 +1,5 @@ +{ pkgs, ... }: + +{ + environment.systemPackages = [ pkgs.attic-client ]; +}