From 245c9b4da23330cf29486d43931cb1fe1b35efef Mon Sep 17 00:00:00 2001 From: Daniel Goertzen Date: Wed, 20 Apr 2022 10:02:35 -0500 Subject: [PATCH 1/2] fix binary cache for nixos --- docs/tutorials/getting-started.md | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/docs/tutorials/getting-started.md b/docs/tutorials/getting-started.md index ad88de4dfd..b7e377975f 100644 --- a/docs/tutorials/getting-started.md +++ b/docs/tutorials/getting-started.md @@ -24,13 +24,9 @@ substituters = [...] https://hydra.iohk.io [...] If you're running NixOS, you need to add/update the following in your `/etc/nixos/configuration.nix` files instead. ``` -# Binary Cache for Haskell.nix -nix.settings.trusted-public-keys = [ - "hydra.iohk.io:f/Ea+s+dFdN+3Y/G+FDgSq+a5NEWhJGzdjvKNGv0/EQ=" -]; -nix.settings.substituters = [ - "https://hydra.iohk.io" -]; +# Binary Cache for Haskell.nix +nix.binaryCaches = [ "https://hydra.iohk.io" ]; +nix.binaryCachePublicKeys = [ "hydra.iohk.io:f/Ea+s+dFdN+3Y/G+FDgSq+a5NEWhJGzdjvKNGv0/EQ=" ] ``` This can be tricky to get setup properly. If you're still having trouble getting cache hits, consult the corresponding [troubleshooting section](../troubleshooting.md#why-am-i-building-ghc). From 348232db1b76a309268a87959e2fee2126b931e5 Mon Sep 17 00:00:00 2001 From: Daniel Goertzen Date: Thu, 21 Apr 2022 10:58:45 -0500 Subject: [PATCH 2/2] Update getting-started.md add nixos binary cache instruction for both <=21.11 and >21.11 --- docs/tutorials/getting-started.md | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) diff --git a/docs/tutorials/getting-started.md b/docs/tutorials/getting-started.md index b7e377975f..d40685a118 100644 --- a/docs/tutorials/getting-started.md +++ b/docs/tutorials/getting-started.md @@ -23,10 +23,26 @@ substituters = [...] https://hydra.iohk.io [...] If you're running NixOS, you need to add/update the following in your `/etc/nixos/configuration.nix` files instead. +``` +# Binary Cache for Haskell.nix +nix.settings.trusted-public-keys = [ + "hydra.iohk.io:f/Ea+s+dFdN+3Y/G+FDgSq+a5NEWhJGzdjvKNGv0/EQ=" +]; +nix.settings.substituters = [ + "https://hydra.iohk.io" +]; +``` + +NixOS-21.11 and older use slightly different settings. + ``` # Binary Cache for Haskell.nix -nix.binaryCaches = [ "https://hydra.iohk.io" ]; -nix.binaryCachePublicKeys = [ "hydra.iohk.io:f/Ea+s+dFdN+3Y/G+FDgSq+a5NEWhJGzdjvKNGv0/EQ=" ] +nix.binaryCachePublicKeys = [ + "hydra.iohk.io:f/Ea+s+dFdN+3Y/G+FDgSq+a5NEWhJGzdjvKNGv0/EQ=" +]; +nix.binaryCaches = [ + "https://hydra.iohk.io" +]; ``` This can be tricky to get setup properly. If you're still having trouble getting cache hits, consult the corresponding [troubleshooting section](../troubleshooting.md#why-am-i-building-ghc).