examples: Move the Docker for Mac blueprint to examples

- merge base.yml and docker-ce.yml to docker-for-mac.yml
- Adjust the README

Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
This commit is contained in:
Rolf Neugebauer
2018-01-19 11:37:53 +00:00
parent f43b62a35b
commit 8028f68e0a
6 changed files with 59 additions and 92 deletions

View File

@@ -0,0 +1,29 @@
# Docker for Mac
[`docker-for-mac.yml`](./docker-for-mac.yml) contains an example use
of the open source components of Docker for Mac. The example has
support for controlling `dockerd` from the host via `vsudd` and port
forwarding with VPNKit. It requires HyperKit, VPNKit and a Docker
client on the host to run. The easiest way to install these at the
moment is to install a recent version of Docker for Mac.
To build it with the latest Docker CE:
```
$ linuxkit build docker-for-mac.yml
```
To run the VM with a 4G disk:
```
linuxkit run hyperkit -networking=vpnkit -vsock-ports=2376 -disk size=4096M -data-file ./metadata.json docker-for-mac
```
In another terminal you should now be able to access docker via the
socket `guest.00000947` in the state directory
(`docker-for-mac-state/` by default):
```
$ docker -H unix://docker-for-mac-state/guest.00000948 ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
```