From f6bd5249a17bd6fda473c91e987ece0c247e66ac Mon Sep 17 00:00:00 2001 From: Yvan Sraka Date: Mon, 8 Aug 2022 10:36:31 +0200 Subject: [PATCH] Add IOG nix cache in flake configuration From https://nixos.org/manual/nix/unstable/command-ref/new-cli/nix3-flake.html#flake-format > `nixConfig`: a set of `nix.conf` options to be set when evaluating any part of a flake. In the interests of security, only a small set of whitelisted options (currently `bash-prompt`, `bash-prompt-prefix`, `bash-prompt-suffix`, and `flake-registry`) are allowed to be set without confirmation so long as `accept-flake-config` is not set in the global configuration. --- flake.nix | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/flake.nix b/flake.nix index 39bad7e1d3..c4491a0db6 100644 --- a/flake.nix +++ b/flake.nix @@ -147,4 +147,14 @@ ]; }; }); + + # --- Flake Local Nix Configuration ---------------------------- + nixConfig = { + # This sets the flake to use the IOG nix cache. + # Nix should ask for permission before using it, + # but remove it here if you do not want it to. + extra-substituters = ["https://cache.iog.io"]; + extra-trusted-public-keys = ["hydra.iohk.io:f/Ea+s+dFdN+3Y/G+FDgSq+a5NEWhJGzdjvKNGv0/EQ="]; + allow-import-from-derivation = "true"; + }; }