Skip to content

Commit

Permalink
feat(cache): add garbage collection
Browse files Browse the repository at this point in the history
  • Loading branch information
klarkc committed Dec 21, 2023
1 parent 2a3e03c commit f5e082c
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions setups/cache/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,16 @@ let
age.secrets.cache.file = "${secrets}/cache.age";
system.stateVersion = config.system.nixos.version;
boot.loader.systemd-boot.enable = true;
# nix-serve
networking.firewall.enable = false;
# cache service
services.nix-serve = {
enable = true;
secretKeyFile = config.age.secrets.cache.path;
};
networking.firewall.enable = false;
nix.extraOptions = ''
min-free = 2684354560
max-free = 5368709120
'';
# SSH
services.sshd.enable = true;
users.users.root.openssh = { inherit authorizedKeys; };
Expand Down Expand Up @@ -78,9 +82,10 @@ let
content = {
type = "btrfs";
extraArgs = [
"--label" "root"
"--label"
"root"
"-f" # Override existing partition
];
];
# Subvolumes must set a mountpoint in order to be mounted,
# unless their parent is mounted
subvolumes = {
Expand Down

0 comments on commit f5e082c

Please sign in to comment.