Browse code

- Remove references to sudo in basics.md; see sudo instructions top of file - Removing references to Boot2Docker replacing with Docker Machine - Removing sudo warnings in instances where appropriate (no sudo in file) - Updating with comments

Signed-off-by: Mary Anthony <mary@docker.com>

Mary Anthony authored on 2015/08/06 01:07:11
Showing 12 changed files
... ...
@@ -83,8 +83,8 @@ own.
83 83
 	container with this image.
84 84
 
85 85
 	The container exposes port 8000 on the localhost so that you can connect and
86
-	see your changes. If you are running Boot2Docker, use the `boot2docker ip`
87
-	to get the address of your server.
86
+	see your changes. If you use Docker Machine, the `docker-machine ip
87
+	<machine-name>` command gives you the address of your server.
88 88
 
89 89
 6.  Check your writing for style and mechanical errors.
90 90
 
... ...
@@ -154,18 +154,20 @@ update the root docs pages by running
154 154
 
155 155
      	$ make AWS_S3_BUCKET=dowideit-docs BUILD_ROOT=yes docs-release
156 156
 
157
-### Errors publishing using Boot2Docker
157
+### Errors publishing using a Docker Machine VM
158 158
 
159
-Sometimes, in a Boot2Docker environment, the publishing procedure returns this
159
+Sometimes, in a Windows or Mac environment, the publishing procedure returns this
160 160
 error:
161 161
 
162 162
 	Post http:///var/run/docker.sock/build?rm=1&t=docker-docs%3Apost-1.2.0-docs_update-2:
163 163
 	dial unix /var/run/docker.sock: no such file or directory.
164 164
 
165
-If this happens, set the Docker host. Run the following command to set the
165
+If this happens, set the Docker host. Run the following command to get the
166 166
 variables in your shell:
167 167
 
168
-		$ eval "$(boot2docker shellinit)"
168
+		docker-machine env <machine-name>
169
+		
170
+Then, set your environment accordingly.
169 171
 
170 172
 ## Cherry-picking documentation changes to update an existing release.
171 173
 
... ...
@@ -47,10 +47,6 @@ image cache.
47 47
 > characters of the full image ID - which can be found using
48 48
 > `docker inspect` or `docker images --no-trunc=true`.
49 49
 
50
-> **Note:** if you are using a remote Docker daemon, such as Boot2Docker, 
51
-> then _do not_ type the `sudo` before the `docker` commands shown in the
52
-> documentation's examples.
53
-
54 50
 ## Running an interactive shell
55 51
 
56 52
 To run an interactive shell in the Ubuntu image:
... ...
@@ -58,7 +58,7 @@ First generate CA private and public keys:
58 58
     State or Province Name (full name) [Some-State]:Queensland
59 59
     Locality Name (eg, city) []:Brisbane
60 60
     Organization Name (eg, company) [Internet Widgits Pty Ltd]:Docker Inc
61
-    Organizational Unit Name (eg, section) []:Boot2Docker
61
+    Organizational Unit Name (eg, section) []:Sales
62 62
     Common Name (e.g. server FQDN or YOUR name) []:$HOST
63 63
     Email Address []:Sven@home.org.au
64 64
 
