feat: Implement hybrid console mode for workshop VM

This commit is contained in:
2025-08-16 16:27:57 +02:00
parent 1fdf506d7a
commit 2c34741b03
2 changed files with 24 additions and 14 deletions

View File

@@ -76,22 +76,27 @@
networking.networkmanager.enable = true;
networking.firewall.enable = false;
# Serial console configuration - the RIGHT way
# Hybrid console configuration - serial primary, GUI available
boot.kernelParams = [ "console=ttyS0,115200" "console=tty1" ];
# VM specific settings
virtualisation.memorySize = 4096;
virtualisation.diskSize = 40000;
# Force serial console as primary
# Hybrid mode: GUI available but serial console primary
virtualisation.qemu.options = [
"-nographic"
"-display" "gtk"
"-monitor" "stdio"
];
# Fix the auto-login conflict with mkForce
services.displayManager.autoLogin = lib.mkForce {
enable = true;
user = "workshop";
};
# Keep GUI session commands for when GUI is used
services.xserver.displayManager.sessionCommands = ''
${pkgs.xfce.xfce4-terminal}/bin/xfce4-terminal --fullscreen --title="Workshop Terminal" &
'';
})
];
};