Skip to content

Latest commit

 

History

History
64 lines (39 loc) · 4.69 KB

MOTIVATION.md

File metadata and controls

64 lines (39 loc) · 4.69 KB

Motivation

This page explains the reasons behind the creation of the taltechivarlab/ubuntu-desktop Docker image (and other images based on it).

📦 What are containers?

Containers are an approach to packaging software in an isolated, standardized and easy-to-distribute form. They can be likened to virtual machines (VMs), which allow to run multiple operating systems (OSs) on a single physical host machine, with software inside those environments being isolated from the host OS. However, in contrast to VMs, containers are not required to have the entire OS inside them — instead, they use the host OS's kernel for their code execution needs. This makes containers much smaller and often faster than virtual machines.

Just like with VMs, containers can be given direct access to the host machine's storage and devices (such as GPUs).

All these points are explained in much greater detail in this blogpost by Docker.

🐳 Why Docker containers are good?

Docker is an open source platform for developing and distributing containers. It is steadily becoming the standard environment for running production software. Adopting it has the following benefits:

  • Docker provides a multiplatform engine, which allows to easily run the same containers on Linux, Windows and macOS hosts.
  • It has an official online registry for sharing container images called Docker Hub, which provides free storage for public container images.
  • Docker container images implement a layer caching mechanism, which allows to save a lot of time when pulling images with common base from remote repositories as well as when building them.
  • And many others...

🧪 How TalTech IVAR Lab uses containers?

In our laboratory we often work with complex software such as ROS, which normally requires time-consuming installation and an environment with the specific set of tools and pre-configured settings. Doing this setup manually every time when we need a fresh ROS installation is a tedious task that is prone to human error, and packaging it in a VM still poses problems with distribution.

Thus, we have decided to package our default development environment in a Docker image instead. This brings multiple benefits:

  • We can get it up and running on any computer in minutes (install Docker + pull and run the image). This is especially easy on Linux hosts, where the whole procedure takes just 5 commands in a terminal.

  • If something goes wrong in the environment, simply starting a new container from the same image provides a clean slate to work with, no repetitive setup required. This encourages experimentation and learning.

  • The content of the image and any of its derivatives can be easily managed and updated through their Dockerfiles hosted in Git repositories (e.g. Dockerfile of taltechivarlab/ubuntu-desktop).

  • It is easy to distribute: all our images are published on Dockerhub under our taltechivarlab account and can be started with a single docker run command.

With this, we hope that you now have a better understanding of what containers are and why using them is worth a try 😉