diff --git a/flake.lock b/flake.lock index 4a21718..6aaf5f0 100644 --- a/flake.lock +++ b/flake.lock @@ -467,6 +467,22 @@ "type": "github" } }, + "nixpkgs_2": { + "locked": { + "lastModified": 1732238832, + "narHash": "sha256-sQxuJm8rHY20xq6Ah+GwIUkF95tWjGRd1X8xF+Pkk38=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "8edf06bea5bcbee082df1b7369ff973b91618b8d", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixpkgs-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, "nixvim": { "inputs": { "devshell": "devshell", @@ -561,9 +577,7 @@ "flake-utils": "flake-utils_2", "gnome-shell": "gnome-shell", "home-manager": "home-manager_3", - "nixpkgs": [ - "nixpkgs" - ], + "nixpkgs": "nixpkgs_2", "systems": "systems_2", "tinted-foot": "tinted-foot", "tinted-kitty": "tinted-kitty", diff --git a/flake.nix b/flake.nix index 6491e71..0b9c9fd 100644 --- a/flake.nix +++ b/flake.nix @@ -19,10 +19,7 @@ inputs.nixpkgs.follows = "nixpkgs"; }; - stylix = { - url ="github:danth/stylix"; - inputs.nixpkgs.follows = "nixpkgs"; - }; + stylix.url = "github:danth/stylix"; nixvim = { url = "github:nix-community/nixvim"; @@ -76,7 +73,7 @@ attrs.stylix.nixosModules.stylix attrs.nixvim.nixosModules.nixvim attrs.nixos-hardware.nixosModules.framework-12th-gen-intel - ./hosts/Lenni + ./hosts ./users/willifan ./pkgs ]; @@ -107,7 +104,7 @@ attrs.nixos-hardware.nixosModules.common-cpu-amd attrs.nixos-hardware.nixosModules.common-cpu-amd-pstate attrs.nixos-hardware.nixosModules.common-cpu-amd-zenpower - ./hosts/Puenktchen + ./hosts ./users/willifan ./pkgs ]; @@ -138,7 +135,7 @@ attrs.nixos-hardware.nixosModules.common-cpu-amd attrs.nixos-hardware.nixosModules.common-cpu-amd-pstate attrs.nixos-hardware.nixosModules.common-cpu-amd-zenpower - ./hosts/Anton + ./hosts ./users/willifan ./pkgs ]; @@ -167,7 +164,7 @@ attrs.stylix.nixosModules.stylix attrs.nixvim.nixosModules.nixvim attrs.jovian.nixosModules.default - ./hosts/Lillie + ./hosts ./users/willifan ./pkgs ]; diff --git a/hosts/Anton/default.nix b/hosts/Anton/default.nix index 0d6c148..805a3eb 100644 --- a/hosts/Anton/default.nix +++ b/hosts/Anton/default.nix @@ -16,9 +16,6 @@ ./radicale.nix ./syncthing.nix - ../../modules/common - ../../modules/server - ]; } diff --git a/hosts/Lenni/default.nix b/hosts/Lenni/default.nix index 7c7c9db..5d54942 100644 --- a/hosts/Lenni/default.nix +++ b/hosts/Lenni/default.nix @@ -4,8 +4,5 @@ ./hardware-configuration.nix #./disko.nix ./syncthing.nix - - ../../modules/common - ../../modules/desktop ]; } diff --git a/hosts/Lillie/default.nix b/hosts/Lillie/default.nix index 6951150..81f90fb 100644 --- a/hosts/Lillie/default.nix +++ b/hosts/Lillie/default.nix @@ -3,9 +3,5 @@ imports = [ ./hardware-configuration.nix ./disko.nix - - ../../modules/common - ../../modules/desktop - ]; } diff --git a/hosts/Puenktchen/default.nix b/hosts/Puenktchen/default.nix index fdbc42e..d34a683 100644 --- a/hosts/Puenktchen/default.nix +++ b/hosts/Puenktchen/default.nix @@ -3,10 +3,8 @@ imports = [ ./hardware-configuration.nix ./disko.nix - - ../../modules/common - ../../modules/desktop - + ./syncthing.nix ]; + boot.initrd.kernelModules = [ "amdgpu" ]; } diff --git a/modules/common/autoupdate.nix b/hosts/common/autoupdate.nix similarity index 100% rename from modules/common/autoupdate.nix rename to hosts/common/autoupdate.nix diff --git a/modules/common/default.nix b/hosts/common/default.nix similarity index 100% rename from modules/common/default.nix rename to hosts/common/default.nix diff --git a/modules/common/garbage-collect.nix b/hosts/common/garbage-collect.nix similarity index 100% rename from modules/common/garbage-collect.nix rename to hosts/common/garbage-collect.nix diff --git a/modules/common/keyd.nix b/hosts/common/keyd.nix similarity index 100% rename from modules/common/keyd.nix rename to hosts/common/keyd.nix diff --git a/modules/common/mimetype.nix b/hosts/common/mimetype.nix similarity index 100% rename from modules/common/mimetype.nix rename to hosts/common/mimetype.nix diff --git a/modules/common/optimise.nix b/hosts/common/optimise.nix similarity index 100% rename from modules/common/optimise.nix rename to hosts/common/optimise.nix diff --git a/modules/common/sops.nix b/hosts/common/sops.nix similarity index 100% rename from modules/common/sops.nix rename to hosts/common/sops.nix diff --git a/hosts/default.nix b/hosts/default.nix new file mode 100644 index 0000000..908c51b --- /dev/null +++ b/hosts/default.nix @@ -0,0 +1,8 @@ +{ hostname, type, ... }: +{ + imports = [ + ./common + ./${type} + ./${hostname} + ]; +} diff --git a/modules/desktop/boot.nix b/hosts/desktop/boot.nix similarity index 100% rename from modules/desktop/boot.nix rename to hosts/desktop/boot.nix diff --git a/modules/desktop/default.nix b/hosts/desktop/default.nix similarity index 100% rename from modules/desktop/default.nix rename to hosts/desktop/default.nix diff --git a/modules/desktop/nfs-client.nix b/hosts/desktop/nfs-client.nix similarity index 100% rename from modules/desktop/nfs-client.nix rename to hosts/desktop/nfs-client.nix diff --git a/modules/desktop/nix-ld.nix b/hosts/desktop/nix-ld.nix similarity index 100% rename from modules/desktop/nix-ld.nix rename to hosts/desktop/nix-ld.nix diff --git a/modules/desktop/printers.nix b/hosts/desktop/printers.nix similarity index 100% rename from modules/desktop/printers.nix rename to hosts/desktop/printers.nix diff --git a/modules/desktop/remoteBuilder.nix b/hosts/desktop/remoteBuilder.nix similarity index 100% rename from modules/desktop/remoteBuilder.nix rename to hosts/desktop/remoteBuilder.nix diff --git a/modules/desktop/ssh-server.nix b/hosts/desktop/ssh-server.nix similarity index 100% rename from modules/desktop/ssh-server.nix rename to hosts/desktop/ssh-server.nix diff --git a/modules/server/boot.nix b/hosts/server/boot.nix similarity index 100% rename from modules/server/boot.nix rename to hosts/server/boot.nix diff --git a/modules/server/builder.nix b/hosts/server/builder.nix similarity index 100% rename from modules/server/builder.nix rename to hosts/server/builder.nix diff --git a/modules/server/default.nix b/hosts/server/default.nix similarity index 100% rename from modules/server/default.nix rename to hosts/server/default.nix diff --git a/modules/server/ssh-server.nix b/hosts/server/ssh-server.nix similarity index 100% rename from modules/server/ssh-server.nix rename to hosts/server/ssh-server.nix diff --git a/modules/common/syncthing.nix b/modules/common/syncthing.nix deleted file mode 100644 index 4b06a0c..0000000 --- a/modules/common/syncthing.nix +++ /dev/null @@ -1,70 +0,0 @@ -{ lib, config, ... }: -{ - - options = { - - syncthing.devices = lib.mkOption { - default = { }; - type = lib.types.attrsOf (lib.types.submodule { - options = { - - id = lib.mkOption { - type = lib.types.str; - default = null; - }; - - }; - }); - }; - }; - - services.syncthing = { - enable = true; - user = "willifan"; - dataDir = "/mnt/data"; - configDir = "/mnt/data/.config/syncthing"; - overrideDevices = true; - overrideFolders = true; - settings = { - gui = { - user = "willifan"; - password = "temppassword"; - }; - devices = { - Anton = { id = "WCDBADD-UPKCACI-X2YJOIO-5QC44PL-DBCR6TS-ADVQV33-HSMF32O-FOKMKAU"; }; - }; - folders = { - "Documents" = { - id = "jtl6g-qjmwo"; - path = "/mnt/data/Documents"; - devices = [ "Anton" ]; - }; - "Enpass" = { - id = "ciksm-xsw4m"; - path = "/mnt/data/Enpass"; - devices = [ "Anton" ]; - }; - "Pictures" = { - id = "po4qj-q9t0t"; - path = "/mnt/data/Pictures"; - devices = [ "Anton" ]; - }; - "Videos" = { - id = "4wqf5-xasng"; - path = "/mnt/data/Videos"; - devices = [ "Anton" ]; - }; - "Notes" = { - id = "oc61n-iewgj"; - path = "/mnt/data/Notes"; - devices = [ "Anton" ]; - }; - "Music" = { - id = "xxh8a-3y2tq"; - path = "/mnt/data/Music"; - devices = [ "Anton" ]; - }; - }; - }; - }; -}