From 99c8703180b69b70e35d602669080914e6447c28 Mon Sep 17 00:00:00 2001 From: Tiffany Jernigan Date: Tue, 22 Mar 2016 19:07:50 -0700 Subject: [PATCH 1/2] Fixed sentence wording on tutorial.md --- tutorial.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tutorial.md b/tutorial.md index 1fe2e7d..9064e53 100644 --- a/tutorial.md +++ b/tutorial.md @@ -203,7 +203,7 @@ The image that you are going to use is a single-page website that was already cr $ docker run seqvence/static-site ``` Since the image doesn't exist on your Docker host, the Docker daemon will first fetch the image from the registry and then run the image. -Okay, now that the server is running, how do see the website? What port is it running on? And more importantly, how do you access the container directly from our host machine? +Okay, now that the server is running, do you see the website? What port is it running on? And more importantly, how do you access the container directly from our host machine? In this case, the client didn't tell the Docker Engine to publish any of the ports so you need to re-run the `docker run` command. We'll take the oportunity to publish ports and pass your name to the container to customize the message displayed. While we are at it, you should also find a way so that our terminal is not attached to the running container. So that you can happily close your terminal and keep the container running. This is called the **detached** mode. From 7476951b8a5216291047f5af9c437e7dd2f29817 Mon Sep 17 00:00:00 2001 From: Tiffany Jernigan Date: Tue, 22 Mar 2016 19:17:54 -0700 Subject: [PATCH 2/2] Added docker-machine eval comment and IP note --- tutorial.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tutorial.md b/tutorial.md index 9064e53..c407bd7 100644 --- a/tutorial.md +++ b/tutorial.md @@ -209,7 +209,7 @@ In this case, the client didn't tell the Docker Engine to publish any of the por Before we look at the **detached** mode, we should first find out a way to stop the container that you have just launched. -First up, launch another terminal (command window) and execute the following command: +First up, launch another terminal (command window) and execute the following command. If you're using docker-machine you need to run `eval $(docker-machine env )` in each new terminal otherwise you'll get the error "Cannot connect to the Docker daemon. Is the docker daemon running on this host?". ``` $ docker ps CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES @@ -241,7 +241,7 @@ $ docker port static-site 80/tcp -> 0.0.0.0:32773 ``` -If you're on Linux, you can open [http://localhost:32773](http://localhost:32773) in your browser. If you're on Windows or a Mac, you need to find the IP of the hostname. +If you're on Linux, you can open [http://localhost:32773](http://localhost:32773) (replace 32773 with your port for 80/tcp) in your browser. If you're on Windows or a Mac, you need to find the IP of the hostname. ``` $ docker-machine ip default