Container (software)
Also known as: software container, container, Docker container, containerization
A software container is a lightweight, self-contained package that holds an application along with the libraries, settings, and tools it needs to run.
Containers share the host computer's operating system kernel, so they start in seconds and use far fewer resources than virtual machines. Docker popularized containers, and Kubernetes manages them at scale in the cloud. While containers make apps portable and consistent, they add new security and management responsibilities.
Container (software), explained at three levels
At home
A container is like a lunchbox that holds a full meal with utensils and napkins included. Wherever you take it, everything needed is already inside.
At work
Containers let developers ship software that works the same on their laptops, test servers, and the cloud.
At home
Home server fans often run apps such as media servers or password managers in Docker containers, making them easy to install and update.
At work
Containers are built from images, stored in registries, and run by engines such as Docker or containerd. Kubernetes orchestrates many containers across servers, handling scaling and restarts.
At home
Container images from random sources can include malware or outdated software. In my opinion, stick to official or well-maintained images.
At work
Scan images for vulnerabilities, use minimal base images, avoid running containers as root, sign images, keep secrets out of images, and patch by rebuilding rather than updating running containers.
Real-world examples
At home
Jerome runs a home media server. Using Docker, he installed it with one command and updates it by pulling the newest container image.
At work
Lena leads a dev team at a Winnipeg startup. Packaging their app in containers ended 'works on my machine' problems between developers and production.
How it compares
| feature | Container (software) | Virtual Machine |
|---|---|---|
| Includes | App and libraries | Full operating system |
| Start time | Seconds | Minutes |
| Resource use | Light | Heavy |
| Isolation | Shares host kernel | Stronger |
Containers are lightweight and fast. VMs are heavier but more isolated.
For analysts
When teams propose containers, I'd ask who'll manage image updates and security scanning. The technology is easy to adopt and easy to neglect.
History & origin
The ideas behind containers date to Unix's chroot command in 1979, FreeBSD 'jails' in 2000, and Solaris Zones in 2004. Google engineers contributed control groups (cgroups) to the Linux kernel around 2007, and LXC combined these features in 2008. Docker, unveiled by Solomon Hykes at PyCon in March 2013, made containers easy to build and share, sparking rapid adoption. Google released Kubernetes in 2014 and donated it to the new Cloud Native Computing Foundation in 2015, the same year the Open Container Initiative formed to standardize formats. In my view, containers did for software what shipping containers did for global trade: standard boxes that move anywhere.