Skip to content
Snippets Groups Projects
Commit ffc0db5a authored by Christopher Lübbemeier's avatar Christopher Lübbemeier
Browse files

Add documentation for autostart

parent cba0d80f
No related branches found
No related tags found
No related merge requests found
......@@ -61,7 +61,7 @@ gnome-keyring-yubikey-unlock/create_secret_file.sh /path/to/your_secret [Your Gn
As an example, I need to input `login:My_Very_Long_Login_Password`. (You may use `seahorse` or `tools/list_keyrings.sh` to determine the name of your keyring)
Then, add the following command to gnome-autostart. You should know how to auto-run a command after starting gnome.
Then, add the following command to gnome-autostart. If you don't know how to do it, [read me](doc/how-to-gnome-autostart.md)!
```
/path/to/this/project/unlock_keyrings.sh /path/to/your_secret
......
# How To Autostart On Gnome
To automatically unlock keyrings right after logging into Gnome, you need to autostart
`unlock_keyrings.sh`. There are different ways to to this.
## Start Via Systemd
Create a new file at `~/.config/systemd/user/unlock-keyring.service` with the following content
(adapt the command after `ExecStart` to your setup):
```ini
[Unit]
Description=Unlock keyring using YubiKey
BindsTo=gnome-session.target
[Service]
Type=oneshot
ExecStart=/path/to/this/project/unlock_keyrings.sh /path/to/your_secret 123456
[Install]
WantedBy=gnome-session.target
```
Run the following command (not root):
```sh
systemctl --user enable unlock-keyring.service
```
When doing changes to the service file, run
```sh
systemctl --user daemon-reload
```
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment