nixos/flake.nix

58 lines
1.2 KiB
Nix
Raw Normal View History

2024-03-01 15:22:49 +01:00
{
description = "Nixos config flake";
inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-23.11";
2024-03-01 15:22:49 +01:00
unstable.url = "github:nixos/nixpkgs/nixos-unstable";
home-manager = {
url = "github:nix-community/home-manager/release-23.11";
inputs.nixpkgs.follows = "nixpkgs";
};
sops-nix = {
url = "github:Mic92/sops-nix";
inputs.nixpkgs.follows = "nixpkgs";
};
2024-03-01 15:22:49 +01:00
};
outputs = {
self,
nixpkgs,
home-manager,
sops-nix,
...
} @ inputs: let
system = "x86_64-linux";
unstable = final: prev: {
unstable = import inputs.unstable {
system = final.system;
config = final.config;
};
};
pkgs = import nixpkgs {
inherit system;
overlays = [unstable];
config.allowUnfree = true;
};
in {
nixosConfigurations."MaxNixosLaptop" = nixpkgs.lib.nixosSystem {
specialArgs = {
inherit inputs;
inherit pkgs;
};
system = "x86_64-linux";
modules = [
./hosts/MaxNixosLaptop/configuration.nix
sops-nix.nixosModules.sops
home-manager.nixosModules.default
{
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
}
];
2024-03-01 15:22:49 +01:00
};
};
2024-03-01 15:22:49 +01:00
}