From 02115fe73de0ee3249c3ac1c8b0b5b35cb27a15a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Felix=20Schr=C3=B6ter?= <dev@felschr.com> Date: Thu, 1 May 2025 16:08:47 +0200 Subject: [PATCH] refactor(hosts): move host configurations into folders --- hosts/{doctr.nix => doctr/default.nix} | 0 hosts/flake-module.nix | 4 +- hosts/{home-pc.nix => home-pc/default.nix} | 36 ++++++------- .../default.nix} | 54 +++++++++---------- hosts/{penguin.nix => penguin/default.nix} | 1 + 5 files changed, 48 insertions(+), 47 deletions(-) rename hosts/{doctr.nix => doctr/default.nix} (100%) rename hosts/{home-pc.nix => home-pc/default.nix} (65%) rename hosts/{home-server.nix => home-server/default.nix} (81%) rename hosts/{penguin.nix => penguin/default.nix} (89%) diff --git a/hosts/doctr.nix b/hosts/doctr/default.nix similarity index 100% rename from hosts/doctr.nix rename to hosts/doctr/default.nix diff --git a/hosts/flake-module.nix b/hosts/flake-module.nix index ae3b4ec..70607e7 100644 --- a/hosts/flake-module.nix +++ b/hosts/flake-module.nix @@ -12,7 +12,7 @@ inputs.nixos-hardware.nixosModules.common-gpu-amd (self.lib.createSystemModule "home-pc" { hardwareConfig = ../hardware/home-pc.nix; - config = ../hosts/home-pc.nix; + config = ../hosts/home-pc/default.nix; }) self.lib.createMediaGroup (self.lib.createUserModule "felschr" { @@ -51,7 +51,7 @@ inputs.matrix-appservices.nixosModule (self.lib.createSystemModule "home-server" { hardwareConfig = ../hardware/lattepanda.nix; - config = ../hosts/home-server.nix; + config = ../hosts/home-server/default.nix; }) self.lib.createMediaGroup (self.lib.createUserModule "felschr" { diff --git a/hosts/home-pc.nix b/hosts/home-pc/default.nix similarity index 65% rename from hosts/home-pc.nix rename to hosts/home-pc/default.nix index 2458661..7ff949f 100644 --- a/hosts/home-pc.nix +++ b/hosts/home-pc/default.nix @@ -2,24 +2,24 @@ { imports = [ - ../hardware/base.nix - ../hardware/bluetooth.nix - ../hardware/xbox.nix - ../hardware/steam.nix - ../hardware/ledger.nix - ../system/desktop.nix - ../system/printing/home.nix - ../system/gaming.nix - ../desktop - ../desktop/cosmic.nix - ../virtualisation/containers.nix - ../virtualisation/podman.nix - ../virtualisation/libvirt.nix - ../modules/systemdNotify.nix - ../services/samba/home-pc.nix - ../services/restic/home-pc.nix - ../services/pcscd.nix - ../services/open-webui.nix + ../../hardware/base.nix + ../../hardware/bluetooth.nix + ../../hardware/xbox.nix + ../../hardware/steam.nix + ../../hardware/ledger.nix + ../../system/desktop.nix + ../../system/printing/home.nix + ../../system/gaming.nix + ../../desktop + ../../desktop/cosmic.nix + ../../virtualisation/containers.nix + ../../virtualisation/podman.nix + ../../virtualisation/libvirt.nix + ../../modules/systemdNotify.nix + ../../services/samba/home-pc.nix + ../../services/restic/home-pc.nix + ../../services/pcscd.nix + ../../services/open-webui.nix ]; nixpkgs.config.allowUnfree = true; diff --git a/hosts/home-server.nix b/hosts/home-server/default.nix similarity index 81% rename from hosts/home-server.nix rename to hosts/home-server/default.nix index 9f25161..f9ab5e8 100644 --- a/hosts/home-server.nix +++ b/hosts/home-server/default.nix @@ -18,33 +18,33 @@ let in { imports = [ - ../hardware/base.nix - ../desktop/x11.nix - ../system/server.nix - ../virtualisation/containers.nix - ../virtualisation/podman.nix - ../modules/inadyn.nix - ../modules/systemdNotify.nix - ../services/postgres - ../services/mail.nix - ../services/lldap.nix - ../services/authelia.nix - ../services/forgejo - ../services/restic/home-server.nix - ../services/samba/home-server.nix - # ../services/kodi.nix - ../services/jellyfin.nix - ../services/etebase.nix - ../services/website.nix - ../services/wkd.nix - ../services/home-assistant - ../services/matrix - ../services/immich.nix - ../services/miniflux.nix - ../services/paperless.nix - ../services/nextcloud.nix - ../services/collabora-office.nix - ../services/calibre-web.nix + ../../hardware/base.nix + ../../desktop/x11.nix + ../../system/server.nix + ../../virtualisation/containers.nix + ../../virtualisation/podman.nix + ../../modules/inadyn.nix + ../../modules/systemdNotify.nix + ../../services/postgres + ../../services/mail.nix + ../../services/lldap.nix + ../../services/authelia.nix + ../../services/forgejo + ../../services/restic/home-server.nix + ../../services/samba/home-server.nix + # ../../services/kodi.nix + ../../services/jellyfin.nix + ../../services/etebase.nix + ../../services/website.nix + ../../services/wkd.nix + ../../services/home-assistant + ../../services/matrix + ../../services/immich.nix + ../../services/miniflux.nix + ../../services/paperless.nix + ../../services/nextcloud.nix + ../../services/collabora-office.nix + ../../services/calibre-web.nix ]; age.secrets.cloudflare.file = ../secrets/cloudflare.age; diff --git a/hosts/penguin.nix b/hosts/penguin/default.nix similarity index 89% rename from hosts/penguin.nix rename to hosts/penguin/default.nix index 1c800f5..849a79f 100644 --- a/hosts/penguin.nix +++ b/hosts/penguin/default.nix @@ -13,6 +13,7 @@ hostname = "penguin"; timezone = "Europe/Berlin"; ipaddr = "192.168.0.1"; + packages = [ "ds-lite" ]; }; }; }