From c5c41d30c284b4d7866d7b1bc365d7121f2954a6 Mon Sep 17 00:00:00 2001 From: Jennifer Graul Date: Thu, 23 Jan 2025 12:52:51 +0100 Subject: [PATCH] tune nix settings --- iso.nix | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/iso.nix b/iso.nix index a99959d..38b54f0 100644 --- a/iso.nix +++ b/iso.nix @@ -21,6 +21,32 @@ # Configure host id for ZFS to work networking.hostId = lib.mkDefault "8425e349"; + nix = { + settings = { + trusted-users = [ "@wheel" ]; + experimental-features = [ "nix-command" "flakes" "repl-flake" ]; + auto-optimise-store = true; + }; + extraOptions = '' + min-free = ${toString (100 * 1024 * 1024)} + max-free = ${toString (1024 * 1024 * 1024)} + ''; + nixPath = lib.mkForce [ "nixpkgs=${lib.cleanSource pkgs.path}" ]; + registry = lib.mkForce { + "nixpkgs" = { + from = { + type = "indirect"; + id = "nixpkgs"; + }; + to = { + type = "path"; + path = lib.cleanSource pkgs.path; + }; + exact = true; + }; + }; + }; + environment.systemPackages = with pkgs; [ w3m-nographics # needed for the manual anyway testdisk # useful for repairing boot problems