This page details how to install OpenShift Origin 1.5, in an Ubuntu 16.04 64-bit server, following the "Method 2: Downloading the Binary" described at:
https://docs.openshift.org/latest/getting_started/administrators.html#getting-started-administrators
Host preparation reference > https://docs.openshift.org/latest/install_config/install/host_preparation.html#install-config-install-host-preparation
If not yet installed, install 'apt-transport-https' and 'wget':
sudo apt-get install apt-transport-https
sudo apt-get install wget
If not yet installed install docker deamon. REference > https://www.digitalocean.com/community/tutorials/how-to-install-and-use-docker-on-ubuntu-16-04
sudo apt-get update
sudo apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D
sudo apt-add-repository 'deb https://apt.dockerproject.org/repo ubuntu-xenial main'
sudo apt-get update
sudo apt-cache policy docker-engine
sudo apt-get install -y docker-engine
# check that docker is running
sudo systemctl status docker
# optional, add user to the docker group to avoid having to prepend docker commands with sudo
sudo usermod -aG docker $(whoami)
Docker must be able to pull images from the host system
Reference > https://docs.docker.com/registry/insecure/#deploying-a-plain-http-registry
Ensure you set the --insecure-registry flag
sudo vi /etc/default/docker
# modify or add the DOCKER_OPTS line with the --insecure-registry flag
#DOCKER_OPTS="--insecure-registry
172.30.0.0/16"
DOCKER_OPTS="--insecure-registry
172.30.155.30:5000"
The previous setting didn't work, "/etc/docker/daemon.json" is the platform-independent configuration.
Reference> http://stackoverflow.com/questions/38695515/can-not-pull-push-images-after-update-docker-to-1-12
Create or modify /etc/docker/daemon.json
on the client machine
{ "insecure-registries":["172.30.155.30:5000"] }
Restart docker daemon
sudo /etc/init.d/docker restart
cd /opt
sudo wget https://github.com/openshift/origin/releases/download/v1.5.0/openshift-origin-server-v1.5.0-031cbe4-linux-64bit.tar.gz
sudo tar -xvzf openshift-origin-server-v1.5.0-031cbe4-linux-64bit.tar.gz
sudo rm openshift-origin-server-v1.5.0-031cbe4-linux-64bit.tar.gz
cd openshift-origin-server-v1.5.0-031cbe4-linux-64bit
export PATH="$(pwd)":$PATH
sudo ./openshift start
You must point oc
and curl
at the appropriate CA bundle and client key and certificate to connect to OpenShift Origin. Set the following environment variables:
$ export KUBECONFIG="$(pwd)"/openshift.local.config/master/admin.kubeconfig $ export CURL_CA_BUNDLE="$(pwd)"/openshift.local.config/master/ca.crt $ sudo chmod +r "$(pwd)"/openshift.local.config/master/admin.kubeconfig
This is just for example purposes; in a production environment, developers would generate their own keys and not have access to the system keys.
Now that you have OpenShift Origin successfully running in your environment, try it out by walking through a sample application lifecycle.