Add distrobox to laptop and fix ovh disks

This commit is contained in:
albert 2024-07-13 12:50:16 +09:00
parent 6f6ed14912
commit 1793439f0f
Signed by: albert
GPG key ID: 3895DD267CA11BA9
3 changed files with 124 additions and 114 deletions

View file

@ -82,7 +82,7 @@
# Servers # Servers
"albert@framework-server" = libx.mkHome { hostname = "framework-server"; }; "albert@framework-server" = libx.mkHome { hostname = "framework-server"; };
"albert@waraw-ovh-01" = libx.mkHome { hostname = "waraw-ovh-01"; }; "albert@warsaw-ovh-01" = libx.mkHome { hostname = "warsaw-ovh-01"; };
"albert@nuc-server" = libx.mkHome { hostname = "nuc-server"; }; "albert@nuc-server" = libx.mkHome { hostname = "nuc-server"; };
# User Machines # User Machines
@ -107,7 +107,7 @@
# Servers # Servers
framework-server = libx.deploy { hostname = "framework-server"; }; framework-server = libx.deploy { hostname = "framework-server"; };
ovh-server = libx.deploy { hostname = "ovh-server"; }; warsaw-ovh-01 = libx.deploy { hostname = "warsaw-ovh-01"; };
# nuc-server = libx.deploy { hostname = "nuc-server"; }; # nuc-server = libx.deploy { hostname = "nuc-server"; };
# Raspberry Pi's # Raspberry Pi's

View file

@ -81,5 +81,8 @@
# RGB stuff # RGB stuff
openrgb-with-all-plugins openrgb-with-all-plugins
rivalcfg rivalcfg
# Other
distrobox
]; ];
} }

View file

@ -13,127 +13,134 @@
services.btrfs.autoScrub.enable = true; services.btrfs.autoScrub.enable = true;
services.btrfs.autoScrub.interval = "weekly"; services.btrfs.autoScrub.interval = "weekly";
disko.devices.disk = { disko.devices = {
sdb = { disk = {
type = "disk"; sdb = {
device = "/dev/sdb"; type = "disk";
content = { device = "/dev/sdb";
type = "gpt"; content = {
partitions = { type = "gpt";
BOOT = { partitions = {
size = "1M"; BOOT = {
type = "EF02"; # GRUB MBR size = "1M";
}; type = "EF02"; # GRUB MBR
ESP = { };
size = "500M"; ESP = {
type = "EF00"; size = "500M";
content = { type = "EF00";
type = "mdraid"; content = {
name = "boot"; type = "mdraid";
name = "boot";
};
};
mdadm = {
size = "100%";
content = {
type = "mdraid";
name = "raid1";
};
}; };
}; };
mdadm = { };
size = "100%"; };
content = "mdraid";
name = "raid1"; sdc = {
type = "disk";
device = "/dev/sdc";
content = {
type = "gpt";
partitions = {
BOOT = {
size = "1M";
type = "EF02"; # GRUB MBR
};
ESP = {
size = "500M";
type = "EF00";
content = {
type = "mdraid";
name = "boot";
};
};
mdadm = {
size = "100%";
content = {
type = "mdraid";
name = "raid1";
};
};
}; };
}; };
}; };
}; };
sdc = { mdadm = {
type = "disk"; boot = {
device = "/dev/sdc"; type = "mdadm";
content = { level = 1;
type = "gpt"; metadata = "1.0";
partitions = { content = {
BOOT = { type = "filesystem";
size = "1M"; format = "vfat";
type = "EF02"; # GRUB MBR mountpoint = "/boot";
}; mountOptions = [ "umask=0077" ];
ESP = {
size = "500M";
type = "EF00";
content = {
type = "mdraid";
name = "boot";
};
};
mdadm = {
size = "100%";
content = "mdraid";
name = "raid1";
};
}; };
}; };
}; raid1 = {
}; type = "mdadm";
mdadm = { level = 1;
boot = { content = {
type = "mdadm"; type = "gpt";
level = 1; partitions = {
metadata = "1.0"; LUKS-ROOT = {
content = { start = "550MiB";
type = "Filesystem"; end = "100%";
format = "vfat";
mountpoint = "/boot";
mountOptions = [ "umask=0077" ];
};
};
raid1 = {
type = "mdadm";
level = 1;
content = {
type = "gpt";
partitions = {
LUKS-ROOT = {
start = "550MiB";
end = "100%";
content = {
type = "luks";
name = "ROOT";
extraOpenArgs = [ "--allow-discards" ];
content = { content = {
type = "btrfs"; type = "luks";
extraArgs = [ "-f" ]; name = "ROOT";
subvolumes = { extraOpenArgs = [ "--allow-discards" ];
"/root" = { content = {
mountpoint = "/"; type = "btrfs";
mountOptions = [ "compress=zstd" "noatime" ]; extraArgs = [ "-f" ];
}; # root subvolumes = {
"/home" = { "/root" = {
mountpoint = "/home"; mountpoint = "/";
mountOptions = [ "compress=zstd" "noatime" ]; mountOptions = [ "compress=zstd" "noatime" ];
}; # home }; # root
"/nix" = { "/home" = {
mountpoint = "/nix"; mountpoint = "/home";
mountOptions = [ "compress=zstd" "noatime" ]; mountOptions = [ "compress=zstd" "noatime" ];
}; # nix }; # home
"/Storage" = { "/nix" = {
mountpoint = "/Storage"; mountpoint = "/nix";
mountOptions = [ "compress=zstd" "noatime" ]; mountOptions = [ "compress=zstd" "noatime" ];
}; # Storage }; # nix
# SNAPSHOT SUBVOLS "/Storage" = {
"/root/.snapshots" = { mountpoint = "/Storage";
mountpoint = "/.snapshots"; mountOptions = [ "compress=zstd" "noatime" ];
mountOptions = [ "compress=zstd" "noatime" ]; }; # Storage
}; # root # SNAPSHOT SUBVOLS
"/home/.snapshots" = { "/root/.snapshots" = {
mountpoint = "/home/.snapshots"; mountpoint = "/.snapshots";
mountOptions = [ "compress=zstd" "noatime" ]; mountOptions = [ "compress=zstd" "noatime" ];
}; # home }; # root
"/nix/.snapshots" = { "/home/.snapshots" = {
mountpoint = "/nix/.snapshots"; mountpoint = "/home/.snapshots";
mountOptions = [ "compress=zstd" "noatime" ]; mountOptions = [ "compress=zstd" "noatime" ];
}; # nix }; # home
"/Storage/.snapshots" = { "/nix/.snapshots" = {
mountpoint = "/Storage/.snapshots"; mountpoint = "/nix/.snapshots";
mountOptions = [ "compress=zstd" "noatime" ]; mountOptions = [ "compress=zstd" "noatime" ];
}; # Storage }; # nix
}; # subvolumes "/Storage/.snapshots" = {
}; # content.content mountpoint = "/Storage/.snapshots";
}; # content mountOptions = [ "compress=zstd" "noatime" ];
}; # partition 2 (/ BTRFS) }; # Storage
}; # subvolumes
}; # content.content
}; # content
}; # partition 2 (/ BTRFS)
};
}; };
}; };
}; };