Skip to main content

Deploy Openshift on MacOS.


OpenShift / Minishift v3.6 setup on MacOS.
The minishift installation is very well documented here but still misses on few steps for Mac OS user’s and hence thought of providing step-by-step install to ensure a consistent setup of OpenShift on Mac OS for demo purpose.
——————————  
OpenShift v3 brings many architectural changes and introduces new concepts and components. It is built around the applications running in Docker containers, scheduling and management support provided by the Kubernetes project, and augmented deployment, orchestration, and routing functionality on top.

OpenShift v3 is a layered system designed to expose underlying Docker-formatted container image and Kubernetes concepts as accurately as possible, with a focus on easy composition of applications by a developer.

Prerequisites for minishift install :
Minishift requires a hypervisor to start the virtual machine on which the OpenShift cluster is provisioned. Verify that the hypervisor of your choice is installed and enabled on your system before you start Minishift.
·       Xcode to be updated to latest version from the App Store
·       Install Homebrew on your Mac.
·       xhyve (default)
xhyve requires specific installation and configuration steps that are described in the Setting Up the Driver Plug-in section.
·       VirtualBox
Detailed steps for minishift install :
Install homebrew for Mac :
 $  /usr/bin/ruby -e "  $  (curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
Error: /usr/local/Cellar is not writable. You should change the
ownership and permissions of /usr/local/Cellar back to your
user account:
  sudo chown -R   $  (whoami) /usr/local/Cellar
Failed during: /usr/local/bin/brew update --force
 $  sudo chown -R   $  (whoami) /usr/local/Cellar
 $  /usr/bin/ruby -e "  $  (curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
Already up-to-date.
Error: Failed to link all completions, docs and manpages:
  Permission denied @ rb_file_s_symlink - (../../../Homebrew/completions/zsh/_brew, /usr/local/share/zsh/site-functions/_brew)
Failed during: /usr/local/bin/brew update --force
Install minishift 
 $  brew cask install minishift
==> Installing Cask minishift
==> Linking Binary 'minishift' to '/usr/local/bin/minishift'.
๐Ÿบ  minishift was successfully installed!
Install xhyve :
 $  brew install --HEAD xhyve
Updating Homebrew...
Error: Your Xcode (6.4) is too outdated.
Please update to Xcode 8.3.3 (or delete it).
Xcode can be updated from the App Store.
 $  brew install --HEAD xhyve
Updating Homebrew...
:
:
Post installation of XCode (or update of the same) to latest version, you need to accept the license.
 $  brew install --HEAD xhyve
Error: You have not agreed to the Xcode license. Please resolve this by running:
  sudo xcodebuild -license accept
 $  sudo xcodebuild -license accept
Password:
Following command will fail due to ownership setup :
 $  brew install docker-machine-driver-xhyve
Set proper ownership :
 $  sudo chown -R `whoami`:admin /usr/local/bin
 $  sudo chown -R `whoami`:admin /usr/local/share
 $  sudo chown -R `whoami`:admin /usr/local/opt
 $  brew link xhyve
Linking /usr/local/Cellar/xhyve/HEAD-1f1dbe3... 3 symlinks created
Rerun again :
 $  brew install docker-machine-driver-xhyve
Warning: docker-machine-driver-xhyve 0.3.3 is already installed, it's just not linked.
You can use `brew link docker-machine-driver-xhyve` to link this version.
 $  brew link docker-machine-driver-xhyve
Linking /usr/local/Cellar/docker-machine-driver-xhyve/0.3.3... 1 symlinks created
   $  which docker-machine-driver-xhyve 
/usr/local/bin/docker-machine-driver-xhyve
   $  sudo chown root:wheel /usr/local/bin/docker-machine-driver-xhyve
Password:
   $  sudo chmod u+s,+x /usr/local/bin/docker-machine-driver-xhyve
On macOS you can also use Homebrew Cask to install the stable version of Minishift:
    $   brew cask install minishift
Start Minishift
$  minishift start
The server is accessible via web console at:
    https://192.168.64.2:8443
You are logged in as:
    User:     developer
    Password: <any value>

To login as administrator:
    oc login -u system:admin
   $  minishift oc-env
export PATH="/Users/user1/.minishift/cache/oc/v3.6.0:  $  PATH"
# Run this command to configure your shell:
# eval   $  (minishift oc-env)

   $  export PATH="/Users/user1/.minishift/cache/oc/v3.6.0:  $  PATH"
  $   eval   $  (minishift oc-env)

That’s it, now you have Openshift/Minishift running on your Mac OS for demo!!!

Enjoy OpenShifting…

This is what you see on your Chrome Browser post OpenShift/minishift install. For Safari, you need to ensure that you are able to accept certificate to proceed access to this site.




I was going through "OpenShift for Developer's" by Brant Shipley and Graham Dumpleton (O'REILLY) and it seems that the OpenShift appliance installation procedure is not changed to reflect minishift install. Its no longer a OpenShift VM image but has moved to minishift and hence I have document the install procedure here in this blog.

Last week at OpenStack Summit Sydney, Red Hat were distributing "OpenShift for Developer's" by Brant Shipley and Graham Dumpleton (O'REILLY) to all those who visited their booth. It was good to see lot of discussion around Kubernetes and OpenStack integration with Red Hat at the centre stage.

Comments

  1. Hi Ritesh,

    One quick suggestion. Please replace all occurrences of `Openshift` with `OpenShift`.

    ReplyDelete
    Replies
    1. Thanks, have updated the one's where it needed.

      Delete

Post a Comment

Popular posts from this blog

Ceph Storage driving throughput for Analytics (Focused on Telco Industry).

เคจ เคฎ เคธ्เค•ा เคฐ  Many in Cloud industry have heard about Ceph Storage as the storage backend for Openstack environment. Its also getting popular as an Object Storage (due to its underlying RADOS structure). Many reference whitepaper's are avaialble to understand architecture and performance what it can deliver in various configurations. Today's focus is on a different aspect of Ceph Storage being used as standalone block storage for Telco Network Analytics. Following are a couple of use cases for reference. 1) RBD Block Storage for Linux based App Server's  (standalone/bare metal  Linux server's or VM's) Some Telco ISV's running Unified Performance Management to monitor and analyze the telco network performance needs to store and analyze lot of data. Hence they need distributed storage as a backend connected to multiple APP Server's for the high throughput / IOPS requirements. Figure 1 below gives an architectural view of providing RBD devices as dis...