22 lines
536 B
Nix
22 lines
536 B
Nix
# flake.nix
|
|
{
|
|
inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
|
|
outputs = { self, nixpkgs, ... }:
|
|
let
|
|
system = "x86_64-linux";
|
|
test = nixpkgs.lib.nixosSystem {
|
|
inherit system;
|
|
modules = [
|
|
./configuration.nix
|
|
];
|
|
};
|
|
in {
|
|
# Use `flake-config#test` with:
|
|
# nixos-rebuild --flake .#test build-vm
|
|
nixosConfigurations.test = test;
|
|
|
|
# Optional: expose VM script for `nix run .#vms.test`
|
|
vms.test = test.config.system.build.vm;
|
|
};
|
|
}
|