NixOS-Config/flake.nix

92 lines
2.2 KiB
Nix
Raw Normal View History

2024-08-24 22:16:51 -04:00
{
inputs = {
# System inputs
2024-11-19 13:20:34 -05:00
nixpkgs.url = "nixpkgs/nixos-24.11";
2024-10-15 02:40:43 -04:00
unstable.url = "nixpkgs/nixos-unstable";
lanzaboote = {
url = "github:nix-community/lanzaboote/v0.4.1";
2024-10-15 02:40:43 -04:00
inputs.nixpkgs.follows = "nixpkgs";
};
disko = {
url = "github:nix-community/disko";
inputs.nixpkgs.follows = "nixpkgs";
};
impermanence.url = "github:nix-community/impermanence";
mailserver.url = "gitlab:simple-nixos-mailserver/nixos-mailserver/nixos-24.05";
minecraft.url = "github:Infinidoge/nix-minecraft";
2024-08-24 22:16:51 -04:00
# Home inputs
home-manager = {
2024-11-19 13:20:34 -05:00
url = "github:nix-community/home-manager/release-24.11";
2024-10-09 03:36:08 -04:00
inputs.nixpkgs.follows = "nixpkgs";
};
nur.url = "github:nix-community/NUR";
blender.url = "https://flakehub.com/f/edolstra/blender-bin/1.0.11.tar.gz";
2024-08-24 22:16:51 -04:00
};
outputs = {
2024-12-01 20:10:31 -05:00
self,
nixpkgs,
unstable,
lanzaboote,
disko,
impermanence,
mailserver,
minecraft,
home-manager,
nur,
blender,
...
}:
let
mkNix = modules: nixpkgs.lib.nixosSystem {
inherit modules;
specialArgs = {
inherit
2024-12-01 20:10:31 -05:00
self
unstable
lanzaboote
disko
impermanence
mailserver
minecraft
home-manager
nur
blender
;
};
};
mkHome = modules: pkgs: home-manager.lib.homeManagerConfiguration {
inherit modules pkgs;
extraSpecialArgs = {
inherit
unstable
nur
blender
;
};
};
in {
2024-11-06 11:49:40 -05:00
# nixos-rebuild switch --flake /etc/nixos#hostname
2024-08-24 22:16:51 -04:00
nixosConfigurations = {
2024-11-12 04:25:51 -05:00
tower = mkNix [ ./hosts/tower ]; # Main Desktop
2024-10-28 00:11:01 -04:00
axolotl = mkNix [ ./hosts/axolotl ]; # PineBook Pro
2024-11-06 11:49:40 -05:00
lacros = mkNix [ ./hosts/lacros ]; # Dell Chromebook
redmond = mkNix [ ./hosts/redmond ]; # Lenovo Dual-Boot Laptop
2024-12-01 20:10:31 -05:00
extern = mkNix [ ./hosts/extern ]; # External Drive/USB
2024-11-12 04:25:51 -05:00
kitty = mkNix [ ./hosts/kitty ]; # Dell Optiplex 7010
xenia = mkNix [ ./hosts/xenia ]; # Acer Veriton X2611G
prophet = mkNix [ ./hosts/prophet ]; # Oracle Neoverse-N1
2024-08-24 22:16:51 -04:00
};
2024-11-06 11:49:40 -05:00
# home-manager switch --flake /etc/nixos#username
homeConfigurations."jimbo" = mkHome [ ./modules/home ] nixpkgs.legacyPackages.x86_64-linux;
2024-08-24 22:16:51 -04:00
};
}