docs: fix docker run
cmd + add how to quickly login
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
23
README.md
23
README.md
@@ -26,10 +26,10 @@
|
|||||||
$ docker run -it \
|
$ docker run -it \
|
||||||
--name jumpbox \
|
--name jumpbox \
|
||||||
-v $(pwd)/jumpbox:/var/lib/jumpbox \
|
-v $(pwd)/jumpbox:/var/lib/jumpbox \
|
||||||
-e "ROOT_AUTHORIZED_KEYS=/var/lib/jumpbox/authorized_keys"
|
-e "ROOT_AUTHORIZED_KEYS=/var/lib/jumpbox/authorized_keys" \
|
||||||
-e "HOSTKEYS=/var/lib/jumpbox/ssh_host_ed25519_key;/var/lib/jumpbox/ssh_host_rsa_key"
|
-e "HOSTKEYS=/var/lib/jumpbox/ssh_host_ed25519_key;/var/lib/jumpbox/ssh_host_rsa_key" \
|
||||||
-e "USERADD=jumpbox:1000:1000:/bin/bash"
|
-e "USERADD=jumpbox:1000:1000:/bin/bash" \
|
||||||
-e "GROUPADD=jumpbox:1000"
|
-e "GROUPADD=jumpbox:1000" \
|
||||||
-p 1022:22 \
|
-p 1022:22 \
|
||||||
pommib/jumpbox:latest
|
pommib/jumpbox:latest
|
||||||
```
|
```
|
||||||
@@ -53,3 +53,18 @@ services:
|
|||||||
USERADD: jumpbox:1000:1000:/bin/bash
|
USERADD: jumpbox:1000:1000:/bin/bash
|
||||||
GROUPADD: jumpbox:1000
|
GROUPADD: jumpbox:1000
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Login as root
|
||||||
|
|
||||||
|
```
|
||||||
|
$ ssh -l root 127.0.0.1 -p 1022
|
||||||
|
```
|
||||||
|
|
||||||
|
## Login as jumpbox
|
||||||
|
|
||||||
|
To login as user jumpbox, make sure `/home/jumpbox` is a mounted volume
|
||||||
|
containing `.ssh/authorized_keys` containing your public key.
|
||||||
|
|
||||||
|
```
|
||||||
|
$ ssh -l jumpbox 127.0.0.1 -p 1022
|
||||||
|
```
|
||||||
|
Reference in New Issue
Block a user