Skip to content

Commit 94d78b3

Browse files
ad-mfredericosilva
authored andcommitted
Update README (#8)
* Update README * Update README.md
1 parent 0327624 commit 94d78b3

1 file changed

Lines changed: 64 additions & 26 deletions

File tree

README.md

Lines changed: 64 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -2,33 +2,66 @@
22

33
[![Build Status](https://travis-ci.com/hyperonecom/docker-machine-driver-hyperone.svg?branch=master)](https://travis-ci.com/hyperonecom/docker-machine-driver-hyperone)
44

5-
HyperOne Driver Plugin for docker-machine.
5+
A Docker Machine driver for [HyperOne](http://www.hyperone.com/). It can be used provision multiple remote Docker hosts on *Virtual Machine*.
66

7-
## Setup
7+
## Requirements
88

9-
### Go
9+
* [Docker Machine](https://docs.docker.com/machine/install-machine)
10+
* [Go tools](https://golang.org/doc/install) (only for installation from sources)
11+
* HyperOne account & access to *Project*
12+
13+
## Installation
14+
15+
### Go tools
1016
```shell
1117
# install latest (git) version of docker-machine-driver-hyperone in your $GOPATH/bin (depends on Golang and docker-machine)
1218
$ go get -u github.com/hyperonecom/docker-machine-driver-hyperone
1319
```
1420

15-
### Binary
21+
### pre-compiled binaries
1622

17-
You can find sources and pre-compiled binaries [here](https://github.com/hyperonecom/docker-machine-driver-hyperone/releases/latest)
23+
You can find sources and pre-compiled binaries on the "[Releases](https://github.com/hyperonecom/docker-machine-driver-hyperone/releases/latest)" page.
24+
25+
Download the binary (this example downloads the binary for darwin amd64):
1826

1927
```shell
20-
# Download the binary (this example downloads the binary for darwin amd64)
2128
$ wget https://github.com/hyperonecom/docker-machine-driver-hyperone/releases/download/v0.0.1/docker-machine-driver-hyperone_0.0.1_darwin_amd64.zip
22-
$ unzip unzip docker-machine-driver-hyperone_0.0.1_darwin_amd64.zip
29+
$ unzip docker-machine-driver-hyperone_0.0.1_darwin_amd64.zip
30+
```
2331

24-
# Make it executable and copy the binary in a directory accessible with your $PATH
32+
Make it executable and copy the binary in a directory accessible on your ```$PATH```:
33+
34+
```shell
2535
$ chmod +x docker-machine-driver-hyperone
2636
$ sudo cp docker-machine-driver-hyperone /usr/local/bin/
2737
```
2838

2939
# Usage
3040

31-
### 1. driver helper
41+
Official documentation for Docker Machine is available on [website](https://docs.docker.com/machine/).
42+
43+
To create a HyperOne Virtual Machine for Docker purposes just run this command:
44+
45+
```shell
46+
$ docker-machine create --driver hyperone --hyperone-token TOKEN --hyperone-project PROJECT vm
47+
Running pre-create checks...
48+
Creating machine...
49+
(vm) Creating HyperOne VM...
50+
Waiting for machine to be running, this may take a few minutes...
51+
Detecting operating system of created instance...
52+
Waiting for SSH to be available...
53+
Detecting the provisioner...
54+
Provisioning with debian...
55+
Copying certs to the local machine directory...
56+
Copying certs to the remote machine...
57+
Setting Docker configuration on the remote daemon...
58+
Checking connection to Docker...
59+
Docker is up and running!
60+
To see how to connect your Docker Client to the Docker Engine running on this virtual machine, run: docker-machine env vm
61+
```
62+
63+
Available options:
64+
3265
```shell
3366
$ docker-machine create -d hyperone -h
3467
Usage: docker-machine create [OPTIONS] [arg...]
@@ -39,7 +72,7 @@ Description:
3972
Run 'docker-machine create --driver name --help' to include the create flags for that driver in the help text.
4073

4174
Options:
42-
75+
4376
--driver, -d "virtualbox" Driver to create machine with. [$MACHINE_DRIVER]
4477
--engine-env [--engine-env option --engine-env option] Specify environment variables to set in the engine
4578
--engine-insecure-registry [--engine-insecure-registry option --engine-insecure-registry option] Specify insecure registries to allow with the created engine
@@ -69,22 +102,27 @@ Options:
69102
--tls-san [--tls-san option --tls-san option] Support extra SANs for TLS certs
70103
```
71104
72-
### 2. Create your machine
105+
## Development
106+
107+
### Build from source
108+
109+
If you wish to work on this driver, you will first need Go installed. Make sure Go is properly installed, including setting up a [GOPATH](https://golang.org/doc/code.html#GOPATH).
110+
111+
Clone the repository:
73112
74113
```shell
75-
$ docker-machine create --driver hyperone --hyperone-token TOKEN --hyperone-project PROJECT vm
76-
Running pre-create checks...
77-
Creating machine...
78-
(vm) Creating HyperOne VM...
79-
Waiting for machine to be running, this may take a few minutes...
80-
Detecting operating system of created instance...
81-
Waiting for SSH to be available...
82-
Detecting the provisioner...
83-
Provisioning with debian...
84-
Copying certs to the local machine directory...
85-
Copying certs to the remote machine...
86-
Setting Docker configuration on the remote daemon...
87-
Checking connection to Docker...
88-
Docker is up and running!
89-
To see how to connect your Docker Client to the Docker Engine running on this virtual machine, run: docker-machine env vm
114+
$ git clone git@github.com:hyperonecom/docker-machine-driver-hyperone.git
115+
$ cd docker-machine-driver-hyperone
90116
```
117+
118+
Run these commands in root of repository to build the plugin binary:
119+
120+
```shell
121+
$ go build
122+
```
123+
124+
After the build is complete, ```docker-machine-driver-hyperone``` binary will be created. Put it in the ```PATH```.
125+
126+
### Running tests
127+
128+
For details how to run tests read the contents of the ```.travis.yml``` file.

0 commit comments

Comments
 (0)