56e9784b85e816bb80f1a5696b2cc29be336eb9b

Author
Rob Berwick <rob.berwick@gmail.com>
Committer
GitHub <noreply@github.com>
Date

Message

docs: Add `IdentitiesOnly` option to ssh command examples (#628)

Diff

 1diff --git a/README.md b/README.md
 2index c28415812a7d0072d3120294ab5af026e885bb6d..0c5414b1f8660931245e71a66ff78492ab51ffde 100644
 3--- a/README.md
 4+++ b/README.md
 5@@ -110,7 +110,7 @@ and database.
 6 
 7 By default, program configuration is stored within the `data` directory. But,
 8 this can be overridden by setting a custom path to a config file with `SOFT_SERVE_CONFIG_LOCATION`
 9-that is pre-created. If a config file pointed to by `SOFT_SERVE_CONFIG_LOCATION`, 
10+that is pre-created. If a config file pointed to by `SOFT_SERVE_CONFIG_LOCATION`,
11 the default location within the `data` dir is used for generating a default config.
12 
13 To change the default data path use `SOFT_SERVE_DATA_PATH` environment variable.
14@@ -315,13 +315,17 @@ Soft Serve at its core manages your server authentication and authorization. Aut
15 
16 To manage the server users, access, and repos, you can use the SSH command line interface.
17 
18-Try `ssh localhost -i ~/.ssh/id_ed25519 -p 23231 help` for more info. Make sure
19+Try `ssh localhost -i ~/.ssh/id_ed25519 -o IdentitiesOnly=yes -p 23231 help` for more info. Make sure
20 you use your key here.
21 
22+> **Note** The `IdentitiesOnly` option is used to prevent SSH from using any
23+> other keys in your `~/.ssh` directory. This is useful when you have multiple
24+> keys, and you want to use a specific key for Soft Serve.
25+
26 For ease of use, instead of specifying the key, port, and hostname every time
27 you SSH into Soft Serve, add your own Soft Serve instance entry to your SSH
28 config. For instance, to use `ssh soft` instead of typing `ssh localhost -i
29-~/.ssh/id_ed25519 -p 23231`, we can define a `soft` entry in our SSH config
30+~/.ssh/id_ed25519 -o IdentitiesOnly=yes -p 23231`, we can define a `soft` entry in our SSH config
31 file `~/.ssh/config`.
32 
33 ```conf
34@@ -329,6 +333,7 @@ Host soft
35   HostName localhost
36   Port 23231
37   IdentityFile ~/.ssh/id_ed25519
38+  IdentitiesOnly yes
39 ```
40 
41 Now, we can do `ssh soft` to SSH into Soft Serve. Since `git` is also aware of
42@@ -341,7 +346,7 @@ git clone ssh://soft/dotfiles
43 git push origin main
44 ```
45 
46-> **Note** The `-i` part will be omitted in the examples below for brevity. You
47+> **Note** The `-i` and `-o` parts will be omitted in the examples below for brevity. You
48 > can add your server settings to your sshconfig for quicker access.
49 
50 ### Authentication