+/config

my dotfiles and nix configuration

git clone https://git.julia.blue/+/config

Julia RyanFix my uid5101abf

main
662 B18 linesraw
1{ config, ... }: {
2  fileSystems = let
3    subvol = name: opts: {
4      label = config.networking.hostName; fsType = "btrfs";
5      options = [ "subvol=@${name}" ] ++ opts;
6    };
7  in {
8    "/"        = subvol "root" [ "compress=zstd" ];
9    "/nix"     = subvol "nix"  [ "compress=zstd" "noatime" ];
10    "/home"    = subvol "home" [ "compress=zstd" "user_subvol_rm_allowed" ]
11      // { neededForBoot = true; }; # for agenix to read my ssh identity
12    "/swap"    = subvol "swap" [ "noatime" ];
13    "/var/log" = subvol "log"  [ ];
14  };
15
16  swapDevices = [{ device = "/swap/swapfile"; }];
17  services.btrfs.autoScrub = { enable = true; fileSystems = [ "/" ]; };
18}