Skip to content
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 3 additions & 33 deletions lib/runners/qemu.nix
Original file line number Diff line number Diff line change
Expand Up @@ -332,46 +332,16 @@ lib.warnIf (mem == 2048) ''
''
(
${writeQmp { execute = "qmp_capabilities"; }}
${writeQmp {
execute = "input-send-event";
arguments.events = [ {
type = "key";
data = {
down = true;
key = {
type = "qcode";
data = "ctrl";
};
};
} {
type = "key";
data = {
down = true;
key = {
type = "qcode";
data = "alt";
};
};
} {
type = "key";
data = {
down = true;
key = {
type = "qcode";
data = "delete";
};
};
} ];
}}
# wait for exit
${writeQmp { execute = "system_powerdown"; }}
# wait for exit
cat
) | \
${pkgs.socat}/bin/socat STDIO UNIX:${socket},shut-none
''
else throw "Cannot shutdown without socket";

setBalloonScript =
if socket != null
if socket != null && balloon
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This line shoud be changed in the other commit which probably should also be an extra commit.

then ''
VALUE=$(( $SIZE * 1024 * 1024 ))
SIZE=$( (
Expand Down