Installing OpenShift command line interface (CLI)
Procedure
- Create a directory on the bastion server.In the following example, /ocp-tools is the new directory created.
mkdir /ocp-tools
- Download the OpenShift® Container Platform client and
installation utilities specific for your bastion operating system.
- Version 3.3.x
wget https://mirror.openshift.com/pub/openshift-v4/clients/ocp/stable-4.6/openshift-client-linux.tar.gz -P /ocp-tools
wget https://mirror.openshift.com/pub/openshift-v4/clients/ocp/stable-4.6/openshift-install-linux.tar.gz -P /ocp-tools
- Version 3.4.x and later
wget https://mirror.openshift.com/pub/openshift-v4/clients/ocp/4.14.15/openshift-client-linux.tar.gz -P /ocp-tools
wget https://mirror.openshift.com/pub/openshift-v4/clients/ocp/4.14.15/openshift-install-linux.tar.gz -P /ocp-tools
- Version 3.3.x
- Issue the following commands.
ls -la /ocp-tools cd /ocp-tools chmod 777 * tar xvf openshift-install-linux.tar.gz openshift-install tar xvf openshift-client-linux.tar.gz oc kubectl cp oc kubectl /usr/local/bin oc version kubectl version /ocp-tools/openshift-install version