Run Everything In Docker Containers (On Your Mac)

Ido Green - Sep 5 '19 - - Dev Community

If you wish to see the power of docker on your Mac as a way to run all (or many) of your daily apps check thisgreat post by Jess.

However, when you are going to the repo with all the Dockerfiles it’s clear that it was meant to be used on Linux. However, here is a short path to run all of these powerful apps on Mac as well.


# Install socat 
brew install socat 

# Install xQuartz as our X11 server 
brew cask install xquartz 

# Run it 
socat TCP-LISTEN:6000,reuseaddr,fork UNIX-CLIENT:\"$DISPLAY\" # 

# In a new terminal 
# open -a XQuartz 

# Let's test it by running Firefox in Docker 

docker run -it -v /tmp/.X11-unix:/tmp/.X11-unix -e DISPLAY=docker.for.mac.host.internal:0 jess/firefox

Enter fullscreen mode Exit fullscreen mode

Easy, no?

If you curious to see what I saved you from?

Check this thread on the topic.

Have fun and productive times.

Packages are great not only for software

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .