Skip to main content

Docker on a Raspberry – Q&A

Soon after i published my last blogpost (Raspberry Pi + Docker + RTL-SDR) i received a bunch of feedback, questions and critic.

“Why not just compile the applications directly?” – “I may be missing the point here but why bother with Docker on the Pi?” – “It does nothing to help the Dump1090 program at all.”

So I’d like to adress some of the points in this post and explain my motivation for using Docker.


Let’s start right away with the most controversial question: Why Docker on a Pi?

Well, because it’s possible 🙂 About two weeks ago i stumbled over a blog post from the guys at Hypriot. They not only managed to install Docker on a Raspberry, they also packaged a nice and easy to use SD-Card image which i used for my first experiments. I already have some substantial background in terms of Docker as we’re using this in larger scale in our company. The concept of Containers and Images is a nice fit if you want to build an orchestrated and reproducible toolchain for you RTL-SDR – Build your Image, upload it to the docker hub – the next time you’re reinstalling your Pi (or installing a new one) you just have to run one command and the exact same version, incl. all the dependencies will be downloaded from the hub and ready to use in minutes. So no problems with outdated Howtos, updated libraries, missing git repositories etc.


Read More

Raspberry Pi + Docker + RTL-SDR

In the last days, i tinkered with different things: I installed Docker onto a Raspberry Pi 2, built several docker images [1][2] and got myself two new RTL-SDR-Sticks.

Today, I’ll bring all these Projects together and show you how to build a virtual aircraft radar (screenshot) – so fasten your seatbelt 😉

DUMP1090 Screenshot

I’m ready – tell me what I need

  • You’ll need a Raspberry Pi 2  – yes, 2! – Of course, you can go with a Pi 1 – but to be honest, this thingy has just not enough ram and only one core so it’s not really suitable for docker. But hey, if you like the pain – go on 😉
  • The Pi has to be prepared to run Docker – You can use the guide from my blog post if you need help
  • And of course you need a RTL-SDR Stick – so if you ever watched DVB-T on your Laptop, the chances are good that you already have a suitable Receiver. Some people over at Reddit compiled a nice list of sticks which are suitable for our little experiment. Oh, and an Antenna would be awesome 😉

List completed? All points checked? Great, let’s go on!


Read More

New RTL-SDR gear

I’ve played with these RTL-SDR sticks for several years now and I am still amazed about the possibilities I have with these cheap pieces of hardware. I managed to receive several data modes like ADS-B, ACARS, AIS and the wireless outdoor thermometer of my neighbor – I’ll write several follow-up posts on this topics 🙂

I decided to get two new Sticks for my collection – this time with a TCXO oscillator to get a more stable reception.

Modified Stick? Whats the deal?

