diff --git a/flake.nix b/flake.nix index 8c636c90..3427deba 100644 --- a/flake.nix +++ b/flake.nix @@ -1,17 +1,21 @@ { description = "NixOS System Config"; inputs = { + # Stable Packages nixpkgs.url = "nixpkgs/nixos-23.11"; - # nixpkgs-wayland - Wayland-specific packages not in nixpkgs - nixpkgs-wayland.url = "github:nix-community/nixpkgs-wayland"; + # Unstable Packages + nixpkgs-unstable.url = "nixpkgs/nixos-unstable"; # home-manager - Dotfile mnagement - add /master at the end to pull from master home-manager.url = "github:nix-community/home-manager/release-23.11"; home-manager.inputs.nixpkgs.follows = "nixpkgs"; # Nix colorizer / themer stylix.url = "github:danth/stylix/release-23.11"; + # lanzaboote - Secureboot Configuration lanzaboote.url = "github:nix-community/lanzaboote"; lanzaboote.inputs.nixpkgs.follows = "nixpkgs"; + # nixpkgs-wayland - Wayland-specific packages not in nixpkgs + nixpkgs-wayland.url = "github:nix-community/nixpkgs-wayland"; # nur - Nix User Repository - user-submitted / maintained packages nur.url = "github:nix-community/NUR"; # sops-nix - Secret Management with SOPS using GPG Keys @@ -32,24 +36,13 @@ # deploy-rs, declarative NixOS deployments deploy-rs.url = "github:serokell/deploy-rs"; deploy-rs.inputs.nixpkgs.follows = "nixpkgs"; - # compose2nix - Convert docker-compose.yml files to nix syntax - compose2nix.url = "github:aksiksi/compose2nix"; - compose2nix.inputs.nixpkgs.follows = "nixpkgs"; # KDE Plasma 6 experimental flake kde2nix.url = "github:nix-community/kde2nix"; # Manage Plasma desktop with Nix plasma-manager.url = "github:pjones/plasma-manager"; plasma-manager.inputs.nixpkgs.follows = "nixpkgs"; - # Hyprland Flake - hyprland.url = "github:hyprwm/Hyprland"; - # Hyprland Plugins - hyprland-plugins.url = "github:hyprwm/hyprland-plugins"; - hyprland-plugins.inputs.hyprland.follows = "hyprland"; - # Nix-enabled generative AI creation toolsI - nixified-ai.url = "github:nixified-ai/flake"; - nixified-ai.inputs.nixpkgs.follows = "nixpkgs"; }; - outputs = { self, nixpkgs, nixpkgs-wayland, home-manager, lanzaboote, nur, sops-nix, doom-emacs, nixos-generators, deploy-rs, ... } @inputs: + outputs = { self, nixpkgs, nixpkgs-unstable, nixpkgs-wayland, home-manager, lanzaboote, nur, sops-nix, doom-emacs, nixos-generators, deploy-rs, ... } @inputs: let inherit (self) outputs; stateVersion = "23.11"; @@ -60,8 +53,8 @@ osaka-linode-01 = libx.mkHost { hostname = "osaka-linode-01"; }; framework-server = libx.mkHost { hostname = "framework-server"; }; nuc-server = libx.mkHost { hostname = "nuc-server"; }; - nixos-desktop = libx.mkHost { hostname = "nixos-desktop"; desktop = "hyprland"; gpu = "nvidia"; theme = "tokyo-night"; }; - nixos-framework = libx.mkHost { hostname = "nixos-framework"; desktop = "hyprland"; gpu = "amd"; theme = "tokyo-night"; }; + nixos-desktop = libx.mkHost { hostname = "nixos-desktop"; repo = "nixpkgs-unstable"; desktop = "hyprland"; gpu = "nvidia"; theme = "tokyo-night"; }; + nixos-framework = libx.mkHost { hostname = "nixos-framework"; repo = "nixpkgs-unstable"; desktop = "hyprland"; gpu = "amd"; theme = "tokyo-night"; }; backups-rpi4 = libx.mkHost { hostname = "backups-rpi4"; platform = "aarch64-linux"; type = "small"; }; piaware-rpi4 = libx.mkHost { hostname = "piaware-rpi4"; platform = "aarch64-linux"; type = "small"; }; quitman-rpi4 = libx.mkHost { hostname = "quitman-rpi4"; platform = "aarch64-linux"; type = "small"; }; diff --git a/lib/default.nix b/lib/default.nix index a7c329e6..670c99d8 100644 --- a/lib/default.nix +++ b/lib/default.nix @@ -40,9 +40,12 @@ gpu ? null, platform ? "x86_64-linux", theme ? "default", - type ? "default" + type ? "default", + repo ? "nixpkgs" }: inputs.nixpkgs.lib.nixosSystem { specialArgs = { inherit inputs outputs desktop hostname username stateVersion gpu platform theme; }; + pkgs = import inputs.${repo} { inherit system; } + modules = [ # Types are 'default', 'small', and 'minimal' ../nixos/${type}.nix