The Startup
Published in

The Startup

How to setup OpenShift Locally on Mac OS

Getting Started with OpenShift Minishift

img source:

The following section describes how to install Minishift and the required dependencies for mac os. This is not for production use, but rather just something to get you started and get familiar with Openshift setup and usage. These are the basic steps for setting up Minishift on your personal system:

1. Install virtual box

Download VirtualBox for Mac OS here and follow this video tutorial on how to install Virtualbox on Mac OS:

2. Set up your virtualization environment

Minishift uses libmachine and its driver plug-in architecture to provide a consistent way to manage the Minishift VM. Some hypervisors require manual installation of the driver plug-in.

Minishift embeds the VirtualBox driver plug-in, so no additional steps are required to configure it. However, VirtualBox will need to be identified to Minishift via the --vm-driver virtualbox flag or persistent configuration settings. See Setting Up Minishift to Use VirtualBox for more information.

Minishift is currently tested against docker-machine-driver-xhyve version 0.3.3. Use the following command to install the latest version of the driver with Homebrew:

$ brew install docker-machine-driver-xhyve

Once installed, enable root access for the docker-machine-driver-xhyve binary and add it to the default wheel group:

$ sudo chown root:wheel $(brew --prefix)/opt/docker-machine-driver-xhyve/bin/docker-machine-driver-xhyve

Set the owner User ID (SUID) for the binary as follows:

$ sudo chmod u+s $(brew --prefix)/opt/docker-machine-driver-xhyve/bin/docker-machine-driver-xhyve
You can also see this command on your terminal. Simpl copy-pastes them — This is a screenshot of mine

3. Install Minishift

On macOS, use Homebrew Cask to install the stable version of Minishift:

$ brew cask install minishift

To update the binary, run following command:

$ brew cask install --force minishift

4. Start Minishift

By default, Minishift uses the driver most relevant to the host OS. To use a different driver, set the --vm-driver flag in minishift start. For example, to use VirtualBox instead of KVM on Linux operating systems, run minishift start --vm-driver=virtualbox.

So, go ahead and run the following command to start Minishit:

$ minishift start --vm-driver=virtualbox

When Minishift is starting you will see it running on your Virtualbox:

Screenshot of my Virtualbox
  • The IP is dynamically generated for each OpenShift cluster. To check the IP, run the minishift ip command.
  • While Minishift starts it runs several checks to make sure that the Minishift VM and the OpenShift cluster are able to start correctly. If any startup checks fail, see the Troubleshooting Getting Started topic for information about possible causes and solutions.
  • Use minishift oc-env to display the command you need to type into your shell in order to add the oc binary to your PATH environment variable. The output of oc-env will differ depending on OS and shell type.
$ minishift oc-env

To access the resources you just created, use the info provided at the end of the minishift start process to log into your web console or using the ofoc login -u system:admincommand:

This is my screenshot after completion of minishit start process

Use this link to access your Openshift web console: The password is not validated since it’s running locally, so you can use any password to log in.

You are all set!!! 🥳😎.

5. Stop Minishift

To stop Minishift, use the following command:

$ minishift stop

Now you can play with it and circle back later when we explore how to deploy a Nodejs application store on GitHub repo using Onpenshift.

If you enjoyed this story, you might also like “How to Set Up the Development Environment





Get smarter at building your thing. Follow to join The Startup’s +8 million monthly readers & +756K followers.

Recommended from Medium

means of setting this config.

Picture this: the best image format for the web in 2019

PromQL / How to return 0 instead of ‘no data’

Importance of Mobile Compatibility Testing

BeamX: How to set up your Beam Wallet.

Creating a REST API to calculate BMR with Ruby on Rails

Getting started with Django and Bootstrap

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Yann Mulonda

Yann Mulonda

Chief Information Officer @ITOT Africa | Lead Senior Site Reliability Engineer @ICF󠁧󠁢󠁳󠁣󠁴 | "Learning is experience; everything else is just information!”

More from Medium

How to Write Serverless NodeJS Azure Functions With PostgreSQL Database — Typescript Version

Create and Run AWS ECS Task programmatically using .NET 5, C# & AWS ECS SDK

BATS (Bash Automated Testing System)

Setup Docker Container as Test environment in Local Development using shell script