adda cachix

This commit is contained in:
Cyryl Płotnicki 2019-10-06 12:17:36 +01:00
parent 1326524e4a
commit 2f819dcfba
3 changed files with 28 additions and 0 deletions

14
nixos/cachix.nix Normal file
View file

@ -0,0 +1,14 @@
# WARN: this file will get overwritten by $ cachix use <name>
{ 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.binaryCaches = ["https://cache.nixos.org/"];
}

13
nixos/cachix/cyplo.nix Normal file
View file

@ -0,0 +1,13 @@
{
nix = {
binaryCaches = [
"https://cyplo.cachix.org"
];
binaryCachePublicKeys = [
"cyplo.cachix.org-1:6cmlYl6tQ1eidsjU2tw6uGN2hmzQ+P5uiQhuo6d1P5o="
];
};
}

View file

@ -13,6 +13,7 @@ in
./common-hardware.nix ./common-hardware.nix
./common-services.nix ./common-services.nix
./vim.nix ./vim.nix
./cachix.nix
]; ];
nixpkgs.config = { nixpkgs.config = {