Docker | Kubernetes | Cloud

Recently I purchased a brand new slim 13.3 inch Apple Mac Book Air with an amazing 1.6GHz dual-core Intel Core i5 processor. Introducing Siri to newly re-branded macOS for the first time along with dozens of new features, it came by default running macOS 10.12.1 Sierra. macOS Sierra is the 13th major release of macOS(previously OS X)and successor of OS X El Capiton. ICYMI – Apple released macOS 10.12 Sierra open source Darwin code last November and can be accessed via https://opensource.apple.com/release/os-x-1012.html . One of the first thing I wanted to try out was to see how easy is it to bring Docker 1.13.0 up and running on this system. Trust me, it was an amazing experience. Under this blog post, I am going to share my experience with Docker 1.13.0 and what you really need to know about Docker for Mac on macOS Sierra.

In case you are too new to Docker For Mac…

Last year during March time frame, Docker announced and released a native beta support for Mac and Windows, rightly termed as “Docker for Mac” & “Docker for Windows” respectively. They started with a closed beta & provided access to a couple of early adopters. During Dockercon 2016, they announced Final GA release for both the platforms.

Docker for Mac Vs. Docker Toolbox

Pre-Requisite:

Docker for Mac only works on OS X 10.11 or newer macOS release.

Apple Mac must be running 2010 or newer Mac system, with Intel HW support for MMU Virtualization.

Docker for Mac require atleast 4GB of RAM to function smoothly.

Currently the installer comes in the form of 2 channels – stable and Beta. Under the stable channel, the installer is fully tested and comes with the latest GA version of Docker Engine. The Experimental feature is enabled by default.Under Beta channel, the installer provides the latest beta release of Docker for Mac with experimental features enabled by default.

Features enablement under Docker 1.13.0:

Getting Started with Docker Engine 1.13.0 on macOS Sierra

Installing Docker for Mac is one of fantastic experience I ever had installing any software. Just 3 simple steps:

Download Docker for Mac by clicking on this link and double-click Docker.dmg which opens up the installer.

Drag Moby the whale to the Application Folder as shown below:

3. Authorize Docker.app with your system password and double-click Docker.app to get started as shown below:

Now this is really amazing. Docker for Mac comes with the default availability of docker-compose, docker-machine and experimental feature by default as shown below:

Kudos to Docker Engineers, the whale in the status bar is all you need to have a glimpse of overall Docker daemon running and easy way to configure Docker preferences & environment as per your need:

Open the terminal and you can see that Docker for Mac runs on top of Alpine Linux v3.5, default storage driver as overlay2, Plugins support and many more.

Multi-CPU Architecture Support(ARM, AARCH64 & PPC64le):

Apple Inc. added support for an ARM chip to the latest macOS Sierra 10.12 kernel. At the right time, Docker for Mac made binfmt_misc multi architecture support available,which means that now you can run containers for different Linux architectures, such as arm, aarch64 ppc64le and even s390x.

I couldn’t wait to test-drive few of Raspberry Pi ARM-based Docker images on my Mac Book Air. Here is how I tested few of ARM -based images:

Please Note – The containers need to have the appropriate qemu binary inside the container to work, without qemu you can pull ARM-based Docker images but can’t run it.

Filesystem Sharing with OSXFS:

Docker for Mac brings a new shared filesystem, rightly called OSXFS solution . OSXFS provides a close-to-native user experience for bind mounting OS X file system trees into Docker containers. It brings a number of unique capabilities as well as differences from a classical Linux file system. It does not use OSXFUSE and doesn’t run under, inside, or between OS X user space processes and the OS X kernel.