add service for lock

This commit is contained in:
Daylin Morgan 2024-02-20 04:16:11 -06:00
parent 544216f83f
commit ec747a04e8
Signed by: daylin
GPG key ID: C1E52E7DD81DF79F

View file

@ -17,6 +17,17 @@
};
in {
config = mkIf cfg.enable {
systemd.services.screen-locker = {
wantedBy = ["sleep.target"];
description = "Lock the screen using a custom lock script";
before = ["suspend.target"];
serviceConfig = {
User = "daylin";
Type = "forking";
Environment = "DISPLAY=:0";
ExecStart = "${lock}/bin/lock";
};
};
security.pam.services.swaylock = {};
# programs.hyprland.package = inputs.hyprland.packages.${pkgs.system}.default;
# Optional, hint electron apps to use wayland: