Why the Internet of Things Needs Docker Containers

Could Docker be the next big thing in the internet of things (IoT)? That remains to be seen, but this much is clear: Docker containers are well-suited to solve some of the biggest challenges in IoT software deployment.

To date, there has been surprisingly little interest in Docker among IoT developers.

The major exception is Resin.io, which is building a software deployment platform for IoT devices that is based on containers. Last fall, Resin.io launched balena, a Docker-compatible container engine tailored for IoT use cases.

Apart from Resin.io and balena, however, interest in Docker containers for IoT applications is sporadic. There are some examples of Docker use cases for the internet of things, but they are relatively few and far between.

Why the IoT Needs Docker

That’s somewhat surprising. Containers are well-positioned to address some of the main challenges that developers face when deploying software to IoT devices:

  • Minimal hardware resources. Many IoT devices lack powerful computing and memory resources. Their ability to process software updates is therefore limited. Containers can help on this front because installing a new container image does not require much computing power. An IoT device needs simply to download an image, put it wherever it’s going to live and remove the old image. Configuration processing is minimal.
  • Geographic distribution. In some use cases, IoT devices are spread across a large geographic area. Delivering software to them from a single central repository may not work well. With Docker, it’s easy to spin up image registries in multiple locations to serve the entire network well.
  • Limited or sporadic network access. Despite the implications of the term “internet of things,” not all devices on the internet of things are well-connected to the internet. They may have limited network bandwidth, or be online only occasionally. Docker can help to deliver software updates under these circumstances because when container images are updated, Docker downloads only the parts of the image that have changed. (Resin.io is taking this efficiency a step further through delta updates, which enable an even more selective download process when updating a container image.)
  • Widely varying device environments. The software that runs on an IoT device could be almost anything. The diversity of software configurations on IoT devices would normally make application installation difficult, because applications would have to be configured for each type of environment if installed via traditional methods. With containers, however, the operating system version and other software variables are much less important. As long as the device runs some kind of Linux distribution and has a container runtime, you can install a containerized application on it without special configuration.

On balance, containers are not a cure-all for IoT software deployment. There are challenges that need to be addressed to use containers effectively for the IoT. One is the fact that Docker is not compatible with all of the hardware that might be used to build IoT devices. Arguably, Docker is also a relatively heavyweight container runtime, which is not ideal for IoT devices with very few hardware resources. (This is why Resin.io created balena, which is lighter-weight.)

Still, it’s clear that Docker containers offer valuable advantages for developers who are building IoT software. The question is why more IoT platforms aren’t already running on Docker.

Christopher Tozzi

Christopher Tozzi has covered technology and business news for nearly a decade, specializing in open source, containers, big data, networking and security. He is currently Senior Editor and DevOps Analyst with Fixate.io and Sweetcode.io.

Christopher Tozzi has 254 posts and counting. See all posts by Christopher Tozzi