update flake lock, update btrfs wipe GLaDOS, replace SDDM with plasma launch on EDI and GLaDOS

This commit is contained in:
Lillian Violet 2026-02-22 20:57:53 +01:00
parent c6d25885c1
commit 68a7950b5e
3 changed files with 61 additions and 32 deletions

18
flake.lock generated
View file

@ -389,11 +389,11 @@
]
},
"locked": {
"lastModified": 1771519029,
"narHash": "sha256-H59Qf82wv5kBXVoyXsmUKW+9J3o8FqgY4uKaLdsLdLg=",
"lastModified": 1771531206,
"narHash": "sha256-1R3Wx6KUkMb4x4E5UOhW9p6rqiexzSGGWxZqSHqW5n0=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "167e0b6837115e672ec5f58e2b0ea39093abe807",
"rev": "91be7cce763fa4022c7cf025a71b0c366d1b6e77",
"type": "github"
},
"original": {
@ -555,11 +555,11 @@
},
"nixpkgs-edge": {
"locked": {
"lastModified": 1771529647,
"narHash": "sha256-jg/CvWdnL3ZZhx58j8g1WDXJHALqiutiwnSyP4zPLj8=",
"lastModified": 1771539422,
"narHash": "sha256-TerWaqclKBZY7mWBEgA+7uwjSmpuWQ4QaOH7MTUkFkI=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "64a253ac18f1496577a30251a06c3871bdcaaa99",
"rev": "c4c6a8dea4a441e4cb2bdb5bc4266a6a9cce3859",
"type": "github"
},
"original": {
@ -906,11 +906,11 @@
"tinted-zed": "tinted-zed"
},
"locked": {
"lastModified": 1771428844,
"narHash": "sha256-rTzo6bZEsdT7yHUZ0B4BYe32XQZzm8SiWKvWLJnxerE=",
"lastModified": 1771536203,
"narHash": "sha256-ffSQmf7RZqCShzUkK4VlROGsBZy9tgKBYRQ5XQD0PiM=",
"owner": "nix-community",
"repo": "stylix",
"rev": "801843d10e9e22d7a00f660d069e2de70aa2980a",
"rev": "ec4d1ce9da22da964cef8a77795dc32011ebbb55",
"type": "github"
},
"original": {

View file

@ -42,9 +42,8 @@
virtualisation.spiceUSBRedirection.enable = true;
services.displayManager.sddm = {
services.displayManager.plasma-login-manager = {
enable = true;
wayland.enable = true;
};
services.displayManager.defaultSession = "plasma";

View file

@ -33,9 +33,8 @@
gparted
];
services.displayManager.sddm = {
services.displayManager.plasma-login-manager = {
enable = true;
wayland.enable = true;
};
services.displayManager.defaultSession = "plasma";
@ -76,14 +75,36 @@
# };
};
boot = {
# Nuke root AND home subvolumes on every boot
initrd.systemd.services.wipe-my-fs = {
requires = ["dev-mapper-nvme_crypted.device"];
after = ["dev-mapper-nvme_crypted.device"];
initrd.systemd.services.rollback = {
description = "Rollback BTRFS root subvolume to a pristine state";
unitConfig.DefaultDependencies = "no";
serviceConfig.Type = "oneshot";
wantedBy = ["initrd.target"];
after = ["systemd-cryptsetup@nvme_crypted.service"];
before = ["sysroot.mount"];
script = ''
echo "mounting btrfs volume to tmp..."
mkdir -p /btrfs_tmp
mount /dev/mapper/cryptroot /btrfs_tmp
mount /dev/mapper/nvme_crypted /btrfs_tmp
echo "mount successful!"
if [[ -e /btrfs_tmp/root ]]; then
echo "copying root to backup..."
mkdir -p /btrfs_tmp/old_roots
timestamp=$(date --date="@$(stat -c %Y /btrfs_tmp/root)" "+%Y-%m-%-d_%H:%M:%S")
mv /btrfs_tmp/root "/btrfs_tmp/old_roots/$timestamp"
echo "copy complete!"
fi
if [[ -e /btrfs_tmp/home ]]; then
echo "copying home to backup..."
mkdir -p /btrfs_tmp/old_homes
timestamp=$(date --date="@$(stat -c %Y /btrfs_tmp/home)" "+%Y-%m-%-d_%H:%M:%S")
mv /btrfs_tmp/home "/btrfs_tmp/old_homes/$timestamp"
"copy complete!"
fi
delete_subvolume_recursively() {
IFS=$'\n'
@ -93,15 +114,24 @@
btrfs subvolume delete "$1"
}
# Nuke and recreate root
delete_subvolume_recursively /btrfs_tmp/root
echo "recursively deleting root subvolumes older than five days..."
for i in $(find /btrfs_tmp/old_roots/ -maxdepth 1 -mtime +5); do
delete_subvolume_recursively "$i"
done
echo "subvolumes deleted!"
echo "recursively deleting home subvolumes older than five days..."
for i in $(find /btrfs_tmp/old_homes/ -maxdepth 1 -mtime +5); do
delete_subvolume_recursively "$i"
done
echo "subvolumes deleted!"
echo "creating new root and home subvolumes..."
btrfs subvolume create /btrfs_tmp/root
# Nuke and recreate home (wipes /home — but we restore via impermanence)
delete_subvolume_recursively /btrfs_tmp/home
btrfs subvolume create /btrfs_tmp/home
echo "unmounting btrfs temporary mount..."
umount /btrfs_tmp
echo "disk clear complete!"
'';
};