summaryrefslogtreecommitdiff
path: root/plugins/ssh-agent/README.md
diff options
context:
space:
mode:
authorNuno Goncalves <nunojpg@gmail.com>2021-06-12 04:03:25 +0200
committerGitHub <noreply@github.com>2021-06-11 19:03:25 -0700
commita206271460ce49e842b1b410c0424b8c9a0a3d14 (patch)
tree294a3c55b1fdfb479d67dd247d4103b3bf2704ed /plugins/ssh-agent/README.md
parent02ce2c4a2f563c4e092410fe3ddc8b29b6de7fdc (diff)
downloadzsh-a206271460ce49e842b1b410c0424b8c9a0a3d14.tar.gz
zsh-a206271460ce49e842b1b410c0424b8c9a0a3d14.tar.bz2
zsh-a206271460ce49e842b1b410c0424b8c9a0a3d14.zip
ssh-agent: improvements (#6309)
* ssh-agent: lock this script with a mkdir style mutex This script is a kind of singleton pattern and is not reentrant. If several shells are oppened in a fast sequence, then several independent ssh-agents would be created, which is not acceptable. A mutex is required. Signed-off-by: Nuno Goncalves <nunojpg@gmail.com> * ssh-agent: only start agent if .ssh dir exists To use the same profile system-wide, it might happen that the .ssh directory does not exist (typically $HOME/.ssh/). This would trigger a error. Creating the directory would be a option, but it usually will not make sense to do so because it means the user doesn't have ssh keys or config. Signed-off-by: Nuno Goncalves <nunojpg@gmail.com> * ssh-agent: adds lazy option to disable key loading on start Option is documented on updated README.md Signed-off-by: Nuno Goncalves <nunojpg@gmail.com> * ssh-agent: simplify agent-forwarding checking Signed-off-by: Nuno Goncalves <nunojpg@gmail.com> Co-authored-by: Robby Russell <robby@planetargon.com>
Diffstat (limited to 'plugins/ssh-agent/README.md')
-rw-r--r--plugins/ssh-agent/README.md12
1 files changed, 10 insertions, 2 deletions
diff --git a/plugins/ssh-agent/README.md b/plugins/ssh-agent/README.md
index 8765a9c7e..aa96f9cc9 100644
--- a/plugins/ssh-agent/README.md
+++ b/plugins/ssh-agent/README.md
@@ -19,9 +19,17 @@ To enable **agent forwarding support** add the following to your zshrc file:
zstyle :omz:plugins:ssh-agent agent-forwarding on
```
-----
+To **NOT load any identities on start** use the `lazy` style.
+This is particularly usefull when combined with the AddKeysToAgent
+(available from OpenSSH 7.2), since it allows to enter the password only
+on first use.
+
+```zsh
+zstyle :omz:plugins:ssh-agent lazy yes
+```
-To **load multiple identities** use the `identities` style, For example:
+To **load multiple identities** use the `identities` style. This have no
+effect if `lazy` is enabled.
```zsh
zstyle :omz:plugins:ssh-agent identities id_rsa id_rsa2 id_github