2024-05-08 00:45:54 +01:00
|
|
|
{
|
2024-05-15 21:46:48 +01:00
|
|
|
description = "Nix Config";
|
2024-05-08 00:45:54 +01:00
|
|
|
|
|
|
|
inputs = {
|
2024-05-09 12:03:13 +01:00
|
|
|
# Nixpkgs
|
2024-06-22 14:37:19 +01:00
|
|
|
nixpkgs.url = "github:nixos/nixpkgs/nixos-24.05";
|
2024-05-09 12:03:13 +01:00
|
|
|
nixpkgs-unstable.url = "github:nixos/nixpkgs/nixos-unstable";
|
2024-05-08 00:45:54 +01:00
|
|
|
|
2024-06-06 18:53:22 +01:00
|
|
|
# NUR
|
|
|
|
nur.url = "github:nix-community/NUR";
|
|
|
|
|
2024-05-09 12:03:13 +01:00
|
|
|
# Home manager
|
2024-05-15 21:46:48 +01:00
|
|
|
home-manager = {
|
2024-06-22 14:37:19 +01:00
|
|
|
url = "github:nix-community/home-manager/release-24.05";
|
2024-05-15 19:44:13 +01:00
|
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
|
|
};
|
2024-05-12 19:58:55 +01:00
|
|
|
|
2024-05-25 16:23:00 +01:00
|
|
|
# Nixvim
|
|
|
|
nixvim = {
|
2024-06-22 14:37:19 +01:00
|
|
|
url = "github:nix-community/nixvim/nixos-24.05";
|
2024-05-25 16:23:00 +01:00
|
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
|
|
};
|
|
|
|
|
2024-06-02 14:30:14 +01:00
|
|
|
# Nix colors
|
|
|
|
nix-colors.url = "github:misterio77/nix-colors";
|
|
|
|
|
2024-05-14 14:51:09 +01:00
|
|
|
# Declarative partitioning and formatting
|
|
|
|
disko = {
|
2024-06-25 18:19:47 +01:00
|
|
|
url = "github:nix-community/disko/v1.6.1";
|
2024-05-14 14:51:09 +01:00
|
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
|
|
};
|
|
|
|
|
2024-05-17 01:07:42 +01:00
|
|
|
impermanence = {
|
|
|
|
url = "github:nix-community/impermanence";
|
|
|
|
};
|
|
|
|
|
2024-05-12 19:58:55 +01:00
|
|
|
# Secrets management
|
|
|
|
sops-nix = {
|
|
|
|
url = "github:mic92/sops-nix";
|
|
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
|
|
};
|
2024-05-13 22:36:10 +01:00
|
|
|
|
|
|
|
nix-secrets = {
|
|
|
|
url = "git+ssh://git@git.bitlab21.com/sam/nix-secrets.git";
|
|
|
|
flake = false;
|
|
|
|
};
|
2024-05-08 00:45:54 +01:00
|
|
|
};
|
|
|
|
|
2024-06-06 18:13:16 +01:00
|
|
|
outputs =
|
|
|
|
{ self
|
|
|
|
, nixpkgs
|
|
|
|
, home-manager
|
|
|
|
, ...
|
|
|
|
} @ inputs:
|
|
|
|
let
|
|
|
|
inherit (self) outputs;
|
|
|
|
systems = [
|
|
|
|
"x86_64-linux"
|
|
|
|
];
|
|
|
|
forAllSystems = nixpkgs.lib.genAttrs systems;
|
|
|
|
specialArgs = { inherit inputs outputs; };
|
|
|
|
in
|
|
|
|
{
|
|
|
|
packages = forAllSystems (system: import ./pkgs nixpkgs.legacyPackages.${system});
|
|
|
|
formatter = forAllSystems (system: nixpkgs.legacyPackages.${system}.alejandra);
|
|
|
|
overlays = import ./overlays { inherit inputs; };
|
|
|
|
nixosModules = import ./modules/nixos;
|
|
|
|
homeManagerModules = import ./modules/home-manager;
|
2024-05-09 12:03:13 +01:00
|
|
|
|
2024-06-06 18:13:16 +01:00
|
|
|
# System level configs
|
|
|
|
nixosConfigurations = {
|
|
|
|
nixdev = nixpkgs.lib.nixosSystem {
|
|
|
|
inherit specialArgs;
|
|
|
|
modules = [
|
|
|
|
./hosts/nixdev
|
|
|
|
home-manager.nixosModules.home-manager
|
|
|
|
{
|
|
|
|
home-manager.extraSpecialArgs = specialArgs;
|
|
|
|
}
|
|
|
|
];
|
|
|
|
};
|
|
|
|
fileserver = nixpkgs.lib.nixosSystem {
|
|
|
|
inherit specialArgs;
|
|
|
|
modules = [
|
|
|
|
./hosts/fileserver
|
|
|
|
home-manager.nixosModules.home-manager
|
|
|
|
{
|
|
|
|
home-manager.extraSpecialArgs = specialArgs;
|
|
|
|
}
|
|
|
|
];
|
|
|
|
};
|
|
|
|
bootstrap = nixpkgs.lib.nixosSystem {
|
|
|
|
inherit specialArgs;
|
|
|
|
modules = [
|
|
|
|
./hosts/bootstrap
|
|
|
|
];
|
|
|
|
};
|
|
|
|
sparky = nixpkgs.lib.nixosSystem {
|
|
|
|
inherit specialArgs;
|
|
|
|
modules = [
|
|
|
|
./hosts/sparky
|
|
|
|
home-manager.nixosModules.home-manager
|
|
|
|
{
|
|
|
|
home-manager.extraSpecialArgs = specialArgs;
|
|
|
|
}
|
|
|
|
];
|
|
|
|
};
|
|
|
|
semita = nixpkgs.lib.nixosSystem {
|
|
|
|
inherit specialArgs;
|
|
|
|
modules = [
|
|
|
|
./hosts/semita
|
|
|
|
home-manager.nixosModules.home-manager
|
|
|
|
{
|
|
|
|
home-manager.extraSpecialArgs = specialArgs;
|
|
|
|
}
|
|
|
|
];
|
|
|
|
};
|
2024-06-28 15:26:16 +01:00
|
|
|
nebula = nixpkgs.lib.nixosSystem {
|
2024-06-25 18:19:47 +01:00
|
|
|
inherit specialArgs;
|
|
|
|
modules = [
|
2024-06-28 15:26:16 +01:00
|
|
|
./hosts/nebula
|
2024-06-25 18:19:47 +01:00
|
|
|
home-manager.nixosModules.home-manager
|
|
|
|
{
|
|
|
|
home-manager.extraSpecialArgs = specialArgs;
|
|
|
|
}
|
|
|
|
];
|
|
|
|
};
|
2024-05-08 00:45:54 +01:00
|
|
|
};
|
2024-06-23 15:22:51 +01:00
|
|
|
};
|
2024-05-08 00:45:54 +01:00
|
|
|
}
|