nixos-configuration/modules/debug.nix
2025-04-09 10:20:44 +02:00

16 lines
410 B
Nix

{ config, lib, ... }:
let
cfg = config.jalr.debug;
in
{
options.jalr.debug = {
enable = lib.mkEnableOption "debugging helpers, DO NOT USE IN PRODUCTION!";
};
config = lib.mkIf cfg.enable {
services.getty.autologinUser = "root";
boot.initrd.systemd.emergencyAccess = true;
systemd.enableEmergencyMode = true;
boot.kernelParams = [ "systemd.setenv=SYSTEMD_SULOGIN_FORCE=1" ];
};
}