I have a laptop that runs Debian Jessie with only the Linux console - no X server installed.
A recent dist-upgrade replaced sysvinit with systemd.
Now I'm trying to get systemd to lock the console when the computer sleeps (this was previously handled by a script in /etc/pm/sleep.d.)
I've tried this:
/etc/systemd/system/screenlock.service:
[Unit]
Description=Lock X session using slock
Before=sleep.target
[Service]
User=<username>
ExecStart=/usr/bin/vlock -ans
[Install]
WantedBy=sleep.target
And then:
systemctl enable screenlock.service
A similar solution works for me on another computer with X but this isn't working in the console.
How can that be?
apt-cache search vlock– eyoung100 Oct 1 '14 at 18:41