Skip to content
This repository has been archived by the owner on Sep 26, 2021. It is now read-only.

Commit

Permalink
Explain how to prepare a Go 1.5 development environment
Browse files Browse the repository at this point in the history
Other minor documentation fixes

Signed-off-by: Giuseppe Mazzotta <gdm85@users.noreply.github.com>
  • Loading branch information
gdm85 committed Oct 11, 2015
1 parent 6a5219b commit a82d2cd
Showing 1 changed file with 20 additions and 9 deletions.
29 changes: 20 additions & 9 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,29 +14,40 @@ Docker does things, you'll feel right at home.
Otherwise, please read [Docker's contributions
guidelines](https://github.com/docker/docker/blob/master/CONTRIBUTING.md).

# Building using docker
# Building

The requirements to build Machine are:

1. A running instance of Docker
1. A running instance of Docker or a Golang 1.5 development environment
2. The `bash` shell
3. [Make](https://www.gnu.org/software/make/)

Call `export USE_CONTAINER=true` to instruct the build system to use containers to build.
## Build using Docker containers

# Alternative: build using go only
To build the `docker-machine` binary using containers, simply run:

Alternatively, you can build without docker, using only golang.
$ export USE_CONTAINER=true
$ make build

[Install and setup go](https://golang.org/doc/install), then clone the machine repository inside your gopath.
## Local Go 1.5 development environment

## Building
Make sure the source code directory is under a correct directory structure to use Go 1.5 vendoring;
example of cloning and preparing the correct environment `GOPATH`:
```
mkdir -p projects/docker-machine/src/github.com/docker
export GOPATH="$PWD/projects/docker-machine"
cd projects/docker-machine/src/github.com/docker
git clone https://github.com/docker/machine
cd machine
```

To build the docker-machine binary, simply run:
At this point, simply run:

$ make build

From the Machine repository's root. You will now have a `bin/docker-machine`.
## Built binary

After the build is complete a `bin/docker-machine` binary will be created.

You may call:

Expand Down

0 comments on commit a82d2cd

Please sign in to comment.