Shift over time (source:
Shift over time (source:

A common problem for these sticks is frequency stability over time. As the oscillator is heating up under load, the frequency of the crystal measured in ppm (parts per million) will change – which causes the frequency to shift. Typical values for cheap sticks are +-150ppm. The real amount of frequency should could be several kHz, which make this behaviour really annoying for headless receivers (like ADSB receivers on a Raspberry Pi) – especially if you try to receive a narrow signal.





Read More

Install RabbitMQ on Dokku

In a previous post, i explained how to package RabbitMQ and several plugins in a Docker Container, so this will be a followup which shows you how to deploy and configure the RabbitMQ Container on a dokku host.

This Post will not explain how to install Dokku itself – so i assume you have a Dokku environment configured and ready.

Prepare your deployment

The following Dockerfile uses the official RabbitMQ Container and extending it by activating the management and the MQTT plugin. If you don’t need MQTT the you can delete the line  RUN rabbitmq-plugins enable --offline rabbitmq_mqtt .

Now create a new directory containing the Dockerfile with the above contents and initialize a git repository.

Then add your dokku server via  git remote add dokku

DO NOT PUSH(!) your changes now, you have to do some configuration first!


Read More

Optimise your Dockerfile

While i am building images for Docker on a Raspberry Pi, I searched for a way to keep my Images as small as possible because of the limited amount of disk space and also because of my $&#@ internet connection at home (really a pain in the $#@ if you want to push bigger images to the docker hub).

Let’s start with the base image for all of my sdr tools. This image derives from resins’s Debian Jessie Image and contains the basic “toolchain” for building/compiling rtl-sdr applications.

So, that’s the original Dockerfile were using to build my Baseimage (sysrun/rpi-rtl-sdr-base):

This Dockerfile gives us a container size of ~307MB.

Optimise the process

We don’t need the package cache (downloaded packages) to be integrated in our container. So adding a apt-get clean after our install will save us some space. The apt-get update is populating the /var/lib/apt/lists/ with stuff we also don’t need after the build. So just remove them

This saves us 22MB – in this case not much. But depending on the packages you install, it could be more.

If you’re doing this for a base container, keep in mind that you have to run apt-get update to repopulate your apt cache. If you miss this step, your apt-get install calls will fail! Also clean up again after you installed the new packages.

The final Dockerfile

Read More

Docker on a Raspberry Pi

The guys at Hypriot did an awesome job to bring Docker to the Raspberry Pi world.

If you want to give it a try, you have two options

Option 1: Prebuilt images

Thats the best option if you want to have a full-fledged docker environment with optimized settings and hassle free installation.

Just download the image from this page and “burn” it to a sd-card. Plug the card in your RPi and enjoy.

Read more about this solution in their Blog: Get your all-in-one Docker playground now: HypriotOS reloaded!

Option 2: Debian Package

This option is the way you should go if you don’t have a spare sd-card around.

You can download a .dep file from this page and install it via dpkg -i package_name.deb

I tried this option on my current Jessie installation and encountered one problem: All docker command had to be issued via sudo. Thats because the docker.sock is only accessible for the root user. I didn’t follow up on this as i am going with option one 🙂


Quick test run? Here we go

After you have installed either the image version or the dep, you should be good to go for a first test.

Log in to your pi and kick of the following command:

docker run -d -p 8080:80 hypriot/rpi-busybox-httpd

Docker is now downloading the webserver image from the docker registry and start the container.

Now start your web browser and open http://<your-pi-ip>:8080

hyprion test docker images


Wait, there is one more thing

They also build an awesome hardware stack called “The Pi Tower” which consists of 4 Raspberry Pi 2 stacked on top of a 5-Port-Switch.

(c) 2015 hypriot
Pi Tower – (c) 2015 hypriot

Read more about this at their blog: Let Docker Swarm all over your Raspberry Pi Cluster



Read More

Installing WordPress on Dokku

To get WP up and running you have to prepare several things. This guide is based on a Dokku installation on a DigitalOcean Dropplet; for me the most convenient way to get a Dokku platform running.

Prepare your dokku environment

To make sure everything is on place, you should prepare your dokku environment.

1. Add your app

Create a app with the  dokku apps:create <appname> where appname is the sub domain of your dokku server.

2. Add a Database

I’ll use the official mariadb plugin for firing up a mysql database.

First add a new database by executing the following command  dokku mariadb:create .

Choose whatever you want for the databasename.

After firing the command, you should see a output like this:

Please note the line

  DSN: mysql://mariadb:[email protected]:3306/my_wp_database 

we will need this information later to configure the WordPress database!

Now connect your database to your app. This step makes sure your app has access to the db.

dokku mariadb:link my_wp_database yourappname


Read More

Dockerize RabbitMQ

You want to run RabbitMQ in a Docker environment? You want MQTT and a nice web interface for administration?

Just use the Dockerfile and the hints in this post to get your server up and running in no time!

Beware: There are two very important points to keep in mind! If you miss even one of these steps, you will loose your configuration and users on every restart!


Read More