Skip to content

Commit 01f3b54

Browse files
committed
added systemd unit to autostart ssh-agent
1 parent 14e8f5a commit 01f3b54

File tree

4 files changed

+18
-0
lines changed

4 files changed

+18
-0
lines changed

neovim/.config/nvim/spell/en.utf-8.add

+5
Original file line numberDiff line numberDiff line change
@@ -24,3 +24,8 @@ Kata
2424
ctl
2525
NDSU
2626
rebasing
27+
posix
28+
tmux
29+
keybinds
30+
dotfile
31+
dotfiles
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
[Unit]
2+
Description=SSH key agent
3+
4+
[Service]
5+
Type=simple
6+
Environment=SSH_AUTH_SOCK=%t/ssh-agent.socket
7+
ExecStart=/usr/bin/ssh-agent -D -a $SSH_AUTH_SOCK
8+
9+
[Install]
10+
WantedBy=default.target

ssh/.ssh/config

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
AddKeysToAgent yes

zsh/.zshrc

+2
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,8 @@
3131
export LESSHISTFILE="/dev/null"
3232
#set the w3m homepage
3333
export WWW_HOME="duckduckgo.com/lite/"
34+
#set ssh-agent to play nice with systemd.
35+
export SSH_AUTH_SOCK="$XDG_RUNTIME_DIR/ssh-agent.socket"
3436

3537
#web_search from terminal
3638
function web_search() {

0 commit comments

Comments
 (0)