first commit

This commit is contained in:
2025-12-31 12:01:37 +01:00
commit 3b06ef4418
16 changed files with 400 additions and 0 deletions

72
flake.nix Normal file
View File

@@ -0,0 +1,72 @@
{
description = "Meine NixOS configuration";
inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
nixpkgs-stable.url = "github:nixos/nixpkgs/nixos-25.11";
systems.url = "github:nix-systems/default-linux";
hardware.url = "github:nixos/nixos-hardware";
home-manager = {
url = "github:nix-community/home-manager";
inputs.nixpkgs.follows = "nixpkgs";
};
sops-nix = {
url = "github:mic92/sops-nix";
inputs.nixpkgs.follows = "nixpkgs";
};
};
outputs = {
self,
nixpkgs,
home-manager,
systems,
...
} @ inputs : let
inherit (self) outputs;
lib = nixpkgs.lib // home-manager.lib;
forEachSystem = f: lib.genAttrs (import systems) (system: f pkgsFor.${system});
pkgsFor = lib.genAttrs (import systems) (
system:
import nixpkgs {
inherit system;
config.allowUnfree = true;
}
);
in {
inherit lib;
nixosModules = import ./modules/nixos;
#homeManagerModules = import ./modules/home-manager;
#overlays = import ./overlays {inherit inputs outputs;};
hydraJobs = import ./hydra.nix {inherit inputs outputs;};
packages = forEachSystem (pkgs: import ./pkgs {inherit pkgs;});
devShells = forEachSystem (pkgs: import ./shell.nix {inherit pkgs;});
formatter = forEachSystem (pkgs: pkgs.alejandra);
nixosConfigurations = {
raidy = lib.nixosSystem {
modules = [./hosts/raidy];
specialArgs = {
inherit inputs outputs;
};
};
};
homeConfigurations = {
"dwessels@electra" = lib.homeManagerConfiguration {
modules = [ ./home/dwessels/electra.nix ]; # ./home/dwessels/nixpkgs.nix ];
pkgs = pkgsFor.x86_64-linux;
extraSpecialArgs = {
inherit inputs outputs;
};
};
};
};
}