Detailed steps for quick installation of openshift

Detailed steps for quick installation of openshift

The fastest way to experience the latest version of OpenShift 3.9.

Preparation

[root@host ~]# git clone http://github.com/liumiaocn/easypack.git
Cloning into 'easypack'...
remote: Counting objects: 1050, done.
remote: Compressing objects: 100% (59/59), done.
remote: Total 1050 (delta 29), reused 6 (delta 3), pack-reused 985
Receiving objects: 100% (1050/1050), 157.41 KiB | 0 bytes/s, done.
Resolving deltas: 100% (464/464), done.
[root@host ~]# cd easypack/openshift/
[root@host openshift]# ls
install-openshift.sh
[root@host openshift]#

Install

Installation command: sh install-openshift.sh

[root@host openshift]# sh install-openshift.sh 
Sun May 6 09:16:16 EDT 2018
## Step 1: OS version confirm: 
Linux host.localdomain 3.10.0-514.el7.x86_64 #1 SMP Tue Nov 22 16:42:41 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
CentOS Linux release 7.3.1611 (Core) 
## Install docker 
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * base: mirror.it.ubc.ca
 * extras: mirror.it.ubc.ca
 * updates: mirror.csclub.uwaterloo.ca
...install docker
Sun May 6 09:16:16 EDT 2018
## Step 2: Set net.ipv4.ip_forward
net.ipv4.ip_forward=1
net.ipv4.ip_forward=1
sysctl net.ipv4.ip_forward
net.ipv4.ip_forward = 1
Sun May 6 09:16:17 EDT 2018
## Step 3: Set registry & Restart docker
{
  "insecure-registries": [
   "172.30.0.0/16"
  ]
}
## systemctl daemon-reload
## systemctl restart docker
## confirm docker version
Client:
 Version: 1.13.1
 API version: 1.26
 Package version: <unknown>
 Go version: go1.8.3
 Git commit: 774336d/1.13.1
 Built: Wed Mar 7 17:06:16 2018
 OS/Arch: linux/amd64
Server:
 Version: 1.13.1
 API version: 1.26 (minimum version 1.12)
 Package version: <unknown>
 Go version: go1.8.3
 Git commit: 774336d/1.13.1
 Built: Wed Mar 7 17:06:16 2018
 OS/Arch: linux/amd64
 Experimental: false
Sun May 6 09:16:20 EDT 2018
## Step 4: Set for firewall
...Set firewall portsSun May 6 09:16:21 EDT 2018
## Step 5: get and set oc: 
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * base: mirror.it.ubc.ca
 * extras: mirror.it.ubc.ca
 * updates: mirror.csclub.uwaterloo.ca
Package wget-1.14-15.el7_4.1.x86_64 already installed and latest version
Nothing to do
--2018-05-06 09:16:22-- 
...Download oc client tools 2018-05-06 09:16:40 (2.45 MB/s) - ‘openshift-origin-client-tools-v3.9.0-191fece-linux-64bit.tar.gz’ saved [44156681/44156681]
...omit /usr/local/bin/oc
oc v3.9.0+191fece
Kubernetes v1.9.1+a0ce1bc657
features: Basic-Auth GSSAPI Kerberos SPNEGO
Sun May 6 09:16:42 EDT 2018
## Step 6: start up oc cluster
Pulling image openshift/origin:v3.9.0
Pulled 1/4 layers, 31% complete
Pulled 2/4 layers, 63% complete
Pulled 3/4 layers, 75% complete
Pulled 3/4 layers, 80% complete
Pulled 3/4 layers, 86% complete
Pulled 3/4 layers, 91% complete
Pulled 3/4 layers, 95% complete
Pulled 3/4 layers, 99% complete
Pulled 4/4 layers, 100% complete
Extracting
Image pull complete
Using nsenter mounter for OpenShift volumes
Using 127.0.0.1 as the server IP
Starting OpenShift using openshift/origin:v3.9.0 ...
OpenShift server started.
The server is accessible via web console at:
  https://127.0.0.1:8443
You are logged in as:
  User: developer
  Password: <any value>
To login as administrator:
  oc login -u system:admin
