Docker on Raspberry Pi

Categories Docker, Raspberry Pi

Running docker on the raspberry pi is a fun process.  Before I begin i should thank the Hypriot blog for making it possible and providing a great set of tutorials and guides. I own 2 Raspberry Pi’s (2 & 3) both running debian 8.0 jessie.
The instructions required to install docker on the RPi are pretty straight forward.

sudo apt-get install -y apt-transport-https 
wget -q -O - | sudo apt-key add - 
echo 'deb wheezy main' | sudo tee /etc/apt/sources.list.d/hypriot.list 
sudo apt-get update 
sudo apt-get install -y docker-hypriot 
sudo systemctl enable docker 

Do note that you need to be root to run docker commands so i suggest

sudo su

To switch to root. The first thing I recommend doing is installing the Docker-UI container built specifically for the Raspberry Pi.
Do note since the Raspberry Pi is an ARM device the amount of supported containers are limited. If anywhere down the dependency chain of the container we come across a library that doesn’t support the ARM architecture the container cannot build/run. Which I find to be the major pain point in running docker on the Raspberry Pi. To install the Docker-UI rpi container we do the following.

 docker pull hypriot/rpi-dockerui:latest 
#Pulls the latest image of the container. 
docker run -d -p 9000:9000 -v /var/run/docker.sock:/var/run/docker.sock hypriot/rpi-dockerui 
#This means run the container in detached mode (-d)
 expose port (-p) 9000 on host as 9000 in container (host port:container port),
mount (-v) the local docker engine socket onto the container socket.

After which if you go to

http://`raspberry pi IP`:9000/
Docker UI on RPI2
Here’s whats running on my Raspberry Pi 2

you should be greeted with the dockerui. I will explain how to set up nginx based reverse proxying in a different post. Here is whats running on my raspberry pi’s.

Docker UI RPI3
here’s whats running my Raspberry Pi 3

I am experimenting with separating Front-End and Back-End components onto different hosts. Current my RPI2 holds Front-End components and the RPI3 holds Back-End components.


  • Jona
    October 11, 2016

    I am sure this post has touched all the internet visitors,
    its really really pleasant piece of writing on building up new weblog.

  • SiuFAndrus
    December 17, 2016

    Thanks to your personal marvelous posting! I really enjoyed reading it, you
    may be an incredible author. I am going to make certain to bookmark your blog
    and can eventually keep coming back down the line.
    I want to encourage you to definitely continue your great writing, possess a nice afternoon!

  • InSWeisman
    December 31, 2016

    Thanks for your personal personal marvelous posting!

    I really enjoyed reading it, you will certainly be an excellent author.I will be sure to bookmark your website
    and definitely will keep coming back from now on. I would like
    to encourage you continue your great posts, have a nice weekend!

Leave a Reply

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