wfvm/flake.nix

38 lines
757 B
Nix
Raw Normal View History

2022-10-11 06:10:32 +08:00
{
description = "WFVM: Windows Functional Virtual Machine";
inputs = {
2023-05-27 15:15:33 +08:00
nixpkgs.url = "github:NixOS/nixpkgs/nixos-23.05";
2022-10-11 06:10:32 +08:00
};
outputs = { self, nixpkgs }:
let
# only x64 is supported
system = "x86_64-linux";
pkgs = nixpkgs.legacyPackages.${system};
2023-05-27 15:36:00 +08:00
in rec {
2022-10-11 06:10:32 +08:00
lib = import ./wfvm {
inherit pkgs;
};
2023-05-27 15:36:00 +08:00
packages.${system} = rec {
demoImage = import ./wfvm/demo-image.nix {
inherit self;
};
default = lib.utils.wfvm-run {
name = "demo";
image = demoImage;
script =
''
echo "Windows booted. Press Enter to terminate VM."
read
'';
display = true;
};
};
2022-10-11 06:10:32 +08:00
};
}