Quick and Simplified Red Hat Openshift Cluster 4.3 Install on AWS
Openshift Kubernetes Engine, its just rename of Openshift Container Platform as of 27 April 2020, Red Hat has decided for better communicate based on the value the product offering delivers.
No change on install or download, we can install Openshift Kubernetes Engine the same way as Openshift Container Platform as both are them same binary distribution.
Openshift Kubernetes Engine has designed to use for enterprise-ready Kubernetes environment and by the way it is easy to install on Cloud, On-Premise or Laptop.
Openshift Kubernetes Engine comes with different installation types for different platforms like AWS, Azure, Bare-metal and Vmware. In this post I have simplified the process of bootstrapping your first Openshift Container Platform 4.3 cluster on AWS Infrastructure from scratch.
Openshift Container Platform 4.3 uses ignition-based deployment, Yes, its a new approach defined on version 4.2 to getting your Kubernetes cluster operational which gives us the fully-automated experience with just 1 command, that deploy a complete Openshift 4 cluster.
This Quick Start Post sets up a AWS cloud Infrastructure and deploys Red Hat Openshift Container Platform 4.3 on AWS cloud.
Am writing this article for someone setting out to install an Openshift Container Platform 4.3 cluster, could assume this documentation will help you.
Let’s start!!!, The deployment process includes these steps:
Step 1: Accounts Sign Up
If you don’t already have an AWS account and Red Hat account, create it first.
Sign up for a Red Hat subscription https://www.redhat.com/wapps/ugc/register.html
Sign Up AWS account https://aws.amazon.com
Step 2: Configuring your Amazon Web Services (AWS) account
Step 2.1: Configuring Route53
To install Openshift Container Platform, we must need a dedicated public hosted zone in your Route53 service, this provides cluster DNS resolution and name lookup for external connections to the cluster.
Step 2.2: AWS account limits
since the Openshift Container Platform cluster uses a number of Amazon Web Services (AWS) components, ensure have enough services limits like VPC, EIP etc.
Step 2.3. Creating an IAM user
Each Amazon Web Services (AWS) account contains a root user account that is based on the email address you used to create the account.
Other than default, Here we created new IAM user name ‘ospuser’ with Programmatic access and attached the AdministratorAccess AWS managed policy. (Download the Access and Secret Key)
Step 3: Setup Jump server or Local Machine (Linux)
This Jump server mine on AWS EC2 machine with Red hat AMI which act as management server will help to perform AWS CLI and Openshift installer and CLI tasks.
Step 3.1: Install the AWS CLI version 1 on Linux
Link: https://aws.amazon.com/cli/
$ sudo yum install python3 -y
$ sudo python get-pip.py --user
$ sudo cp -rf .local/bin/* /usr/local/bin/
$ sudo pip3 install awscli upgrade --user
$ sudo cp .local/bin/aws /usr/local/bin/ ; chmod +x /usr/local/bin/aws
$ sudo aws --version
Step 3.2: Generating an SSH private key and adding it to the agent
$ sudo ssh-keygen -t rsa -b 4096 -N ‘’ -f ~/.ssh/id_rsa
$ sudo eval “$(ssh-agent -s)”
$ sudo ssh-add ~/.ssh/id_rsa
Step 3.3 AWS Configure
Configure the AWS CLI tool with IAM user name ‘ospuser’ account ID with Access and Secret Key (created and downloaded on Step 2.3).
$ sudo aws configure
AWS Access Key ID [None]: AKIAV62DSXXXXXXX
AWS Secret Access Key [None]: AcpxFM2YVJ0XXXXXXXXX
Default region name [None]: us-east-2
Default output format [None]: json
Step 4: Download Openshift installer and client CLI binaries and add them to your PATH
Next, Obtaining the installation program https://cloud.redhat.com/openshift/install, download and extract the install program on Jump server or Local machine in the root directory of user.
Step 4.1: Download Openshift installer
$ sudo curl -O https://mirror.openshift.com/pub/openshift-v4/clients/ocp/latest/openshift-install-linux.tar.gz
$ sudo tar -xvzf openshift-install-linux.tar.gz
$ sudo cp -rf openshift-install /usr/local/bin/openshift-install ; chmod +x /usr/local/bin/openshift-install
Step 4.2: Pull secret
Download or copy pull secret from https://cloud.redhat.com/openshift/install . The install program will prompt you for your pull secret during installation.
Step 4.3: Download Command-line interface
Download the Openshift command-line tools to manage cluster after installed.
$ sudo curl -O https://mirror.openshift.com/pub/openshift-v4/clients/ocp/latest/openshift-client-linux.tar.gz
$ sudo tar -xvzf openshift-client-linux.tar.gz
$ sudo cp -rf oc /usr/local/bin/oc ; chmod +x /usr/local/bin/oc ; cp -rf kubectl /usr/local/bin/kubectl; chmod +x /usr/local/bin/kubectl
Step: 4 Deploy the Openshift cluster 4.3
Great, Now our environment ready for Openshift cluster installation on AWS Cloud Infrastructure.
It will be quick and simplified process, openshift-install CLI initially create a Bootstrap EC2 instance which deploy 3 Master and 3 Worker nodes instances. Once process completed Bootstrap instance will terminate automatically.
Step 4.1: Create a directory to store installation files
$sudo mkdir ./oscdir
Step 4.2: Create Cluster
$ sudo openshift-install create cluster --dir=./oscdir
The Pull Secret is one of the values we need to specify during the installation process. Obtain from installation program page https://cloud.redhat.com/openshift/install
That’s it, only 1 command :), Deployment will complete in approximately 30 to 60 mins.
Step 5: Access your cluster
You are now ready to access your Openshift Cluster 4.3 through the browser (or command-line interface).
For Command-line cluster access, you can log into your cluster as a default system user by exporting the cluster kubeconfig file:
export KUBECONFIG=<installation_directory>/auth/kubeconfig
Access your cluster through browser by using web-console link got after the installation with default username and password on install completion screen.
Step 6: Destroy Openshift cluster
$ sudo openshift-install destroy cluster --dir=./oscdir -- log-level=info