... ...
@@ -311,40 +311,36 @@ installer](https://www.docker.com/toolbox).
311 311
 
312 312
 ## Container port redirection
313 313
 
314
-If you are curious, the username for the Docker default user is `docker`
315
-and the password is `tcuser`.
314
+If you are curious, the username for the Docker default user is `docker` and the
315
+password is `tcuser`. The latest version of `docker-machine` sets up a host only
316
+network adaptor which provides access to the container's ports.
316 317
 
317
-The latest version of `boot2docker` sets up a host only network adaptor which
318
-provides access to the container's ports.
318
+If you run a container with a published port:
319 319
 
320
-If you run a container with an exposed port:
320
+    $ docker run --rm -i -t -p 80:80 nginx
321 321
 
322
-    docker run --rm -i -t -p 80:80 nginx
322
+Then you should be able to access that nginx server using the IP address
323
+reported to you using:
323 324
 
324
-Then you should be able to access that nginx server using the IP address reported
325
-to you using:
325
+    $ docker-machine ip
326 326
 
327
-    boot2docker ip
328
-
329
-Typically, it is 192.168.59.103, but it could get changed by VirtualBox's DHCP
330
-implementation.
331
-
332
-For further information or to report issues, please see the [Boot2Docker site](http://boot2docker.io)
327
+Typically, the IP is 192.168.59.103, but it could get changed by VirtualBox's
328
+DHCP implementation.
333 329
 
334 330
 ## Login with PUTTY instead of using the CMD
335 331
 
336
-Boot2Docker generates and uses the public/private key pair in your `%USERPROFILE%\.ssh`
337
-directory so to log in you need to use the private key from this same directory.
338
-
339
-The private key needs to be converted into the format PuTTY uses.
340
-
341
-You can do this with
332
+Docker Machine generates and uses the public/private key pair in your
333
+`%USERPROFILE%\.ssh` directory so to log in you need to use the private key from
334
+this same directory. The private key needs to be converted into the format PuTTY
335
+uses. You can do this with
342 336
 [puttygen](http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html):
343 337
 
344
-- Open `puttygen.exe` and load ("File"->"Load" menu) the private key from
338
+1. Open `puttygen.exe` and load ("File"->"Load" menu) the private key from
345 339
   `%USERPROFILE%\.ssh\id_boot2docker`
346
-- then click: "Save Private Key".
347
-- Then use the saved file to login with PuTTY using `docker@127.0.0.1:2022`.
340
+
341
+2. Click "Save Private Key".
342
+
343
+3.  Use the saved file to login with PuTTY using `docker@127.0.0.1:2022`.
348 344
 
349 345
 ## Uninstallation
350 346
 
... ...
@@ -33,7 +33,7 @@ Docker currently runs only on Linux, but you can use VirtualBox to run Docker in
33 33
 a virtual machine on your box, and get the best of both worlds. Check out the
34 34
 [*Mac OS X*](/installation/mac/) and [*Microsoft
35 35
 Windows*](/installation/windows/) installation guides. The small Linux
36
-distribution boot2docker can be run inside virtual machines on these two
36
+distribution Docker Machine can be run inside virtual machines on these two
37 37
 operating systems.
38 38
 
39 39
 >**Note:** if you are using a remote Docker daemon on a VM through Docker
... ...
@@ -29,7 +29,7 @@ you continue working with your fork on this branch.
29 29
 
30 30
 ##  Clean your host of Docker artifacts
31 31
 
32
-Docker developers run the latest stable release of the Docker software (with Boot2Docker if their machine is Mac OS X). They clean their local
32
+Docker developers run the latest stable release of the Docker software (with Docker Machine if their machine is Mac OS X). They clean their local
33 33
 hosts of unnecessary Docker artifacts such as stopped containers or unused
34 34
 images. Cleaning unnecessary artifacts isn't strictly necessary, but it is
35 35
 good practice, so it is included here.
... ...
@@ -57,8 +57,8 @@ target="_blank">docker/docker repository</a>.
57 57
 
58 58
         $ cd ~
59 59
         
60
-  In Windows, you'll work in your Boot2Docker window instead of Powershell or
61
-  a `cmd` window.
60
+    In Windows, you'll work in your Docker Quickstart Terminal window instead of
61
+    Powershell or a `cmd` window.
62 62
 
63 63
 6. Create a `repos` directory.
64 64
 
... ...
@@ -258,9 +258,9 @@ can browse the docs.
258 258
 
259 259
 4. Enter the URL in your browser.
260 260
 
261
-    If you are running Boot2Docker, replace the default localhost address
261
+    If you are using Docker Machine, replace the default localhost address
262 262
     (0.0.0.0) with your DOCKERHOST value. You can get this value at any time by
263
-    entering `boot2docker ip` at the command line.
263
+    entering `docker-machine ip <machine-name>` at the command line.
264 264
 
265 265
 5. Once in the documentation, look for the red notice to verify you are seeing the correct build.
266 266
 
... ...
@@ -10,10 +10,6 @@ parent = "smn_cli"
10 10
 
11 11
 # Using the command line
12 12
 
13
-> **Note:** If you are using a remote Docker daemon, such as Boot2Docker,
14
-> then _do not_ type the `sudo` before the `docker` commands shown in the
15
-> documentation's examples.
16
-
17 13
 To list available commands, either run `docker` with no parameters
18 14
 or execute `docker help`:
19 15
 
... ...
@@ -256,7 +256,7 @@ Let's create a directory and a `Dockerfile` first.
256 256
     $ cd sinatra
257 257
     $ touch Dockerfile
258 258
 
259
-If you are using Boot2Docker on Windows, you may access your host
259
+If you are using Docker Machine on Windows, you may access your host
260 260
 directory by `cd` to `/c/Users/your_user_name`.
261 261
 
262 262
 Each instruction creates a new layer of the image. Let's look at a simple
... ...
@@ -15,9 +15,10 @@ parent = "smn_applied"
15 15
 Docker allows you to run applications inside containers. Running an
16 16
 application inside a container takes a single command: `docker run`.
17 17
 
18
-> **Note:** if you are using a remote Docker daemon, such as Boot2Docker, 
19
-> then _do not_ type the `sudo` before the `docker` commands shown in the
20
-> documentation's examples.
18
+>**Note**: Depending on your Docker system configuration, you may be required to
19
+>preface each `docker` command on this page with `sudo`. To avoid this behavior,
20
+>your system administrator can create a Unix group called `docker` and add users
21
+>to it. 
21 22
 
22 23
 ## Hello world
23 24
 
... ...
@@ -90,13 +90,13 @@ You will notice in the above 'Volumes' is specifying the location on the host an
90 90
 In addition to creating a volume using the `-v` flag you can also mount a
91 91
 directory from your Docker daemon's host into a container.
92 92
 
93
-> **Note:**
94
-> If you are using Boot2Docker, your Docker daemon only has limited access to
95
-> your OS X/Windows filesystem. Boot2Docker tries to auto-share your `/Users`
96
-> (OS X) or `C:\Users` (Windows) directory - and so you can mount files or directories
97
-> using `docker run -v /Users/<path>:/<container path> ...` (OS X) or
98
-> `docker run -v /c/Users/<path>:/<container path ...` (Windows). All other paths
99
-> come from the Boot2Docker virtual machine's filesystem.
93
+>**Note**: If you are using Docker Machine on Mac or Windows, your Docker daemon
94
+>only has limited access to your OS X/Windows filesystem. Docker Machine tries
95
+>to auto-share your `/Users` (OS X) or `C:\Users` (Windows) directory - and so
96
+>you can mount files or directories using `docker run -v
97
+>/Users/<path>:/<container path> ...` (OS X) or `docker run -v
98
+>/c/Users/<path>:/<container path ...` (Windows). All other paths come from your
99
+>virtual machine's filesystem.
100 100
 
101 101
     $ docker run -d -P --name web -v /src/webapp:/opt/webapp training/webapp python app.py
102 102