Browse code

Minor changes to SSHd example

Docker-DCO-1.1-Signed-off-by: James Turnbull <james@lovedthanlost.net> (github: jamtur01)

James Turnbull authored on 2014/10/12 05:30:36
Showing 1 changed files
... ...
@@ -46,7 +46,8 @@ the container's port 22 is mapped to:
46 46
 
47 47
 And now you can ssh as `root` on the container's IP address (you can find it
48 48
 with `docker inspect`) or on port `49154` of the Docker daemon's host IP address
49
-(`ip address` or `ifconfig` can tell you that):
49
+(`ip address` or `ifconfig` can tell you that) or `localhost` if on the
50
+Docker daemon host:
50 51
 
51 52
     $ ssh root@192.168.1.2 -p 49154
52 53
     # The password is ``screencast``.
... ...
@@ -55,15 +56,15 @@ with `docker inspect`) or on port `49154` of the Docker daemon's host IP address
55 55
 ## Environment variables
56 56
 
57 57
 Using the `sshd` daemon to spawn shells makes it complicated to pass environment
58
-variables to the user's shell via the simple Docker mechanisms, as `sshd` scrubs
58
+variables to the user's shell via the normal Docker mechanisms, as `sshd` scrubs
59 59
 the environment before it starts the shell.
60 60
 
61
-If you're setting values in the Dockerfile using `ENV`, you'll need to push them
62
-to a shell initialisation file like the `/etc/profile` example in the Dockerfile
61
+If you're setting values in the `Dockerfile` using `ENV`, you'll need to push them
62
+to a shell initialization file like the `/etc/profile` example in the `Dockerfile`
63 63
 above.
64 64
 
65 65
 If you need to pass`docker run -e ENV=value` values, you will need to write a
66
-short script to do the same before you start `sshd -D` - and then replace the
66
+short script to do the same before you start `sshd -D` and then replace the
67 67
 `CMD` with that script.
68 68
 
69 69
 ## Clean up