nix-config/flake.nix

38 lines
931 B
Nix
Raw Normal View History

2024-09-16 22:04:47 +02:00
{
description = "My system flake";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
stable.url = "github:NixOS/nixpkgs/nixos-24.05";
nix-flatpak.url = "github:gmodena/nix-flatpak";
home-manager = {
url = "github:nix-community/home-manager";
inputs.nixpkgs.follows = "nixpkgs";
2024-09-16 22:04:47 +02:00
};
2024-09-22 21:36:02 +02:00
disko.url = "github:nix-community/disko";
2024-09-16 22:04:47 +02:00
};
outputs =
inputs@{ self, nixpkgs, ... }:
2024-10-02 21:32:58 +02:00
let
hosts = ["work-ntb" "lenar"];
in {
# Please replace my-nixos with your hostname
2024-10-02 21:32:58 +02:00
nixosConfigurations = nixpkgs.lib.genAttrs hosts (host: nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
modules = [
2024-10-02 21:32:58 +02:00
./hosts/${host}
2024-09-20 23:15:30 +02:00
./hosts/base
];
2024-09-20 23:44:27 +02:00
specialArgs = {
inherit inputs;
};
2024-10-02 21:32:58 +02:00
}
);
formatter.x86_64-linux = nixpkgs.legacyPackages.x86_64-linux.nixfmt-rfc-style;
2024-09-16 22:04:47 +02:00
};
}