hosts: steamdeck: add initial config
This commit is contained in:
@@ -22,70 +22,76 @@
|
||||
boot.kernelModules = [ "kvm-amd" ];
|
||||
boot.kernelParams = [ ];
|
||||
boot.tmp.useTmpfs = true;
|
||||
zramSwap.enable = true;
|
||||
# zramSwap.enable = true;
|
||||
|
||||
services.btrfs.autoScrub = {
|
||||
enable = true;
|
||||
interval = "monthly";
|
||||
fileSystems = [
|
||||
"/"
|
||||
];
|
||||
};
|
||||
# services.btrfs.autoScrub = {
|
||||
# enable = true;
|
||||
# interval = "monthly";
|
||||
# fileSystems = [
|
||||
# "/"
|
||||
# ];
|
||||
# };
|
||||
#
|
||||
# services.btrbk = {
|
||||
# instances = {
|
||||
# hf = {
|
||||
# onCalendar = "hourly";
|
||||
# settings = {
|
||||
# incremental = "yes";
|
||||
# snapshot_create = "ondemand";
|
||||
# snapshot_dir = "@snapshots";
|
||||
# timestamp_format = "long";
|
||||
#
|
||||
# snapshot_preserve = "2m 2w 5d 5h";
|
||||
# snapshot_preserve_min = "latest";
|
||||
#
|
||||
# volume = {
|
||||
# "/mnt/snapshots/root" = {
|
||||
# snapshot_create = "always";
|
||||
# subvolume = {
|
||||
# "@home" = {};
|
||||
# };
|
||||
# };
|
||||
# };
|
||||
# };
|
||||
# };
|
||||
# };
|
||||
# };
|
||||
|
||||
services.btrbk = {
|
||||
instances = {
|
||||
hf = {
|
||||
onCalendar = "hourly";
|
||||
settings = {
|
||||
incremental = "yes";
|
||||
snapshot_create = "ondemand";
|
||||
snapshot_dir = "@snapshots";
|
||||
timestamp_format = "long";
|
||||
|
||||
snapshot_preserve = "2m 2w 5d 5h";
|
||||
snapshot_preserve_min = "latest";
|
||||
|
||||
volume = {
|
||||
"/mnt/snapshots/root" = {
|
||||
snapshot_create = "always";
|
||||
subvolume = {
|
||||
"@home" = {};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
# fileSystems."/" =
|
||||
# { device = "/dev/disk/by-label/NIXROOT";
|
||||
# fsType = "btrfs";
|
||||
# options = [ "compress=zstd,space_cache=v2,ssd,noatime,subvol=@,discard=async" ];
|
||||
# };
|
||||
#
|
||||
# fileSystems."/home" =
|
||||
# { device = "/dev/disk/by-label/NIXROOT";
|
||||
# fsType = "btrfs";
|
||||
# options = [ "compress=zstd,space_cache=v2,ssd,noatime,subvol=@home,discard=async" ];
|
||||
# };
|
||||
#
|
||||
# fileSystems."/srv" =
|
||||
# { device = "/dev/disk/by-label/NIXROOT";
|
||||
# fsType = "btrfs";
|
||||
# options = [ "compress=zstd,space_cache=v2,ssd,noatime,subvol=@srv,discard=async" ];
|
||||
# };
|
||||
#
|
||||
# fileSystems."/nix" =
|
||||
# { device = "/dev/disk/by-label/NIXROOT";
|
||||
# fsType = "btrfs";
|
||||
# options = [ "compress=zstd,space_cache=v2,ssd,noatime,subvol=@nix,discard=async" ];
|
||||
# };
|
||||
#
|
||||
# fileSystems."/mnt/snapshots/root" =
|
||||
# { device = "/dev/disk/by-label/NIXROOT";
|
||||
# fsType = "btrfs";
|
||||
# options = [ "compress=zstd,space_cache=v2,ssd,noatime,subvolid=5,discard=async" ];
|
||||
# };
|
||||
|
||||
fileSystems."/" =
|
||||
{ device = "/dev/disk/by-label/NIXROOT";
|
||||
fsType = "btrfs";
|
||||
options = [ "compress=zstd,space_cache=v2,ssd,noatime,subvol=@,discard=async" ];
|
||||
};
|
||||
|
||||
fileSystems."/home" =
|
||||
{ device = "/dev/disk/by-label/NIXROOT";
|
||||
fsType = "btrfs";
|
||||
options = [ "compress=zstd,space_cache=v2,ssd,noatime,subvol=@home,discard=async" ];
|
||||
};
|
||||
|
||||
fileSystems."/srv" =
|
||||
{ device = "/dev/disk/by-label/NIXROOT";
|
||||
fsType = "btrfs";
|
||||
options = [ "compress=zstd,space_cache=v2,ssd,noatime,subvol=@srv,discard=async" ];
|
||||
};
|
||||
|
||||
fileSystems."/nix" =
|
||||
{ device = "/dev/disk/by-label/NIXROOT";
|
||||
fsType = "btrfs";
|
||||
options = [ "compress=zstd,space_cache=v2,ssd,noatime,subvol=@nix,discard=async" ];
|
||||
};
|
||||
|
||||
fileSystems."/mnt/snapshots/root" =
|
||||
{ device = "/dev/disk/by-label/NIXROOT";
|
||||
fsType = "btrfs";
|
||||
options = [ "compress=zstd,space_cache=v2,ssd,noatime,subvolid=5,discard=async" ];
|
||||
fsType = "ext4";
|
||||
options = [ "defaults,noatime" ];
|
||||
};
|
||||
|
||||
fileSystems."/boot" =
|
||||
@@ -96,22 +102,21 @@
|
||||
fileSystems."/sdcard" =
|
||||
{ device = "/dev/disk/by-label/sdcard";
|
||||
fsType = "ext4";
|
||||
options = [ "nofail" "x-systemd.automount" ];
|
||||
options = [ "nofail,x-systemd.automount" ];
|
||||
};
|
||||
|
||||
fileSystems."/mnt/Pluto" =
|
||||
{ device = "nas:/Pluto";
|
||||
fsType = "nfs";
|
||||
options = [ "noauto,users,x-systemd.automount,x-systemd.device-timeout=10,soft,timeo=14,x-systemd.idle-timeout=1min,sec=sys,exec,nfsvers=4.2" ];
|
||||
options = [ "nofail,noauto,users,x-systemd.automount,x-systemd.device-timeout=10,soft,timeo=14,x-systemd.idle-timeout=1min,sec=sys,exec,nfsvers=4.2" ];
|
||||
};
|
||||
|
||||
fileSystems."/mnt/Mars" =
|
||||
{ device = "nas:/Mars";
|
||||
fsType = "nfs";
|
||||
options = [ "noauto,users,x-systemd.automount,x-systemd.device-timeout=10,soft,timeo=14,x-systemd.idle-timeout=1min,sec=sys,exec,nfsvers=4.2" ];
|
||||
options = [ "nofail,noauto,users,x-systemd.automount,x-systemd.device-timeout=10,soft,timeo=14,x-systemd.idle-timeout=1min,sec=sys,exec,nfsvers=4.2" ];
|
||||
};
|
||||
|
||||
|
||||
swapDevices = [
|
||||
{ device = "/dev/disk/by-label/NIXSWAP"; }
|
||||
];
|
||||
|
||||
Reference in New Issue
Block a user