Compare commits

..

8 commits

11 changed files with 151 additions and 62 deletions

View file

@ -49,6 +49,14 @@ cryptsetup open /dev/disk/by-label/NIXCRYPTFS crypfs
mkfs.btrfs -L NIXFS /dev/mapper/cryptfs
```
> [!NOTE]
> For the LUKS encrypted partitions, I'd heavily recommend that you back up the LUKS headers in case of a partial drive failure, so that you're still
> able to recover your remaining data. To do this, you can use the following command:
>
> ```bash
> cryptsetup luksHeaderBackup /dev/device --header-backup-file /mnt/backup/file.img
> ```
### BTRFS Subvolumes
Now we will split our btrfs partition into the following subvolumes:

View file

@ -132,11 +132,11 @@
]
},
"locked": {
"lastModified": 1719994518,
"narHash": "sha256-pQMhCCHyQGRzdfAkdJ4cIWiw+JNuWsTX7f0ZYSyz0VY=",
"lastModified": 1725234343,
"narHash": "sha256-+ebgonl3NbiKD2UD0x4BszCZQ6sTfL4xioaM49o5B3Y=",
"owner": "hercules-ci",
"repo": "flake-parts",
"rev": "9227223f6d922fee3c7b190b2cc238a99527bbb7",
"rev": "567b938d64d4b4112ee253b9274472dc3a346eb6",
"type": "github"
},
"original": {
@ -153,11 +153,11 @@
]
},
"locked": {
"lastModified": 1717285511,
"narHash": "sha256-iKzJcpdXih14qYVcZ9QC9XuZYnPc6T8YImb6dX166kw=",
"lastModified": 1722555600,
"narHash": "sha256-XOQkdLafnb/p9ij77byFQjDf5m5QYl9b2REiVClC+x4=",
"owner": "hercules-ci",
"repo": "flake-parts",
"rev": "2a55567fcf15b1b1c7ed712a2c6fadaec7412ea8",
"rev": "8471fe90ad337a8074e957b69ca4d0089218391d",
"type": "github"
},
"original": {
@ -257,11 +257,11 @@
]
},
"locked": {
"lastModified": 1719226092,
"narHash": "sha256-YNkUMcCUCpnULp40g+svYsaH1RbSEj6s4WdZY/SHe38=",
"lastModified": 1724947644,
"narHash": "sha256-MHHrHasTngp7EYQOObHJ1a/IsRF+wodHqOckhH6uZbk=",
"owner": "hercules-ci",
"repo": "hercules-ci-effects",
"rev": "11e4b8dc112e2f485d7c97e1cee77f9958f498f5",
"rev": "dba4367b9a9d9615456c430a6d6af716f6e84cef",
"type": "github"
},
"original": {
@ -284,11 +284,11 @@
]
},
"locked": {
"lastModified": 1713898448,
"narHash": "sha256-6q6ojsp/Z9P2goqnxyfCSzFOD92T3Uobmj8oVAicUOs=",
"lastModified": 1719226092,
"narHash": "sha256-YNkUMcCUCpnULp40g+svYsaH1RbSEj6s4WdZY/SHe38=",
"owner": "hercules-ci",
"repo": "hercules-ci-effects",
"rev": "c0302ec12d569532a6b6bd218f698bc402e93adc",
"rev": "11e4b8dc112e2f485d7c97e1cee77f9958f498f5",
"type": "github"
},
"original": {
@ -303,6 +303,27 @@
"nixpkgs"
]
},
"locked": {
"lastModified": 1725948275,
"narHash": "sha256-4QOPemDQ9VRLQaAdWuvdDBhh+lEUOAnSMHhdr4nS1mk=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "e5fa72bad0c6f533e8d558182529ee2acc9454fe",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "home-manager",
"type": "github"
}
},
"home-manager_2": {
"inputs": {
"nixpkgs": [
"schizofox",
"nixpkgs"
]
},
"locked": {
"lastModified": 1723015306,
"narHash": "sha256-jQnFEtH20/OsDPpx71ntZzGdRlpXhUENSQCGTjn//NA=",
@ -317,34 +338,13 @@
"type": "github"
}
},
"home-manager_2": {
"inputs": {
"nixpkgs": [
"schizofox",
"nixpkgs"
]
},
"locked": {
"lastModified": 1717097707,
"narHash": "sha256-HC5vJ3oYsjwsCaSbkIPv80e4ebJpNvFKQTBOGlHvjLs=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "0eb314b4f0ba337e88123e0b1e57ef58346aafd9",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "home-manager",
"type": "github"
}
},
"impermanence": {
"locked": {
"lastModified": 1719091691,
"narHash": "sha256-AxaLX5cBEcGtE02PeGsfscSb/fWMnyS7zMWBXQWDKbE=",
"lastModified": 1725690722,
"narHash": "sha256-4qWg9sNh5g1qPGO6d/GV2ktY+eDikkBTbWSg5/iD2nY=",
"owner": "nix-community",
"repo": "impermanence",
"rev": "23c1f06316b67cb5dabdfe2973da3785cfe9c34a",
"rev": "63f4d0443e32b0dd7189001ee1894066765d18a5",
"type": "github"
},
"original": {
@ -389,11 +389,11 @@
]
},
"locked": {
"lastModified": 1722479120,
"narHash": "sha256-P0fXZvYT56dKd5Zjuao4uQqgw9YFZ5AE2V31f4iluXI=",
"lastModified": 1725503605,
"narHash": "sha256-P/3wqoBMbQfjEtweRIzUBRWL7yj52ODsVPMinvOCFhQ=",
"owner": "nixpak",
"repo": "nixpak",
"rev": "c53bd63c6851f6972fb1f1f192e608775fb54a9f",
"rev": "baa4b365dd20aa5b56f73bc446e2970a3089c145",
"type": "github"
},
"original": {
@ -415,11 +415,11 @@
]
},
"locked": {
"lastModified": 1717036060,
"narHash": "sha256-Bm1pBy1goxIz9PD0PRJ9ZgQzl7MQOQ6n5IB4wLNdXrA=",
"lastModified": 1723083542,
"narHash": "sha256-Nkbb3j+P0zMqvZUlV6WbT5erHasZ14NW0TJS3Bb9dVY=",
"owner": "nixpak",
"repo": "nixpak",
"rev": "3a68b5453f75b1c8e5d31859a654e061a57dc059",
"rev": "d36970c58794c90401617accae0eb48868e335e6",
"type": "github"
},
"original": {
@ -430,11 +430,11 @@
},
"nixpkgs": {
"locked": {
"lastModified": 1722813957,
"narHash": "sha256-IAoYyYnED7P8zrBFMnmp7ydaJfwTnwcnqxUElC1I26Y=",
"lastModified": 1725634671,
"narHash": "sha256-v3rIhsJBOMLR8e/RNWxr828tB+WywYIoajrZKFM+0Gg=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "cb9a96f23c491c081b38eab96d22fa958043c9fa",
"rev": "574d1eac1c200690e27b8eb4e24887f8df7ac27c",
"type": "github"
},
"original": {
@ -559,11 +559,11 @@
"systems": "systems_2"
},
"locked": {
"lastModified": 1722689807,
"narHash": "sha256-8YZ2T0o2bcSaXmEbuxIhbb7u4MpVSU7BGdgPpLy6RNk=",
"lastModified": 1725210690,
"narHash": "sha256-iCGXWHn7MeU3uKLw0bQyyl3rvIN7/X2bxZ7buqZgNvU=",
"owner": "schizofox",
"repo": "schizofox",
"rev": "cd6fbdda984644176ad45bfb4ecfb61fd190b95d",
"rev": "4c554d44b73823d820bb6add4c12411e0ffecd80",
"type": "github"
},
"original": {
@ -603,11 +603,11 @@
]
},
"locked": {
"lastModified": 1723004010,
"narHash": "sha256-9NaGh1bUlIWrRJXY3qTmX5IFa+5xEP2wf8J0DCi/Wxs=",
"lastModified": 1725941773,
"narHash": "sha256-pvjDesWV1L9LgiqKT1JUlviVFMcH3jVOm/wjt/uqIpg=",
"owner": "Gerg-L",
"repo": "spicetify-nix",
"rev": "5a4a301de746e16851165b0da8ab6d38ed37b8dd",
"rev": "26955b675c39338e4e1963eaa1f5405890e63fb8",
"type": "github"
},
"original": {
@ -654,11 +654,11 @@
]
},
"locked": {
"lastModified": 1723046394,
"narHash": "sha256-WvUtvAfuhTL128OIDGgRcKjXkqbLkyypG711nlGmMNw=",
"lastModified": 1725430478,
"narHash": "sha256-W30JZlSiFIUALwFtjIDG5E6LtuUTjHvAVrNlKpuSEt0=",
"owner": "abenz1267",
"repo": "walker",
"rev": "bb2f7fa6a01ec92388e992cc9a8348e72fa00622",
"rev": "e4a58cd93691d3d9ace67a691bd74d54032c89b0",
"type": "github"
},
"original": {

View file

@ -1,5 +1,6 @@
_: {
imports = [
./prismlauncher.nix
./lutris.nix
];
}

View file

@ -0,0 +1,19 @@
{
lib,
pkgs,
osConfig,
...
}: let
inherit (lib) mkIf;
cfg = osConfig.myOptions.home-manager.programs.games.lutris;
in {
config = mkIf cfg.enable {
home.packages = with pkgs; [
lutris.override
{
extraPkgs = pkgs: [];
}
];
};
}

View file

@ -92,7 +92,6 @@
#
# Jetbrains
"windowdance, class:^(jetbrains-.*)$,floating:1"
"center, class:^(jetbrains-.*)$,title:^(splash)$,floating:1"
"nofocus, class:^(jetbrains-.*)$,title:^(splash)$,floating:1"
"noborder, class:^(jetbrains-.*)$,title:^(splash)$,floating:1"

View file

@ -1,26 +1,57 @@
{pkgs, ...}: {
# TODO: Consider switching to nixvim
programs.neovim = {
enable = true;
viAlias = true;
vimAlias = true;
# Packages required for:
#
# - Mason to build various language servers / linters / formatters from source
# - Runtime dependencies of plugins / lang servers / ...
withNodeJs = true;
withPython3 = true;
extraPackages = with pkgs; [
# Tools for building Mason packages
go
python3
rustc
cargo
gcc
cmake
gnumake
# lang servers
lua-language-server
rust-analyzer
taplo
gopls
marksman
yaml-language-server
ruff
neocmakelsp
bash-language-server
nixd
# Linters / formatters
stylua
shfmt
gofumpt
gotools
sqlfluff
hadolint
markdownlint-cli2
nodePackages.prettier
shellcheck
shfmt
alejandra
deadnix
statix
alejandra
nixd
# Other tools / utilities
ripgrep
fd
jq
lazygit
];
};
}

View file

@ -37,6 +37,7 @@
username = "itsdrike";
sound.enable = true;
docker.enable = true;
impermanence = {
root = {
@ -48,6 +49,7 @@
extraDirectories = [
"/var/log"
"/var/lib/docker"
];
};
@ -86,6 +88,8 @@
".config/github-copilot"
".config/ipython"
".cache/pre-commit"
".cache/venv-selector"
".local/share/direnv"
# Services
".local/state/wireplumber" # volume settings
@ -231,6 +235,7 @@
};
games = {
steam.enable = true;
lutris.enable = true;
prismlauncher.enable = true;
};
};

View file

@ -65,6 +65,7 @@ in {
games = {
steam.enable = mkEnableOption "Steam client";
lutris.enable = mkEnableOption "Lutris (Open Gaming Platform for Linux)";
prismlauncher.enable = mkEnableOption "PrismLauncher";
};

View file

@ -1,6 +1,5 @@
{lib, ...}:
with lib; let
inherit (lib) mkOption;
{lib, ...}: let
inherit (lib) mkOption mkEnableOption types;
in {
imports = [
./boot
@ -21,5 +20,14 @@ in {
sound = {
enable = mkEnableOption "sound related programs and audio-dependent programs";
};
docker = {
enable = mkEnableOption "docker virtualisation platform";
data-root = mkOption {
type = types.str;
description = "Path to the directory where docker data should be stored";
default = "/var/lib/docker";
};
};
};
}

View file

@ -7,5 +7,6 @@ _: {
./thermald.nix
./journald.nix
./fstrim.nix
./docker.nix
];
}

View file

@ -0,0 +1,16 @@
{
lib,
config,
...
}: let
cfg = config.myOptions.system.docker;
in {
config = lib.mkIf cfg.enable {
virtualisation.docker = {
enable = true;
storageDriver = "btrfs";
daemon.settings.data-root = cfg.data-root;
};
};
}