Skip to content

Commit f539586

Browse files
Merge pull request #19112 from adambkaplan/feature/contributing-docfix
Updates to CONTRIBUTING documentation.
2 parents ce742c8 + a297c4d commit f539586

File tree

2 files changed

+52
-63
lines changed

2 files changed

+52
-63
lines changed

CONTRIBUTING.adoc

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,8 +50,9 @@ can be built locally or in the `openshift/origin-release` container environment.
5050
http://golang.org/[Go] programming language is only necessary for building on
5151
the local host.
5252

53-
Currently, OpenShift is built with `go` 1.8 and uses Docker 1.12. The exact
54-
requirement for Docker is documented
53+
Currently, OpenShift is built with `go` 1.9 and uses Docker 1.13 on Fedora/CentOS/RHEL.
54+
MacOS supports builds with `go` 1.9 and Docker CE 17.09.1 - newer versions of go and Docker are not supported.
55+
The exact requirement for Docker is documented
5556
https://docs.openshift.org/latest/install_config/install/prerequisites.html#installing-docker[here].
5657

5758
==== Installing Prerequisites
@@ -65,17 +66,23 @@ $ brew install git
6566
----
6667

6768
Then, follow the instructions to install https://docs.docker.com/docker-for-mac/install/[`docker`].
69+
Search the https://docs.docker.com/docker-for-mac/release-notes/[Docker for Mac releases] to find a link:/docs/cluster_up_down.md#prerequisites[supported
70+
version] to download.
6871
You will need to build `linux/amd64` binaries for the OpenShift server; if you
6972
want to do the builds locally, you will need to follow the instructions to
7073
install https://golang.org/doc/install#install[the `go` programming language].
74+
Go `pkg` installers can be downloaded https://golang.org/dl/[here].
7175

7276
===== Windows
7377

7478
Follow the installation steps to install https://git-for-windows.github.io/[`git` for Windows]
7579
and https://docs.docker.com/docker-for-windows/install/[`docker`].
80+
Search the https://docs.docker.com/docker-for-windows/release-notes/[Docker for Windows releases] to find a link:/docs/cluster_up_down.md#prerequisites[supported
81+
version] to download.
7682
You will need to build `linux/amd64` binaries for the OpenShift server; if you
7783
want to do the builds locally, you will need to follow the instructions to
7884
install https://golang.org/doc/install#windows[the `go` programming language].
85+
Go `msi` installers can be downloaded https://golang.org/dl/[here].
7986

8087
===== Fedora
8188

docs/cluster_up_down.md

Lines changed: 43 additions & 61 deletions
Original file line numberDiff line numberDiff line change
@@ -2,30 +2,39 @@
22

