12 lines
221 B
Nix
12 lines
221 B
Nix
{ lib, config, ... }:
|
|
|
|
{
|
|
boot.resumeDevice = (lib.head config.swapDevices).device;
|
|
services.logind = {
|
|
lidSwitch = "suspend-then-hibernate";
|
|
};
|
|
systemd.sleep.extraConfig = ''
|
|
HibernateDelaySec=30m
|
|
'';
|
|
}
|