Build Kubernetes on Mac OS X (Tech Tip #70)

kubernetes on macKey Concepts of Kubernetes explained the basic fundamentals of Kubernetes. Binary distributions of Kubernetes on Linux can be downloaded from Continuous Integration builds. But it needs to manually built on other platforms, for example Mac. Building Kubernetes on Mac is straightforward as long as you know the steps.

This Tech Tip explains how to build Kubernetes on Mac.

Lets get started!

  1. Kubernetes is written using Go programming language. So you’ll need to download the tools/compilers to build Kubernetes.Install Go ( For example Go 1.4 package for 64-bit Mac OS X can be downloaded from
  2. Configure Go. GOROOT is directory of Go installation is done and contains compiler/tools. GOPATH is directory for your Go projects / 3rd party libraries (downloaded with “go get”).Setup environment variables GOPATH and GOROOT. For example, on my environment they are:
    Make sure $GOROOT/bin is in $PATH.
  3. Install Gnutar:
    Without this, the following message will be shown:
  4. Tech Tip #39 shows how to get stared with Docker on Mac using boot2docker. Download boot2docker for Mac from and install.
  5. Git clone Kubernetes repo:
  6. Build it. This needs to be done from within the boot2docker VM.


Subsequent blogs will show how to run a Kubernetes cluster of WildFly containers. WildFly will have a Java EE 7 application deployed and persist data to MySQL containers.

Be Sociable, Share!
  • Tweet

3 thoughts on “Build Kubernetes on Mac OS X (Tech Tip #70)

  1. Pingback: Java EE 7 and WildFly on Kubernetes using Vagrant - Java吧
  2. Hi Arun,

    it builds in the OSX bash too if you’ve properly set up boot2docker so the build process can start the golang container in the boot2docker VM.

Leave a Reply

Your email address will not be published. Required fields are marked *