File tree Expand file tree Collapse file tree 7 files changed +12
-10
lines changed Expand file tree Collapse file tree 7 files changed +12
-10
lines changed Original file line number Diff line number Diff line change 112112 name = builtins . replaceStrings [ "${ system } -" ] [ "" ] systemName ;
113113 inherit ( nixos . config . microvm ) hypervisor ;
114114 in
115- if nixos . pkgs . system == nixpkgs . lib . replaceString "-darwin" "-linux" system
115+ if nixos . pkgs . stdenv . hostPlatform . system == nixpkgs . lib . replaceString "-darwin" "-linux" system
116116 then result // {
117117 "${ name } " = nixos . config . microvm . runner . ${ hypervisor } ;
118118 }
Original file line number Diff line number Diff line change 2424 kernelPath = {
2525 x86_64-linux = "${ kernel . dev } /vmlinux" ;
2626 aarch64-linux = "${ kernel . out } /${ pkgs . stdenv . hostPlatform . linux-kernel . target } " ;
27- } . ${ pkgs . stdenv . system } ;
27+ } . ${ pkgs . stdenv . hostPlatform . system } ;
2828
2929 kernelConsoleDefault =
30- if pkgs . stdenv . system == "x86_64-linux"
30+ if pkgs . stdenv . hostPlatform . system == "x86_64-linux"
3131 then "earlyprintk=ttyS0 console=ttyS0"
32- else if pkgs . stdenv . system == "aarch64-linux"
32+ else if pkgs . stdenv . hostPlatform . system == "aarch64-linux"
3333 then "console=ttyAMA0"
3434 else "" ;
3535
Original file line number Diff line number Diff line change 66
77let
88 inherit ( pkgs ) lib ;
9- inherit ( pkgs . stdenv ) system ;
9+ inherit ( pkgs . stdenv . hostPlatform ) system ;
1010 inherit ( microvmConfig )
1111 vcpu mem balloon initialBalloonMem hotplugMem hotpluggedMem user volumes shares
1212 socket devices vsock graphics credentialFiles
Original file line number Diff line number Diff line change 44} :
55
66let
7- inherit ( pkgs ) lib system ;
7+ inherit ( pkgs ) lib ;
8+ inherit ( pkgs . stdenv . hostPlatform ) system ;
89 inherit ( microvmConfig )
910 hostName user socket preStart
1011 vcpu mem balloon initialBalloonMem hotplugMem hotpluggedMem
Original file line number Diff line number Diff line change 77
88let
99 inherit ( pkgs ) lib ;
10- inherit ( pkgs . stdenv ) system ;
10+ inherit ( pkgs . stdenv . hostPlatform ) system ;
1111 inherit ( microvmConfig ) vmHostPackages ;
1212
1313 enableLibusb = pkg : pkg . overrideAttrs ( oa : {
Original file line number Diff line number Diff line change 66} :
77
88let
9- inherit ( pkgs ) lib system ;
9+ inherit ( pkgs ) lib ;
10+ inherit ( pkgs . stdenv . hostPlatform ) system ;
1011
1112 inherit ( microvmConfig )
1213 hostName
Original file line number Diff line number Diff line change 730730
731731 config = lib . mkMerge [ {
732732 microvm . qemu . machine =
733- lib . mkIf ( pkgs . stdenv . system == "x86_64-linux" ) (
733+ lib . mkIf ( pkgs . stdenv . hostPlatform . system == "x86_64-linux" ) (
734734 lib . mkDefault "microvm"
735735 ) ;
736736 } {
737737 microvm . qemu . machine =
738- lib . mkIf ( pkgs . stdenv . system == "aarch64-linux" ) (
738+ lib . mkIf ( pkgs . stdenv . hostPlatform . system == "aarch64-linux" ) (
739739 lib . mkDefault "virt"
740740 ) ;
741741 } ] ;
You can’t perform that action at this time.
0 commit comments