Sun May 6 09:20:37 EDT 2018
REPOSITORY TAG IMAGE ID CREATED SIZE
docker.io/openshift/origin-web-console v3.9.0 6d397283b924 6 days ago 489 MB
docker.io/openshift/origin-deployer v3.9.0 2dcb16bd17a4 6 days ago 1.25 GB
docker.io/openshift/origin v3.9.0 e28708220c0b 6 days ago 1.25 GB
docker.io/openshift/origin-pod v3.9.0 b549aa96e0a7 6 days ago 220 MB
docker.io/capitalone/hygieia-api latest 8e7b476005b9 15 months ago 684 MB
Sun May 6 09:20:38 EDT 2018
## Step 7: oc login -u developer
Logged into "https://127.0.0.1:8443" as "developer" using existing credentials.
You have one project on this server: "myproject"
Using project "myproject".
## Finished.
[root@host openshift]#

Result Confirmation

Related images

[root@host openshift]# docker images |grep openshift
docker.io/openshift/origin-web-console v3.9.0 6d397283b924 6 days ago 489 MB
docker.io/openshift/origin-docker-registry v3.9.0 45f47bc77de8 6 days ago 458 MB
docker.io/openshift/origin-haproxy-router v3.9.0 42e8fd168a7a 6 days ago 1.28 GB
docker.io/openshift/origin-deployer v3.9.0 2dcb16bd17a4 6 days ago 1.25 GB
docker.io/openshift/origin v3.9.0 e28708220c0b 6 days ago 1.25 GB
docker.io/openshift/origin-pod v3.9.0 b549aa96e0a7 6 days ago 220 MB
[root@host openshift]#

Verify Administrator Rights

[root@host openshift]# oc login -u system:admin
Logged into "https://127.0.0.1:8443" as "system:admin" using existing credentials.
You have access to the following projects and can switch between them with 'oc project <projectname>':
  default
  kube-public
  kube-system
 * myproject
  OpenShift
  openshift-infra
  openshift-node
  openshift-web-console
Using project "myproject".
[root@host openshift]#

Local connection method

ssh -p 10023 -L 80:127.0.0.1:80 127.0.0.1
ssh -p 10023 -L 8443:127.0.0.1:8443 127.0.0.1
https://127.0.0.1:8443

Summarize

The above is the full content of this article. I hope that the content of this article will have certain reference learning value for your study or work. Thank you for your support of 123WORDPRESS.COM. If you want to learn more about this, please check out the following links

You may also be interested in:
  • Docker uses busybox to create a base image
  • Docker's health detection mechanism
  • Architecture and component description of docker private library Harbor
  • Methods and steps for Etcd distributed deployment based on Docker
  • Docker-compose one-click deployment of gitlab Chinese version method steps
  • Sample code for deploying Spring-boot project with Docker
  • How to modify the default network segment of Docker0 bridge in Docker
  • Docker container deployment attempt - multi-container communication (node+mongoDB+nginx)
  • Can Docker become the next "Linux"?
  • How to deploy gitlab using Docker-compose

<<:  Detailed example of removing duplicate data in MySQL

>>:  WeChat applet custom scroll-view example code

Recommend

Binary Search Tree Algorithm Tutorial for JavaScript Beginners

Table of contents What is a Binary Search Tree (B...

Use of Linux network configuration tools

This article introduces RHEL8 network services an...

Notes on using the blockquote tag

<br />Semanticization cannot be explained in...

Detailed explanation of the knowledge points of using TEXT/BLOB types in MySQL

1. The difference between TEXT and BLOB The only ...

MySQL configuration SSL master-slave replication

MySQL5.6 How to create SSL files Official documen...

Detailed explanation and examples of database account password encryption

Detailed explanation and examples of database acc...

Detailed introduction to MySQL database index

Table of contents Mind Map Simple understanding E...

How to remotely log in to the MySql database?

Introduction: Sometimes, in order to develop a pr...

Comparison of the efficiency of different methods of deleting files in Linux

Test the efficiency of deleting a large number of...

MySQL 8.0 WITH query details

Table of contents Learning about WITH queries in ...

Specific use of the autoindex module in the Nginx Http module series

The main function of the brower module is to dete...

Solution to JS out-of-precision number problem

The most understandable explanation of the accura...

4 ways to implement routing transition effects in Vue

Vue router transitions are a quick and easy way t...