Container Fundamentals with Docker
Learn Docker from first principles — images, Dockerfiles, networking, volumes, and multi-stage builds.
View badge details
About This Course
Course Curriculum
12 Lessons
What Are Containers
Learn what containers are, how they compare to VMs, and master the Docker CLI for running, inspecting, and managing containers.
What Are Containers - Lab Exercises
Containers vs VMs (isolation, shared kernel, efficiency), Docker architecture (engine, daemon, CLI, containerd), running containers (docker run, -d, -it, --name, --rm), container lifecycle (start/stop/restart/remove, docker ps -a), inspecting containers (docker logs, exec, inspect, stats)
Docker Images and Dockerfiles
Build custom Docker images with Dockerfiles. Learn FROM, COPY, RUN, CMD, ENTRYPOINT, and image management commands.
Docker Images and Dockerfiles - Lab Exercises
Image anatomy (layers, union filesystem, base images, tags), Dockerfile instructions (FROM, COPY, RUN, WORKDIR, EXPOSE, CMD, ENTRYPOINT), building images (docker build -t, build context, .dockerignore), CMD vs ENTRYPOINT (exec form vs shell form), image management (docker images, rmi, tag, history)
Container Networking
Understand Docker networking models including bridge, host, and overlay networks. Learn to connect containers, expose ports, and enable service communication.
Container Networking - Lab Exercises
Default bridge network, user-defined networks (docker network create, DNS by name), port mapping (-p host:container, -P), multi-container communication (web app + database), network troubleshooting (docker network inspect, exec ping)
Volumes and Persistent Data
Master Docker volumes and bind mounts for persisting data beyond container lifecycles. Learn volume drivers, backup strategies, and data sharing between containers.
Volumes and Persistent Data - Lab Exercises
Container filesystem problem (data lost on remove), named volumes (docker volume create, -v name:/path), bind mounts (-v /host:/container, live reload), tmpfs mounts, volume management (ls, inspect, prune)
Image Optimization and Best Practices
Optimize Docker images for size and security using multi-stage builds, layer caching, minimal base images, and vulnerability scanning best practices.
Image Optimization and Best Practices - Lab Exercises
Multi-stage builds (separate build and runtime, reduce size), layer caching (instruction order, COPY requirements first), security (non-root USER, minimal base images, no secrets in images), .dockerignore, image scanning (docker scout)
Capstone Briefing Containerize a Full Stack App
Capstone briefing for containerizing a full-stack application. Review the architecture, requirements, and approach for the hands-on challenge ahead.
Capstone Containerize a Full Stack App
Capstone: containerize PackShip e-commerce app - Python FastAPI backend (multi-stage Dockerfile, non-root user), PostgreSQL database (named volume), Redis cache (alpine), custom bridge network, port mapping, .dockerignore, image under 150MB