diff --git a/flake.lock b/flake.lock index c438086..3242525 100644 --- a/flake.lock +++ b/flake.lock @@ -2,20 +2,14 @@ "nodes": { "catppuccin": { "inputs": { - "catppuccin-v1_1": "catppuccin-v1_1", - "catppuccin-v1_2": "catppuccin-v1_2", - "home-manager": "home-manager", - "home-manager-stable": "home-manager-stable", - "nixpkgs": "nixpkgs", - "nixpkgs-stable": "nixpkgs-stable", - "nuscht-search": "nuscht-search" + "nixpkgs": "nixpkgs" }, "locked": { - "lastModified": 1736957255, - "narHash": "sha256-qZZ/K5XheRMjCNYgle90QESuys0PIFJNPJJswMJ0GEA=", + "lastModified": 1739934729, + "narHash": "sha256-PcrLk10meIJICzUJqtCMOJxoITzbH52fZg2XAB7SSsM=", "owner": "catppuccin", "repo": "nix", - "rev": "f06fcadf9a61b6581b392e72f230fa6783fe36e4", + "rev": "b1ff2a638afa827f1473498190a2c1cae1cf41cf", "type": "github" }, "original": { @@ -24,34 +18,6 @@ "type": "github" } }, - "catppuccin-v1_1": { - "locked": { - "lastModified": 1734055249, - "narHash": "sha256-pCWJgwo77KD7EJpwynwKrWPZ//dwypHq2TfdzZWqK68=", - "rev": "7221d6ca17ac36ed20588e1c3a80177ac5843fa7", - "revCount": 326, - "type": "tarball", - "url": "https://api.flakehub.com/f/pinned/catppuccin/nix/1.1.1/0193bdc0-b045-7eed-bbec-95611a8ecdf5/source.tar.gz" - }, - "original": { - "type": "tarball", - "url": "https://flakehub.com/f/catppuccin/nix/1.1.%2A.tar.gz" - } - }, - "catppuccin-v1_2": { - "locked": { - "lastModified": 1734734291, - "narHash": "sha256-CFX4diEQHKvZYjnhf7TLg20m3ge1O4vqgplsk/Kuaek=", - "rev": "1e4c3803b8da874ff75224ec8512cb173036bbd8", - "revCount": 344, - "type": "tarball", - "url": "https://api.flakehub.com/f/pinned/catppuccin/nix/1.2.1/0193e646-1107-7f69-a402-f2a3988ecf1d/source.tar.gz" - }, - "original": { - "type": "tarball", - "url": "https://flakehub.com/f/catppuccin/nix/1.2.%2A.tar.gz" - } - }, "commonmark-simple": { "flake": false, "locked": { @@ -71,11 +37,11 @@ "commonmark-wikilink": { "flake": false, "locked": { - "lastModified": 1711394028, - "narHash": "sha256-eu5gMmgRz6Y51TBCaB26uJKNN3z1LRfUcTV4+PMy5Gw=", + "lastModified": 1738248145, + "narHash": "sha256-UN2Nh+uf+DzM336Ojzr6YZV4RJy8BPx9Q5GZpax3wt0=", "owner": "srid", "repo": "commonmark-wikilink", - "rev": "57dcf665082ffc1b6f35a427e203ed115821b15c", + "rev": "1d7aa327fb33b41f3c4899d5b29aa122780c900f", "type": "github" }, "original": { @@ -85,18 +51,12 @@ } }, "crane": { - "inputs": { - "nixpkgs": [ - "lanzaboote", - "nixpkgs" - ] - }, "locked": { - "lastModified": 1717535930, - "narHash": "sha256-1hZ/txnbd/RmiBPNUs7i8UQw2N89uAK3UzrGAWdnFfU=", + "lastModified": 1731098351, + "narHash": "sha256-HQkYvKvaLQqNa10KEFGgWHfMAbWBfFp+4cAgkut+NNE=", "owner": "ipetkov", "repo": "crane", - "rev": "55e7754ec31dac78980c8be45f8a28e80e370946", + "rev": "ef80ead953c1b28316cc3f8613904edc2eb90c28", "type": "github" }, "original": { @@ -105,14 +65,34 @@ "type": "github" } }, + "disko": { + "inputs": { + "nixpkgs": [ + "nixos-unstable" + ] + }, + "locked": { + "lastModified": 1739841949, + "narHash": "sha256-lSOXdgW/1zi/SSu7xp71v+55D5Egz8ACv0STkj7fhbs=", + "owner": "nix-community", + "repo": "disko", + "rev": "15dbf8cebd8e2655a883b74547108e089f051bf0", + "type": "github" + }, + "original": { + "owner": "nix-community", + "repo": "disko", + "type": "github" + } + }, "ema": { "flake": false, "locked": { - "lastModified": 1724260267, - "narHash": "sha256-pxTlvpK0l7pek43FIz6KYAazK0BWbnuBJSFrcShVoWE=", + "lastModified": 1738428103, + "narHash": "sha256-vZgaNI0y6IKnWDSLFsl7mwSUZ3ONgduclQkB6WK0VMo=", "owner": "srid", "repo": "ema", - "rev": "16e2752267cd49027e281409daa25b6ecba68fd3", + "rev": "4478e88d33126ef0b478b2980a71592b8f9afd6b", "type": "github" }, "original": { @@ -133,17 +113,17 @@ "heist-extra": "heist-extra", "nixos-unified": "nixos-unified", "nixpkgs": [ - "nixpkgs-unstable" + "nixos-unstable" ], "treefmt-nix": "treefmt-nix", "unionmount": "unionmount" }, "locked": { - "lastModified": 1736358771, - "narHash": "sha256-6vRvRWoYAKVquR/3w6ztay1f4xusyV8ms2V8Zp/N6wo=", + "lastModified": 1739923609, + "narHash": "sha256-ZKdpDTsVUoxBiqyXqvkM1Klr6oc4ORCqX1nlm5EW05E=", "owner": "srid", "repo": "emanote", - "rev": "708306717d9d9fd0edb4aebe68f7ffea22ddb7ec", + "rev": "6a4295cd7fad530beafe8aa45bdaf0693254b3c0", "type": "github" }, "original": { @@ -155,7 +135,7 @@ "fcc-unlock": { "inputs": { "nixpkgs": [ - "nixpkgs-stable" + "nixos-unstable" ] }, "locked": { @@ -217,11 +197,11 @@ ] }, "locked": { - "lastModified": 1717285511, - "narHash": "sha256-iKzJcpdXih14qYVcZ9QC9XuZYnPc6T8YImb6dX166kw=", + "lastModified": 1730504689, + "narHash": "sha256-hgmguH29K2fvs9szpq2r3pz2/8cJd2LPS+b4tfNFCwE=", "owner": "hercules-ci", "repo": "flake-parts", - "rev": "2a55567fcf15b1b1c7ed712a2c6fadaec7412ea8", + "rev": "506278e768c2a08bec68eb62932193e341f55c90", "type": "github" }, "original": { @@ -245,42 +225,6 @@ "type": "github" } }, - "flake-utils": { - "inputs": { - "systems": "systems" - }, - "locked": { - "lastModified": 1731533236, - "narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "11707dc2f618dd54ca8739b309ec4fc024de578b", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, - "flake-utils_2": { - "inputs": { - "systems": "systems_2" - }, - "locked": { - "lastModified": 1710146030, - "narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "gitignore": { "inputs": { "nixpkgs": [ @@ -321,11 +265,11 @@ "heist-extra": { "flake": false, "locked": { - "lastModified": 1710541479, - "narHash": "sha256-9e4U78eutom6D3EJqsCdV8iQxNgYA/pi001r5CZdm0A=", + "lastModified": 1737313814, + "narHash": "sha256-WCXhs/xhCR4CKBEadQjqqgUb47bLzDY7P7oL5cSgDHc=", "owner": "srid", "repo": "heist-extra", - "rev": "589b7636f620dcdfc0dc07dea720feed1ab3e0fa", + "rev": "6f73e000a34b7c054b516b9504b5a7ed08ce6a2d", "type": "github" }, "original": { @@ -337,58 +281,15 @@ "home-manager": { "inputs": { "nixpkgs": [ - "catppuccin", - "nixpkgs" + "nixos-unstable" ] }, "locked": { - "lastModified": 1736508663, - "narHash": "sha256-ZOaGwa+WnB7Zn3YXimqjmIugAnHePdXCmNu+AHkq808=", + "lastModified": 1739913864, + "narHash": "sha256-WhzgQjadrwnwPJQLLxZUUEIxojxa7UWDkf7raAkB1Lw=", "owner": "nix-community", "repo": "home-manager", - "rev": "2532b500c3ed2b8940e831039dcec5a5ea093afc", - "type": "github" - }, - "original": { - "owner": "nix-community", - "repo": "home-manager", - "type": "github" - } - }, - "home-manager-stable": { - "inputs": { - "nixpkgs": [ - "catppuccin", - "nixpkgs-stable" - ] - }, - "locked": { - "lastModified": 1736373539, - "narHash": "sha256-dinzAqCjenWDxuy+MqUQq0I4zUSfaCvN9rzuCmgMZJY=", - "owner": "nix-community", - "repo": "home-manager", - "rev": "bd65bc3cde04c16755955630b344bc9e35272c56", - "type": "github" - }, - "original": { - "owner": "nix-community", - "ref": "release-24.11", - "repo": "home-manager", - "type": "github" - } - }, - "home-manager_2": { - "inputs": { - "nixpkgs": [ - "nixpkgs-stable" - ] - }, - "locked": { - "lastModified": 1736785676, - "narHash": "sha256-TY0jUwR3EW0fnS0X5wXMAVy6h4Z7Y6a3m+Yq++C9AyE=", - "owner": "nix-community", - "repo": "home-manager", - "rev": "fc52a210b60f2f52c74eac41a8647c1573d2071d", + "rev": "97ac0801d187b2911e8caa45316399de12f6f199", "type": "github" }, "original": { @@ -398,68 +299,39 @@ "type": "github" } }, - "ixx": { - "inputs": { - "flake-utils": [ - "catppuccin", - "nuscht-search", - "flake-utils" - ], - "nixpkgs": [ - "catppuccin", - "nuscht-search", - "nixpkgs" - ] - }, - "locked": { - "lastModified": 1729958008, - "narHash": "sha256-EiOq8jF4Z/zQe0QYVc3+qSKxRK//CFHMB84aYrYGwEs=", - "owner": "NuschtOS", - "repo": "ixx", - "rev": "9fd01aad037f345350eab2cd45e1946cc66da4eb", - "type": "github" - }, - "original": { - "owner": "NuschtOS", - "ref": "v0.0.6", - "repo": "ixx", - "type": "github" - } - }, "lanzaboote": { "inputs": { "crane": "crane", "flake-compat": "flake-compat", "flake-parts": "flake-parts_2", - "flake-utils": "flake-utils_2", "nixpkgs": [ - "nixpkgs-unstable" + "nixos-unstable" ], "pre-commit-hooks-nix": "pre-commit-hooks-nix", "rust-overlay": "rust-overlay" }, "locked": { - "lastModified": 1718178907, - "narHash": "sha256-eSZyrQ9uoPB9iPQ8Y5H7gAmAgAvCw3InStmU3oEjqsE=", + "lastModified": 1737639419, + "narHash": "sha256-AEEDktApTEZ5PZXNDkry2YV2k6t0dTgLPEmAZbnigXU=", "owner": "nix-community", "repo": "lanzaboote", - "rev": "b627ccd97d0159214cee5c7db1412b75e4be6086", + "rev": "a65905a09e2c43ff63be8c0e86a93712361f871e", "type": "github" }, "original": { "owner": "nix-community", - "ref": "v0.4.1", + "ref": "v0.4.2", "repo": "lanzaboote", "type": "github" } }, "nixos-hardware": { "locked": { - "lastModified": 1736978406, - "narHash": "sha256-oMr3PVIQ8XPDI8/x6BHxsWEPBRU98Pam6KGVwUh8MPk=", + "lastModified": 1739798439, + "narHash": "sha256-GyipmjbbQEaosel/+wq1xihCKbv0/e1LU00x/8b/fP4=", "owner": "NixOS", "repo": "nixos-hardware", - "rev": "b678606690027913f3434dea3864e712b862dde5", + "rev": "3e2ea8a49d4d76276b0f4e2041df8ca5c0771371", "type": "github" }, "original": { @@ -483,6 +355,22 @@ "type": "github" } }, + "nixos-unstable": { + "locked": { + "lastModified": 1739866667, + "narHash": "sha256-EO1ygNKZlsAC9avfcwHkKGMsmipUk1Uc0TbrEZpkn64=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "73cf49b8ad837ade2de76f87eb53fc85ed5d4680", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, "nixpkgs": { "locked": { "lastModified": 1736012469, @@ -501,91 +389,20 @@ }, "nixpkgs-stable": { "locked": { - "lastModified": 1736061677, - "narHash": "sha256-DjkQPnkAfd7eB522PwnkGhOMuT9QVCZspDpJJYyOj60=", + "lastModified": 1730741070, + "narHash": "sha256-edm8WG19kWozJ/GqyYx2VjW99EdhjKwbY3ZwdlPAAlo=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "cbd8ec4de4469333c82ff40d057350c30e9f7d36", + "rev": "d063c1dd113c91ab27959ba540c0d9753409edf3", "type": "github" }, "original": { "owner": "NixOS", - "ref": "nixos-24.11", + "ref": "nixos-24.05", "repo": "nixpkgs", "type": "github" } }, - "nixpkgs-stable_2": { - "locked": { - "lastModified": 1710695816, - "narHash": "sha256-3Eh7fhEID17pv9ZxrPwCLfqXnYP006RKzSs0JptsN84=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "614b4613980a522ba49f0d194531beddbb7220d3", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixos-23.11", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs-stable_3": { - "locked": { - "lastModified": 1736883708, - "narHash": "sha256-uQ+NQ0/xYU0N1CnXsa2zghgNaOPxWpMJXSUJJ9W7140=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "eb62e6aa39ea67e0b8018ba8ea077efe65807dc8", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixos-unstable", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs-unstable": { - "locked": { - "lastModified": 1736883708, - "narHash": "sha256-uQ+NQ0/xYU0N1CnXsa2zghgNaOPxWpMJXSUJJ9W7140=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "eb62e6aa39ea67e0b8018ba8ea077efe65807dc8", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixos-unstable", - "repo": "nixpkgs", - "type": "github" - } - }, - "nuscht-search": { - "inputs": { - "flake-utils": "flake-utils", - "ixx": "ixx", - "nixpkgs": [ - "catppuccin", - "nixpkgs" - ] - }, - "locked": { - "lastModified": 1735854821, - "narHash": "sha256-Iv59gMDZajNfezTO0Fw6LHE7uKAShxbvMidmZREit7c=", - "owner": "NuschtOS", - "repo": "search", - "rev": "836908e3bddd837ae0f13e215dd48767aee355f0", - "type": "github" - }, - "original": { - "owner": "NuschtOS", - "repo": "search", - "type": "github" - } - }, "pre-commit-hooks-nix": { "inputs": { "flake-compat": [ @@ -597,14 +414,14 @@ "lanzaboote", "nixpkgs" ], - "nixpkgs-stable": "nixpkgs-stable_2" + "nixpkgs-stable": "nixpkgs-stable" }, "locked": { - "lastModified": 1717664902, - "narHash": "sha256-7XfBuLULizXjXfBYy/VV+SpYMHreNRHk9nKMsm1bgb4=", + "lastModified": 1731363552, + "narHash": "sha256-vFta1uHnD29VUY4HJOO/D6p6rxyObnf+InnSMT4jlMU=", "owner": "cachix", "repo": "pre-commit-hooks.nix", - "rev": "cc4d466cb1254af050ff7bdf47f6d404a7c646d1", + "rev": "cd1af27aa85026ac759d5d3fccf650abe7e1bbf0", "type": "github" }, "original": { @@ -616,40 +433,36 @@ "root": { "inputs": { "catppuccin": "catppuccin", + "disko": "disko", "emanote": "emanote", "fcc-unlock": "fcc-unlock", "flake-parts": [ "emanote", "flake-parts" ], - "home-manager": "home-manager_2", + "home-manager": "home-manager", "lanzaboote": "lanzaboote", "nixos-hardware": "nixos-hardware", + "nixos-unstable": "nixos-unstable", "nixpkgs": [ "emanote", "nixpkgs" - ], - "nixpkgs-stable": "nixpkgs-stable_3", - "nixpkgs-unstable": "nixpkgs-unstable" + ] } }, "rust-overlay": { "inputs": { - "flake-utils": [ - "lanzaboote", - "flake-utils" - ], "nixpkgs": [ "lanzaboote", "nixpkgs" ] }, "locked": { - "lastModified": 1717813066, - "narHash": "sha256-wqbRwq3i7g5EHIui0bIi84mdqZ/It1AXBSLJ5tafD28=", + "lastModified": 1731897198, + "narHash": "sha256-Ou7vLETSKwmE/HRQz4cImXXJBr/k9gp4J4z/PF8LzTE=", "owner": "oxalica", "repo": "rust-overlay", - "rev": "6dc3e45fe4aee36efeed24d64fc68b1f989d5465", + "rev": "0be641045af6d8666c11c2c40e45ffc9667839b5", "type": "github" }, "original": { @@ -658,36 +471,6 @@ "type": "github" } }, - "systems": { - "locked": { - "lastModified": 1681028828, - "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", - "owner": "nix-systems", - "repo": "default", - "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", - "type": "github" - }, - "original": { - "owner": "nix-systems", - "repo": "default", - "type": "github" - } - }, - "systems_2": { - "locked": { - "lastModified": 1681028828, - "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", - "owner": "nix-systems", - "repo": "default", - "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", - "type": "github" - }, - "original": { - "owner": "nix-systems", - "repo": "default", - "type": "github" - } - }, "treefmt-nix": { "inputs": { "nixpkgs": [ diff --git a/flake.nix b/flake.nix index c24a0cd..ba4318c 100644 --- a/flake.nix +++ b/flake.nix @@ -11,31 +11,35 @@ inputs = { # Upstream deps - nixpkgs-unstable.url = "github:NixOS/nixpkgs/nixos-unstable"; - nixpkgs-stable.url = "github:NixOS/nixpkgs/nixos-unstable"; + nixos-unstable.url = "github:NixOS/nixpkgs/nixos-unstable"; nixos-hardware.url = "github:NixOS/nixos-hardware"; lanzaboote = { - url = "github:nix-community/lanzaboote/v0.4.1"; - inputs.nixpkgs.follows = "nixpkgs-unstable"; + url = "github:nix-community/lanzaboote/v0.4.2"; + inputs.nixpkgs.follows = "nixos-unstable"; + }; + + disko = { + url = "github:nix-community/disko"; + inputs.nixpkgs.follows = "nixos-unstable"; }; # Packages home-manager.url = "github:nix-community/home-manager/master"; - home-manager.inputs.nixpkgs.follows = "nixpkgs-stable"; + home-manager.inputs.nixpkgs.follows = "nixos-unstable"; catppuccin.url = "github:catppuccin/nix"; fcc-unlock = { url = "github:fabianhauser/fcc-unlock"; - inputs.nixpkgs.follows = "nixpkgs-stable"; + inputs.nixpkgs.follows = "nixos-unstable"; }; emanote = { url = "github:srid/emanote"; inputs = { emanote-template.follows = ""; - nixpkgs.follows = "nixpkgs-unstable"; + nixpkgs.follows = "nixos-unstable"; }; }; }; @@ -49,18 +53,19 @@ home-manager, lanzaboote, nixos-hardware, - nixpkgs-stable, - nixpkgs-unstable, + nixos-unstable, + disko, ... }@inputs: let system = "x86_64-linux"; - pkgsUnstable = import nixpkgs-unstable { + pkgsUnstable = import nixos-unstable { inherit system; config.allowUnfree = true; # For vscode }; hosts = [ "ochsenchopf" + "speer" ]; in with pkgsUnstable.lib; @@ -88,7 +93,7 @@ }; mapHostnameToAttr = host: - nixpkgs-stable.lib.nixosSystem { + nixos-unstable.lib.nixosSystem { inherit system; specialArgs = sharedSpecialArgs // { hardwareModules = nixos-hardware.nixosModules; @@ -97,6 +102,7 @@ home-manager.nixosModules.home-manager catppuccin.nixosModules.catppuccin lanzaboote.nixosModules.lanzaboote + disko.nixosModules.disko ./host/${host}/default.nix ] ++ (if host == "bachtel" then [ ] else [ home-manager-config ]); }; diff --git a/host/speer/default.nix b/host/speer/default.nix new file mode 100644 index 0000000..fa8da66 --- /dev/null +++ b/host/speer/default.nix @@ -0,0 +1,34 @@ +{ config, pkgs, ... }: +{ + + imports = [ + ./filesystems.nix + ./networking.nix + ./disko-config.nix + + ../../defaults/base + ../../defaults/desktop + ../../defaults/hardware/amd-board.nix + ../../defaults/hardware/ecc-memory.nix + ]; + + virtualisation = { + # TODO: This should probably be somewhere else. + docker = { + enable = true; + enableOnBoot = false; + }; + libvirtd.enable = true; + }; + + # Set your time zone. + time.timeZone = "Europe/Amsterdam"; + + # This value determines the NixOS release from which the default + # settings for stateful data, like fi:le locations and database versions + # on your system were taken. It‘s perfectly fine and recommended to leave + # this value at the release version of the first install of this system. + # Before changing this value read the documentation for this option + # (e.g. man configuration.nix or on https://nixos.org/nixos/options.html). + system.stateVersion = "24.11"; # Did you read the comment? +} diff --git a/host/speer/disko-config.nix b/host/speer/disko-config.nix new file mode 100644 index 0000000..711264f --- /dev/null +++ b/host/speer/disko-config.nix @@ -0,0 +1,98 @@ +{ pkgs, ... }: +{ + disko.devices = { + disk = rec { + system-1 = { + type = "disk"; + device = "/dev/disk/by-id/nvme-Samsung_SSD_970_EVO_Plus_2TB_S4J4NX0W821176E"; + content = { + type = "gpt"; + partitions = { + boot = { + size = "1G"; + type = "EF00"; + content = { + type = "filesystem"; + format = "vfat"; + mountpoint = "/boot-primary"; + }; + }; + raid_system = { + start = "5G"; + size = "98%"; + content = { + type = "mdraid"; + name = "raid_system"; + }; + }; + }; + }; + }; + #system-2 = { + # type = "disk"; + # device = "/dev/disk/by-id/nvme-XXXXX"; + # content = pkgs.lib.recursiveUpdate system-1.content { + # partitions.boot.content.mountpoint = "/boot-secondary"; + # }; + #}; + }; + + mdadm = { + "raid_system" = { + type = "mdadm"; + level = 1; + content = { + type = "luks"; + name = "crypted_system"; + passwordFile = "/run/secrets/system/hdd.key"; + settings = { + allowDiscards = true; + bypassWorkqueues = true; + }; + content = { + type = "lvm_pv"; + vg = "vg_system"; + }; + }; + }; + }; + lvm_vg = { + vg_system = { + type = "lvm_vg"; + lvs = { + swap = { + size = "32G"; + content = { + type = "swap"; + resumeDevice = true; + }; + }; + data = { + size = "1000GB"; + content = { + type = "btrfs"; + mountOptions = [ + "defaults" + "noatime" + ]; + subvolumes."/home".mountpoint = "/home"; + }; + }; + hv_speer = { + size = "200GiB"; + content = { + type = "btrfs"; + mountOptions = [ + "defaults" + "noatime" + ]; + subvolumes = { + "/root".mountpoint = "/"; + }; + }; + }; + }; + }; + }; + }; +} diff --git a/host/speer/filesystems.nix b/host/speer/filesystems.nix new file mode 100644 index 0000000..d6db5af --- /dev/null +++ b/host/speer/filesystems.nix @@ -0,0 +1,22 @@ +{ + config, + pkgs, + lib, + ... +}: +{ + # Configurations are set in disko-config.nix! + + # mdadm.conf generated by `mdadm --detail --scan` + # TODO + boot.swraid.enable = true; + boot.swraid.mdadmConf = '' + MAILADDR root + ''; + + services.fwupd.daemonSettings.EspLocation = pkgs.lib.mkForce config.disko.devices.disk.system-1.content.partitions.boot.content.mountpoint; + + # Use the systemd-boot EFI boot loader. + boot.loader.systemd-boot.enable = true; + boot.loader.efi.canTouchEfiVariables = true; +} diff --git a/host/speer/networking.nix b/host/speer/networking.nix new file mode 100644 index 0000000..3e0c936 --- /dev/null +++ b/host/speer/networking.nix @@ -0,0 +1,8 @@ +{ config, pkgs, ... }: +{ + networking = { + networkmanager.enable = true; + useDHCP = false; + hostName = "speer"; + }; +}