Tagged

Docker guides

Hands-on guides that cover Docker. Every command is run and verified on a live server before it is published.

Guide

Your First Container

A beginner guide to Docker on a VPS: run your first container in one command and learn the image versus container difference that trips people up.

8 min read
Guide

The Docker Engine and Your First Container

Install the Docker engine on a bare Ubuntu 24.04 slice, run your first Docker container in one command, then meet the image and container split that runs it.

10 min read
Guide

Images and Dockerfiles: Build a Small App Image

Build a Docker image from a Dockerfile on Ubuntu 24.04, read its layers with docker history, then shrink it from 477 MB to under 20 MB with multi-stage.

6 min read
Guide

Building Your App's Image

Package a Node app into a small, non-root Docker image. Build it with a Dockerfile and learn why layer caching and COPY order decide rebuild speed.

8 min read
Guide

A Real Stack with Compose

Describe your whole stack, the app plus a Postgres database, in one Docker Compose file. Bring it up with one command and connect services by name.

8 min read
Guide

Compose a Multi-Service App

Use Docker Compose to run an app and a Redis datastore as one stack: one file, a private network, health checks, and both services up and reachable.

7 min read
Guide

Volumes and Networks That Persist and Connect

Prove Docker volumes keep data across a full teardown, and that a user-defined network lets containers resolve each other by name where the bridge cannot.

6 min read
Guide

Compose in Production

Take a Docker Compose stack to production: restart policies, resource limits, HTTPS out front, and the security defaults that contain a container breach.

9 min read
Guide

Resource Limits and Restart Policies

Set Docker resource limits for memory and CPU, watch docker stats enforce them, and add a restart policy that recovers a container after it crashes.

6 min read
Guide

Logging and Observability

Read docker logs from a running stack, cap them with json-file rotation so they cannot fill the disk, and use docker stats and inspect to see inside.

6 min read
Guide

Security and Hardening

Harden Docker security for a container: run as non-root, use a read-only filesystem, drop capabilities, and keep the secret out of the image.

6 min read