diff --git a/agents/fj-hetzner-aarch64.nix b/agents/fj-hetzner-aarch64.nix index 83905ac..ae3c517 100644 --- a/agents/fj-hetzner-aarch64.nix +++ b/agents/fj-hetzner-aarch64.nix @@ -1,5 +1,8 @@ { pkgs, config, lib, ... }: { + imports = [ + ../cachix.nix + ]; environment.systemPackages = with pkgs; [ # vim -- added by srvos.nixosModules.server # git -- srvos.nixosModules.server diff --git a/agents/fj-shadowfax-x86_64.nix b/agents/fj-shadowfax-x86_64.nix index bd410ee..08d363f 100644 --- a/agents/fj-shadowfax-x86_64.nix +++ b/agents/fj-shadowfax-x86_64.nix @@ -1,5 +1,8 @@ { pkgs, config, lib, ... }: { + imports = [ + ../cachix.nix + ]; environment.systemPackages = with pkgs; [ # vim -- added by srvos.nixosModules.server # git -- srvos.nixosModules.server diff --git a/cachix.nix b/cachix.nix new file mode 100644 index 0000000..850eddd --- /dev/null +++ b/cachix.nix @@ -0,0 +1,16 @@ + +# WARN: this file will get overwritten by $ cachix use +{ pkgs, lib, ... }: + +let + folder = ./cachix; + toImport = name: value: folder + ("/" + name); + filterCaches = key: value: value == "regular" && lib.hasSuffix ".nix" key; + imports = lib.mapAttrsToList toImport (lib.filterAttrs filterCaches (builtins.readDir folder)); +in { + inherit imports; + nix.settings = { + substituters = ["https://cache.nixos.org/"]; + builders-use-substitutes = true; + }; +} diff --git a/cachix/hsndev.nix b/cachix/hsndev.nix new file mode 100644 index 0000000..1d59976 --- /dev/null +++ b/cachix/hsndev.nix @@ -0,0 +1,13 @@ + +{ + nix = { + settings = { + substituters = [ + "https://hsndev.cachix.org" + ]; + trusted-public-keys = [ + "hsndev.cachix.org-1:vN1/XGBZtMLnTFYDmTLDrullgZHSUYY3Kqt+Yg/C+tE=" + ]; + }; + }; +} diff --git a/cachix/nix-community.nix b/cachix/nix-community.nix new file mode 100644 index 0000000..7fc4c65 --- /dev/null +++ b/cachix/nix-community.nix @@ -0,0 +1,13 @@ + +{ + nix = { + settings = { + substituters = [ + "https://nix-community.cachix.org" + ]; + trusted-public-keys = [ + "nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=" + ]; + }; + }; +} diff --git a/cachix/numtide.nix b/cachix/numtide.nix new file mode 100644 index 0000000..309a03b --- /dev/null +++ b/cachix/numtide.nix @@ -0,0 +1,13 @@ + +{ + nix = { + settings = { + substituters = [ + "https://numtide.cachix.org" + ]; + trusted-public-keys = [ + "numtide.cachix.org-1:2ps1kLBUWjxIneOy1Ik6cQjb41X0iXVXeHigGmycPPE=" + ]; + }; + }; +}