63 lines
1.8 KiB
Nix
63 lines
1.8 KiB
Nix
{
|
|
description = "System configuration for all machines in samfélag";
|
|
|
|
inputs = {
|
|
|
|
# - Nixpkgs ----------------------------------
|
|
nixpkgs.url = "github:nixos/nixpkgs/nixos-22.05";
|
|
|
|
# - Home-Manager -----------------------------
|
|
home-manager.url = "github:nix-community/home-manager/release-22.05";
|
|
home-manager.inputs.nixpkgs.follows = "nixpkgs";
|
|
|
|
# - NUR --------------------------------------
|
|
nur.url = "github:nix-community/NUR";
|
|
|
|
# - Overlays ---------------------------------
|
|
emacs-overlay.url = "github:nix-community/emacs-overlay";
|
|
|
|
# - Themeing ---------------------------------
|
|
grub2-themes.url = "github:vinceliuice/grub2-themes";
|
|
grub2-themes.inputs.nixpkgs.follows = "nixpkgs";
|
|
|
|
nix-colors.url = "github:misterio77/nix-colors";
|
|
|
|
};
|
|
|
|
outputs = inputs @ { self, nixpkgs, home-manager, ... }:
|
|
let
|
|
system = "x86_64-linux";
|
|
|
|
pkgs = import nixpkgs {
|
|
inherit system;
|
|
config.allowUnfree = true;
|
|
overlays = import ./overlays { inherit inputs; };
|
|
};
|
|
|
|
lib = nixpkgs.lib.extend
|
|
(self: super: { my = import ./lib { inherit pkgs inputs; lib = self; }; });
|
|
|
|
mkHost = hostPath: lib.nixosSystem {
|
|
inherit system;
|
|
inherit pkgs;
|
|
specialArgs = { inherit lib inputs system; };
|
|
modules = [
|
|
hostPath
|
|
{
|
|
imports =
|
|
[
|
|
inputs.home-manager.nixosModules.home-manager
|
|
inputs.nix-colors.homeManagerModule
|
|
inputs.grub2-themes.nixosModule
|
|
]
|
|
# All my personal modules
|
|
++ (lib.my.mapModulesRec' (toString ./modules) import);
|
|
}
|
|
];
|
|
};
|
|
|
|
in {
|
|
nixosConfigurations = lib.my.mapModules ./hosts mkHost;
|
|
};
|
|
}
|