aboutsummaryrefslogtreecommitdiff
path: root/modules/hosts
diff options
context:
space:
mode:
authorschererleander <leander@schererleander.de>2026-02-05 12:03:07 +0100
committerschererleander <leander@schererleander.de>2026-02-05 15:19:41 +0100
commit3b13d9a2a367db84d48940460532c17a374bb488 (patch)
tree599110a39c4baecf3991fe9a58d0103a43c38896 /modules/hosts
parent46aa4842b98d9215baca00060c233f386a0c2188 (diff)
feat(modules): use dendritic pattern
Diffstat (limited to 'modules/hosts')
-rw-r--r--modules/hosts/adam/configuration.nix56
-rw-r--r--modules/hosts/adam/flake-parts.nix15
-rw-r--r--modules/hosts/adam/hardware-configuration.nix49
-rw-r--r--modules/hosts/lilith/configuration.nix64
-rw-r--r--modules/hosts/lilith/flake-parts.nix15
-rw-r--r--modules/hosts/sachiel/configuration.nix49
-rw-r--r--modules/hosts/sachiel/flake-parts.nix14
-rw-r--r--modules/hosts/sachiel/hardware-configuration.nix39
8 files changed, 301 insertions, 0 deletions
diff --git a/modules/hosts/adam/configuration.nix b/modules/hosts/adam/configuration.nix
new file mode 100644
index 0000000..53094f0
--- /dev/null
+++ b/modules/hosts/adam/configuration.nix
@@ -0,0 +1,56 @@
+{
+ flake.modules.nixos.adam =
+ {
+ pkgs,
+ ...
+ }:
+ {
+ boot = {
+ kernelPackages = pkgs.linuxPackages_latest;
+ kernelParams = [ "amd_pstate=active" ];
+ initrd.luks.devices."luks-803851e9-7fa8-4367-a927-0bb76d0fe830".device =
+ "/dev/disk/by-uuid/803851e9-7fa8-4367-a927-0bb76d0fe830";
+ loader = {
+ timeout = 0;
+ systemd-boot.enable = true;
+ efi.canTouchEfiVariables = true;
+ };
+ };
+
+ # Localisation
+ time.timeZone = "Europe/Berlin";
+ i18n.defaultLocale = "en_US.UTF-8";
+ i18n.extraLocaleSettings = {
+ LC_ADDRESS = "de_DE.UTF-8";
+ LC_IDENTIFICATION = "de_DE.UTF-8";
+ LC_MEASUREMENT = "de_DE.UTF-8";
+ LC_MONETARY = "de_DE.UTF-8";
+ LC_NAME = "de_DE.UTF-8";
+ LC_NUMERIC = "de_DE.UTF-8";
+ LC_PAPER = "de_DE.UTF-8";
+ LC_TELEPHONE = "de_DE.UTF-8";
+ LC_TIME = "de_DE.UTF-8";
+ };
+
+ # Disable waiting for network to be online
+ systemd.services.NetworkManager-wait-online.enable = false;
+
+ # User configuration
+ users.users.schererleander = {
+ isNormalUser = true;
+ home = "/home/schererleander";
+ shell = pkgs.zsh;
+ ignoreShellProgramCheck = true;
+ extraGroups = [
+ "wheel"
+ "networkmanager"
+ "video"
+ "input"
+ ];
+ };
+
+ nixpkgs.config.allowUnfree = true;
+ nixpkgs.hostPlatform = "x86_64-linux";
+ system.stateVersion = "25.11";
+ };
+}
diff --git a/modules/hosts/adam/flake-parts.nix b/modules/hosts/adam/flake-parts.nix
new file mode 100644
index 0000000..cf50170
--- /dev/null
+++ b/modules/hosts/adam/flake-parts.nix
@@ -0,0 +1,15 @@
+{ inputs, ... }:
+{
+ flake.nixosConfigurations."adam" = inputs.nixpkgs.lib.nixosSystem {
+ specialArgs = { inherit inputs; };
+ modules = [
+ inputs.self.modules.nixos.adam
+ inputs.self.modules.nixos.secrets
+ inputs.self.modules.nixos.home-manager
+ inputs.self.modules.nixos.plymouth
+ inputs.self.modules.nixos.kde
+ inputs.self.modules.nixos.dns
+ inputs.self.modules.nixos.bluetooth
+ ];
+ };
+}
diff --git a/modules/hosts/adam/hardware-configuration.nix b/modules/hosts/adam/hardware-configuration.nix
new file mode 100644
index 0000000..be6cc0a
--- /dev/null
+++ b/modules/hosts/adam/hardware-configuration.nix
@@ -0,0 +1,49 @@
+# Do not modify this file! It was generated by ‘nixos-generate-config’
+# and may be overwritten by future invocations. Please make changes
+# to /etc/nixos/configuration.nix instead.
+{
+ flake.modules.nixos.adam =
+ {
+ config,
+ lib,
+ ...
+ }:
+
+ {
+ boot.initrd.availableKernelModules = [
+ "nvme"
+ "xhci_pci"
+ "ahci"
+ "usbhid"
+ "usb_storage"
+ "sd_mod"
+ ];
+ boot.initrd.kernelModules = [ ];
+ boot.kernelModules = [ "kvm-amd" ];
+ boot.extraModulePackages = [ ];
+
+ fileSystems."/" = {
+ device = "/dev/mapper/luks-37471d57-a31d-4bf1-b219-9992bafe7b64";
+ fsType = "ext4";
+ };
+
+ boot.initrd.luks.devices."luks-37471d57-a31d-4bf1-b219-9992bafe7b64".device =
+ "/dev/disk/by-uuid/37471d57-a31d-4bf1-b219-9992bafe7b64";
+
+ fileSystems."/boot" = {
+ device = "/dev/disk/by-uuid/8E50-FCCA";
+ fsType = "vfat";
+ options = [
+ "fmask=0077"
+ "dmask=0077"
+ ];
+ };
+
+ swapDevices = [
+ { device = "/dev/mapper/luks-803851e9-7fa8-4367-a927-0bb76d0fe830"; }
+ ];
+
+ nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
+ hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
+ };
+}
diff --git a/modules/hosts/lilith/configuration.nix b/modules/hosts/lilith/configuration.nix
new file mode 100644
index 0000000..af15fba
--- /dev/null
+++ b/modules/hosts/lilith/configuration.nix
@@ -0,0 +1,64 @@
+{
+ flake.modules.darwin.lilith =
+ {
+ ...
+ }:
+
+ let
+ username = "schererleander";
+ in
+ {
+ networking.hostName = "lilith";
+
+ # User configuration
+ users.users.${username}.home = "/Users/${username}";
+
+ system.primaryUser = username;
+ system.defaults = {
+ dock = {
+ autohide = true;
+ largesize = 48;
+ show-recents = false;
+ };
+ WindowManager.EnableStandardClickToShowDesktop = false;
+ finder = {
+ _FXShowPosixPathInTitle = true;
+ _FXSortFoldersFirst = true;
+ };
+ controlcenter = {
+ Display = false;
+ FocusModes = false;
+ Sound = false;
+ };
+ loginwindow.GuestEnabled = false;
+ };
+
+ homebrew = {
+ enable = true;
+ brews = [
+ "openjdk@21"
+ ];
+ casks = [
+ "mullvad-vpn"
+ "nextcloud"
+ "iterm2"
+ "rectangle"
+ ];
+ masApps = {
+ "AdGuard Mini" = 1440147259;
+ #"WebSSH - Sysadmin Toolbox" = 497714887;
+ "Windows App" = 1295203466;
+ "Goodnotes: KI-Notizen, PDF" = 1444383602;
+ "WhatsApp Messenger" = 310633997;
+ };
+ onActivation.cleanup = "zap";
+ onActivation.autoUpdate = true;
+ onActivation.upgrade = true;
+ };
+
+ nix.enable = false;
+
+ nixpkgs.config.allowUnfree = true;
+ system.stateVersion = 5;
+ };
+}
diff --git a/modules/hosts/lilith/flake-parts.nix b/modules/hosts/lilith/flake-parts.nix
new file mode 100644
index 0000000..5842777
--- /dev/null
+++ b/modules/hosts/lilith/flake-parts.nix
@@ -0,0 +1,15 @@
+{
+ inputs,
+ ...
+}:
+
+{
+ flake.darwinConfigurations.lilith = inputs.nix-darwin.lib.darwinSystem {
+ specialArgs = { inherit inputs; };
+ system = "aarch64-darwin";
+ modules = [
+ inputs.self.modules.darwin.lilith
+ inputs.self.modules.darwin.home-manager
+ ];
+ };
+}
diff --git a/modules/hosts/sachiel/configuration.nix b/modules/hosts/sachiel/configuration.nix
new file mode 100644
index 0000000..d2d1d75
--- /dev/null
+++ b/modules/hosts/sachiel/configuration.nix
@@ -0,0 +1,49 @@
+{
+ flake.modules.nixos.sachiel =
+ {
+ pkgs,
+ ...
+ }:
+ {
+ boot.tmp.cleanOnBoot = true;
+ boot.loader.grub.configurationLimit = 2;
+ zramSwap.enable = true;
+
+ swapDevices = [
+ {
+ device = "/var/swapfile";
+ size = 4096;
+ }
+ ];
+
+ networking = {
+ hostName = "sachiel";
+ domain = "schererleander.de";
+ };
+
+ users.users.root.hashedPassword = "!";
+ users.mutableUsers = false;
+ users.users.administrator = {
+ isNormalUser = true;
+ hashedPassword = "$6$KBblJguEyfEmuWnU$Xf0QqPVacA2qvnzZRpnSE2cmh0kNnMgtVhCrMEDI76buNzuzkuDY6EnO7jPjQlEnoczx6ZPAl2pK.SxezbVa..";
+ extraGroups = [ "wheel" ];
+ openssh.authorizedKeys.keys = [
+ "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPvlkqlvY4+0o7UIGnFnnRw0HeBq5v7wYJ3kY3teXxxl vps"
+ "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAINL+r0l2i07pl9V9iiGqw5e2f/QAcrMhuraA25HavdNT github-deploy"
+ ];
+ };
+
+ environment.systemPackages = with pkgs; [
+ git
+ gnutar
+ gzip
+ zoxide
+ neovim
+ htop
+ ];
+
+ nixpkgs.config.allowUnfree = true;
+ nixpkgs.hostPlatform = "x86_64-linux";
+ system.stateVersion = "25.05";
+ };
+}
diff --git a/modules/hosts/sachiel/flake-parts.nix b/modules/hosts/sachiel/flake-parts.nix
new file mode 100644
index 0000000..42d7551
--- /dev/null
+++ b/modules/hosts/sachiel/flake-parts.nix
@@ -0,0 +1,14 @@
+{ inputs, ... }:
+{
+ flake.nixosConfigurations."sachiel" = inputs.nixpkgs.lib.nixosSystem {
+ specialArgs = { inherit inputs; };
+ modules = [
+ inputs.self.modules.nixos.sachiel
+ inputs.self.modules.nixos.secrets
+ inputs.self.modules.nixos.openssh
+ inputs.self.modules.nixos.nginx
+ inputs.self.modules.nixos.nextcloud
+ inputs.self.modules.nixos.site
+ ];
+ };
+}
diff --git a/modules/hosts/sachiel/hardware-configuration.nix b/modules/hosts/sachiel/hardware-configuration.nix
new file mode 100644
index 0000000..e188fae
--- /dev/null
+++ b/modules/hosts/sachiel/hardware-configuration.nix
@@ -0,0 +1,39 @@
+{
+ flake.modules.nixos.sachiel =
+ { ... }:
+ {
+ boot.loader.grub = {
+ efiSupport = true;
+ efiInstallAsRemovable = true;
+ device = "nodev";
+ };
+ fileSystems."/boot" = {
+ device = "/dev/disk/by-uuid/4E07-7ABB";
+ fsType = "vfat";
+ };
+ boot.initrd.availableKernelModules = [
+ "ata_piix"
+ "uhci_hcd"
+ "xen_blkfront"
+ "vmw_pvscsi"
+ "virtio_net"
+ "virtio_pci"
+ "virtio_mmio"
+ "virtio_blk"
+ "virtio_scsi"
+ "9p"
+ "9pnet_virtio"
+ ];
+ boot.initrd.kernelModules = [
+ "nvme"
+ "virtio_balloon"
+ "virtio_console"
+ "virtio_rng"
+ "virtio_gpu"
+ ];
+ fileSystems."/" = {
+ device = "/dev/vda1";
+ fsType = "ext4";
+ };
+ };
+}