summaryrefslogtreecommitdiff
path: root/modules/nixos/nix-common.nix
blob: a3d291b466b7016e95db0722d27233a82de18349 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
{ config, pkgs, ... }: {
  
  nix = {
    settings = {
      # Users allowed to run nix
      allowed-users = [ "root" "@wheel" "@builders" "@video" ];
      experimental-features = [ "nix-command" "flakes" ];
      extra-substituters = [ "https://cache.lix.systems" ];
      trusted-public-keys = [ "cache.lix.systems:aBnZUw8zA7H35Cz2RyKFVs3H4PlGTLawyY5KRbvJR8o=" ];
    };

    # Clean up old generations after 30 days
    gc = {
      automatic = true;
      dates = "weekly";
      options = "--delete-older-than 30d";
    };
  };
}