feat: add _qubesLite options interface to guest config
Adds options._qubesLite.{disposable, idleTimeout} for host to pass
auto-shutdown configuration to guest.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
parent
d328638564
commit
7275698636
1 changed files with 24 additions and 6 deletions
|
|
@ -9,10 +9,27 @@
|
|||
#
|
||||
{ config, pkgs, lib, wayland-proxy-virtwl, ... }:
|
||||
|
||||
{
|
||||
#############################################################################
|
||||
# Boot Configuration - Systemd Stage 1
|
||||
#############################################################################
|
||||
let
|
||||
cfg = config._qubesLite;
|
||||
in {
|
||||
options._qubesLite = {
|
||||
disposable = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
description = "Whether this VM should auto-shutdown when idle.";
|
||||
};
|
||||
|
||||
idleTimeout = lib.mkOption {
|
||||
type = lib.types.int;
|
||||
default = 60;
|
||||
description = "Seconds to wait after last command before shutdown.";
|
||||
};
|
||||
};
|
||||
|
||||
config = {
|
||||
#############################################################################
|
||||
# Boot Configuration - Systemd Stage 1
|
||||
#############################################################################
|
||||
|
||||
boot.initrd.systemd.enable = true;
|
||||
|
||||
|
|
@ -361,6 +378,7 @@
|
|||
# Disable services we don't need
|
||||
services.timesyncd.enable = false;
|
||||
|
||||
# System version
|
||||
system.stateVersion = "25.11";
|
||||
# System version
|
||||
system.stateVersion = "25.11";
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue