Installing the OpenShift CLI Command Line Interface

OpenShift ships with a feature rich web console as well as command line tools to provide users with a nice interface to work with applications deployed to the platform. The OpenShift tools are a single executable written in the Go programming language and is available for the following operating systems:

  • Microsoft Windows

  • Apple OS X

  • Linux

Downloading the tools

During this lab, we are going to download the client tool and add them to our operating system $PATH environment variables so the executable is accessible from any directory on the command line.

The first thing we want to do is download the correct executable for your operating system from link.

Extracting the tools

For Linux, open up a terminal window and change to the directory where you downloaded the file. Once you are in the directory, enter in the following command:

tar zxvf oc-linux.tar.gz

Adding oc to your PATH

$ export PATH=$PATH:~/OpenShift


At this point, we should have the oc tool available for use. Let’s test this out by printing the version of the oc command:

oc version

You should see the following (or something similar):

oc v1.5.0
kubernetes v1.5.2+43a9be4

results matching ""

    No results matching ""