xlock/systemd/xlock@.service

18 lines
275 B
SYSTEMD

[Unit]
Description=Locker daemon
# allows infinite restarts
StartLimitIntervalSec=0
[Service]
Type=simple
User=%i
Group=%i
Restart=always
Environment="DISPLAY=:0"
Environment="XAUTHORITY=/home/%i/.Xauthority"
ExecStart=/usr/sbin/xlock
[Install]
WantedBy=multi-user.target