33
- [Overview](#overview)
44
- [Getting Started](#getting-started)
5+
- [Prerequisities](#prerequisites)
56
- [Linux](#linux)
67
- [MacOS with Docker for Mac](#macos-with-docker-for-mac)
7-
- [Mac OS X with Docker Toolbox](#mac-os-x-with-docker-toolbox)
8+
- [Mac OS X with Docker Machine](#mac-os-x-with-docker-machine)
89
- [Windows with Docker for Windows](#windows-with-docker-for-windows)
9-
- [Windows with Docker Toolbox](#windows-with-docker-toolbox)
10+
- [Windows with Docker Machine](#windows-with-docker-machine)
1011
- [Persistent Volumes](#persistent-volumes)
1112
- [Using a Proxy](#using-a-proxy)
1213
- [Installing Metrics](#installing-metrics)
1314
- [Installing Logging Aggregation](#installing-logging-aggregation)
1415
- [Installing the Service Catalog](#installing-the-service-catalog)
1516
- [Administrator Access](#administrator-access)
16-
- [Docker Machine](#docker-machine)
1717
- [Configuration](#configuration)
1818
- [Etcd Data](#etcd-data)
1919
- [Routing](#routing)
2020
- [Specifying Images to Use](#specifying-images-to-use)
2121
- [Accessing the OpenShift Registry Directly](#accessing-the-openshift-registry-directly)
2222

23-
## Pre-requisites
23+
## Prerequisites
2424

2525
| NOTE |
2626
| ---- |
2727
| This command was released with the 1.3+ version of oc client tools, so you must be using version 1.3+ or newer for this command to work. |
2828

29+
To run an OpenShift cluster locally, you must have a compatible version of Docker installed in your environment.
30+
OpenShift officially supports the following versions of Docker:
31+
32+
| OpenShift Version | Docker Version |
33+
| ----------------- | -------------- |
34+
| 3.9 | 1.13 |
35+
| 3.6-3.7 | 1.12 |
36+
| 1.4-1.5 | 1.12 |
37+
| 1.3 | 1.10 |
2938

3039
## Overview
3140

@@ -46,7 +55,7 @@ a URL to access the management console for your cluster.
4655
| The default Firewalld configuration on Fedora blocks access to ports needed by containers running on an OpenShift cluster. Make sure you grant access to these ports. See step 3 below. |
4756
| Check that `sysctl net.ipv4.ip_forward` is set to 1. |
4857

49-
1. Install Docker with your platform's package manager.
58+
1. Install Docker with your platform's package manager. Consult the [compatibility table](#prerequisites) to select a supported version of Docker.
5059
2. Configure the Docker daemon with an insecure registry parameter of `172.30.0.0/16`
5160
- In RHEL and Fedora, edit the `/etc/containers/registries.conf` file and add the following lines:
5261
```
@@ -112,7 +121,12 @@ $ oc cluster down
112121
113122
### MacOS with Docker for Mac
114123
115-
1. Install [Docker for Mac](https://docs.docker.com/docker-for-mac/) making sure you meet the [prerequisites](https://docs.docker.com/docker-for-mac/#/what-to-know-before-you-install).
124+
> `oc cluster up` with Docker for Mac does not work with versions 3.7.1 and earlier.
125+
We recommend using [Mac OS X with Docker Machine](#mac-os-x-with-docker-machine) with these versions of the openshift cli.
126+
See [issue #17570](https://github.com/openshift/origin/issues/17570).
127+
128+
1. Install [Docker for Mac](https://docs.docker.com/docker-for-mac/release-notes/) making sure you meet the [prerequisites](https://docs.docker.com/docker-for-mac/#/what-to-know-before-you-install)
129+
and download a [compatible version of Docker](#prerequisites).
116130
2. Once Docker is running, add an insecure registry of `172.30.0.0/16`:
117131
- From the Docker menu in the toolbar, select `Preferences...`
118132
- Click on `Daemon` in the preferences dialog (note: on some older versions of Docker for Mac this is under `Advanced`)
@@ -133,7 +147,7 @@ $ oc cluster down
133147
Download the Mac OS `oc` binary from [openshift-origin-client-tools-VERSION-mac.zip](https://github.com/openshift/origin/releases) and place it in your path.
134148
135149
> Please be aware that the 'oc cluster' set of commands are only available in the 1.3+ or newer releases.
136-
150+
137151
3. Open Terminal and run
138152
```
139153
$ oc cluster up
@@ -144,38 +158,34 @@ To stop your cluster, run:
144158
$ oc cluster down
145159
```
146160
147-
### Mac OS X with Docker Toolbox
161+
### Mac OS X with Docker Machine
148162
149-
1. Install [Docker Toolbox](https://www.docker.com/products/docker-toolbox) and ensure that it is functional.
150-
2. Install the oc binary using homebrew with: `brew install openshift-cli`
163+
1. Install [Docker for Mac](https://docs.docker.com/docker-for-mac/release-notes/) making sure you meet the [prerequisites](https://docs.docker.com/docker-for-mac/#/what-to-know-before-you-install)
164+
and download a [compatible version of Docker](#prerequisites).
165+
2. Install [VirtualBox for OSX Hosts](https://www.virtualbox.org/wiki/Downloads)
166+
3. Install the oc binary using homebrew with: `brew install openshift-cli`
151167
152168
OR
153169
154170
Download the OS X `oc` binary from [openshift-origin-client-tools-VERSION-mac.zip](https://github.com/openshift/origin/releases) and place it in your path.
155171
156172
> Please be aware that the 'oc cluster' set of commands are only available in the 1.3+ or newer releases.
157173
158-
3. Open Terminal and run
174+
4. Create a new docker machine named `openshift` with appropriate resource constraints. See [Getting Started with Docker Machine](https://docs.docker.com/machine/get-started/#create-a-machine) for instructions.
175+
5. Open Terminal and run
159176
```
160-
$ oc cluster up --create-machine
177+
$ oc cluster up --docker-machine=openshift
161178
```
162179
163-
A Docker machine named `openshift` will be created using the VirtualBox driver and the OpenShift cluster
164-
will be started on it.
180+
OpenShift will start cluster on the docker machine you specified.
165181
166182
To stop the cluster, run:
167183
168184
```
169185
$ oc cluster down --docker-machine=openshift
170186
```
171187
172-
To create a machine with a different name, specify the `--docker-machine` argument with `--create-machine`:
173-
174-
```
175-
$ oc cluster up --create-machine --docker-machine=mymachine
176-
```
177-
178-
Once the machine has been created, the `--create-machine` argument is no longer needed. To start/stop OpenShift again, either:
188+
To start/stop OpenShift again, either:
179189
180190
* Setup the Docker environment for the machine you wish to use, and then run `oc cluster up` and `oc cluster down`:
181191
@@ -202,7 +212,8 @@ Once the machine has been created, the `--create-machine` argument is no longer
202212
203213
### Windows with Docker for Windows
204214
205-
1. Install [Docker for Windows](https://docs.docker.com/docker-for-windows/) making sure you meet the [prerequisites](https://docs.docker.com/docker-for-windows/#/what-to-know-before-you-install).
215+
1. Install [Docker for Windows](https://docs.docker.com/docker-for-windows/relase-notes/) making sure you meet the [prerequisites](https://docs.docker.com/docker-for-windows/#/what-to-know-before-you-install)
216+
and download a [compatible version of Docker](#prerequisites).
206217
2. Once Docker is running, add an insecure registry of `172.30.0.0/16`:
207218
- Right click on the Docker icon in the notification area and select `Settings...`
208219
- Click on `Docker Daemon` in the settings dialog
@@ -229,35 +240,30 @@ To stop the cluster, run:
229240
C:\> oc cluster down
230241
```
231242
232-
### Windows with Docker Toolbox
243+
### Windows with Docker Machine
233244
234-
1. Install [Docker Toolbox](https://www.docker.com/products/docker-toolbox) and ensure that it is functional.
235-
2. Download the Windows `oc.exe` binary from [openshift-origin-client-tools-VERSION-windows.zip](https://github.com/openshift/origin/releases) and place it in your path.
245+
1. Install [Docker for Windows](https://docs.docker.com/docker-for-windows/release-notes/) making sure you meet the [prerequisites](https://docs.docker.com/docker-for-windows/#/what-to-know-before-you-install)
246+
and download a [compatible version of Docker](#prerequisites).
247+
2. Review the [prerequisite instructions](https://docs.docker.com/machine/get-started/#prerequisite-information) to set up Docker Machine on Windows.
248+
3. Download the Windows `oc.exe` binary from [openshift-origin-client-tools-VERSION-windows.zip](https://github.com/openshift/origin/releases) and place it in your path.
236249
237250
> Please be aware that the 'oc cluster' set of commands are only available in the 1.3+ or newer releases.
238-
239-
3. Open a Command window as Administrator (for most drivers, docker-machine on Windows requires administrator privileges)
251+
4. Create a new docker machine named `openshift` with appropriate resource constraints. See [Getting Started with Docker Machine](https://docs.docker.com/machine/get-started/#create-a-machine) for instructions.
252+
5. Open a Command window as Administrator (for most drivers, docker-machine on Windows requires administrator privileges)
240253
and run:
241254
```
242-
C:\> oc cluster up --create-machine
255+
C:\> oc cluster up --docker-machine=openshift
243256
```
244257
245-
A Docker machine named `openshift` will be created using the VirtualBox driver and the OpenShift cluster
246-
will be started on it.
258+
OpenShift will start cluster on the docker machine you specified.
247259
248260
To stop the cluster, run:
249261
250262
```
251263
C:\> oc cluster down --docker-machine=openshift
252264
```
253265
254-
To create a machine with a different name, specify the `--docker-machine` argument with `--create-machine`:
255-
256-
```
257-
C:\> oc cluster up --create-machine --docker-machine=mymachine
258-
```
259-
260-
Once the machine has been created, the `--create-machine` argument is no longer needed. To start/stop OpenShift again, either:
266+
To start/stop OpenShift again, either:
261267
262268
* Setup the Docker environment for the machine you wish to use, and then run `oc cluster up` and `oc cluster down`:
263269
```
@@ -367,30 +373,6 @@ To return to the regular `developer` user, login as that user:
367373
oc login -u developer
368374
```
369375
370-
## Docker Machine
371-
372-
By default, when `--create-machine` is used to create a new Docker machine, the `oc cluster up` command will use the
373-
VirtualBox driver. In order to use a different driver, you must create the Docker machine beforehand
374-
and either specify its name with the `--docker-machine` argument, or set its environment using the `docker-machine env`
375-
command. When creating a Docker machine manually, you must specify the `--engine-insecure-registry` argument with the
376-
value expected by OpenShift.
377-
378-
Following are examples of creating a new Docker machine in OS X using the [xhyve](https://github.com/zchee/docker-machine-driver-xhyve) driver,
379-
and in Windows, using the [hyper-v](https://docs.docker.com/machine/drivers/hyper-v/) driver.
380-
381-
OS X:
382-
```
383-
$ docker-machine create --driver xhyve --engine-insecure-registry 172.30.0.0/16 mymachine
384-
```
385-
386-
Windows (running a command window as Administrator):
387-
```
388-
C:\> docker-machine create --driver hyperv --engine-insecure-registry 172.30.0.0/16 mymachine
389-
```
390-
391-
When the `--docker-machine` argument is specified on `oc cluster up`, the machine's environment does not need to be configured
392-
on the current shell. Also if the machine exists but is not started, `oc cluster up` will attempt to start it.
393-
394376
## Configuration
395377
396378
`oc cluster up` creates its configuration by default in `/var/lib/origin/openshift.local.config` on the Docker host.

0 commit comments

Comments
 (0)