Docker El Capitan

This is a short guide explaining how to run GUI applications from within Docker on Mac. This uses XQuartz to enable to set the DISPLAY variable within the container.

El Capitan Desktop Support El Capitan Desktop Guides Yosemite Desktop Support. You probably will have to use the legacy Docker Toolbox solution. Docker fails to start on Mac (El Capitan) #899. Snoopdave opened this issue on Nov 5, 2016 2 comments. Lifecycle/locked osx/10.11.x status/0-triage version/1.12.1. Djs55 added osx/10.11.x status/0-triage version/1.12.1 labels on Nov 7, 2016. Djs55 closed this on Nov 8, 2016. Get menu, photos and location information for El Capitan in Miami, FL. Or book now at one of our other 6823 great restaurants in Miami. No Comments on Fix Docker not using /etc/hosts on MacOS On my MacBook with Mac OS X 10.11 (El Capitan) and Docker 1.12.0, Docker did not read manually set DNS entries from the /etc/hosts file. Continue reading “Fix Docker not using /etc/hosts on MacOS”.

Install XQuartz

Install docker el capitan

You can install XQuartz using homebrew with brew cask install xquartz or directly from the website here. At the time of writing, I had 2.7.11 installed on my machine with OSX El Capitan. After installing XQuartz restart your machine.

Install Docker for Mac

Install docker using brew cask install docker or directly from the website here.

Run XQuartz

Start XQuartz from command line using open -a XQuartz. In the XQuartz preferences, go to the “Security” tab and make sure you’ve got “Allow connections from network clients” ticked:

Docker Mac El Capitan

Host Machine IP

Docker Os X El Capitan

IP=$(ifconfig en0 | grep inet | awk '$1'inet' {print $2}') should set the IP variable as the ip of your local machine. If you’re on wifi you may want to use en1 instead of en0, check the value of the variable using echo $IP.

Docker el capitan download

Now add the IP using Xhost with xhost + $IP. If the xhost command is not found check /usr/X11/bin/xhost as that might not be in your path.

Docker El CapitanCapitan

Running a container

You can now try running firefox in your container with:

or run octave using:

Docker

Docker El Capitan Software

When I'm initializing VPN connection via Cisco AnyConnect client, I'm loosing connection to docker daemon. My guess (backed by some googling) is that this has something to do with with routing rewritten by AnyConnect.

The question is – how this can be circumvented?
I've tried to launch and re-launch docker daemon after VPN connection established but this naïve attempt just predictably failed.

Then I've googled a bunch of proposed quite kludgy solutions, for instance, this guy suggests to forward ports and then just always use docker --tlsverify=false – I don't want to do this.

Other thing I've tried to do is to use solution mentioned here:

Docker El Capitan Download

This does not work for me as well.

So I'm looking for canonical solution which can be beneficial for other docker users as well.

Docker Mac Os El Capitan

My docker version is 1.11.2, OS is OS X El Capitan (10.11.6).