mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-22 15:03:28 +00:00
f72432aeb2
... which is like a specialisation, but for nixos-rebuild build-vm
23 lines
461 B
Nix
23 lines
461 B
Nix
{ configuration ? import ./lib/from-env.nix "NIXOS_CONFIG" <nixos-config>
|
|
, system ? builtins.currentSystem
|
|
}:
|
|
|
|
let
|
|
|
|
eval = import ./lib/eval-config.nix {
|
|
inherit system;
|
|
modules = [ configuration ];
|
|
};
|
|
|
|
in
|
|
|
|
{
|
|
inherit (eval) pkgs config options;
|
|
|
|
system = eval.config.system.build.toplevel;
|
|
|
|
vm = eval.config.virtualisation.vmVariant.system.build.vm;
|
|
|
|
vmWithBootLoader = eval.config.virtualisation.vmVariantWithBootLoader.system.build.vm;
|
|
}
|