From e5cbb5c906d37b14dbf0180d253f58f8995de571 Mon Sep 17 00:00:00 2001 From: Sven Dowideit Date: Tue, 18 Mar 2014 22:29:11 +1000 Subject: [PATCH] add env hint Docker-DCO-1.1-Signed-off-by: Sven Dowideit (github: SvenDowideit) --- docs/sources/use/working_with_links_names.rst | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/docs/sources/use/working_with_links_names.rst b/docs/sources/use/working_with_links_names.rst index dc370c01c9..4acb6079c1 100644 --- a/docs/sources/use/working_with_links_names.rst +++ b/docs/sources/use/working_with_links_names.rst @@ -112,8 +112,16 @@ Accessing the network information along with the environment of the child container allows us to easily connect to the Redis service on the specific IP and port in the environment. +.. note:: + These Environment variables are only set for the first process in + the container. Similarly, some daemons (such as ``sshd``) will + scrub them when spawning shells for connection. + + You can work around this by storing the initial ``env`` in a file, + or looking at ``/proc/1/environ``. + Running ``docker ps`` shows the 2 containers, and the ``webapp/db`` -alias name for the redis container. +alias name for the Redis container. .. code-block:: bash