Learning paths / Foundations

Learning path 38 modules40 lessons open

Containers

Images, containers, Dockerfiles, registries, Compose and volumes, ending with your own image running on ComputeSphere.

At a glance

Level
Beginner to intermediate
Duration
About 8 hours
Modules
8
Verified labs
2
Prerequisites
Application foundations recommended; module 1 sets up Docker

Modules in this path

  1. 1. Why containersSet up Docker, reproducible environments
    1. Set up Docker Reading, 10 min
    2. "Works on my machine" and why containers fix it Video and reading, 12 min
    3. Containers vs virtual machines, revisited Reading, 6 min
    4. Check: why containers Knowledge check, 5 min
    4 open
  2. 2. Images and layersLayers, tags, digests, base images
    1. Images are layers Reading, 6 min
    2. Tags and digests Reading, 6 min
    3. Choosing a base image Reading, 6 min
    4. Try it: inspect an image's layers Reading, 12 min
    5. Check: images Knowledge check, 5 min
    5 open
  3. 3. Running containersPorts, environment, logs
    1. Running a container: ports and environment Reading, 6 min
    2. Logs, exec and restart behaviour Reading, 6 min
    3. Try it: run, inspect and stop a container Reading, 15 min
    4. Check: running containers Knowledge check, 5 min
    4 open
  4. 4. Writing DockerfilesMulti-stage, non-root, small images
    1. Anatomy of a Dockerfile Video and reading, 13 min
    2. Multi-stage builds Reading, 6 min
    3. Non-root users and least privilege in images Reading, 5 min
    4. .dockerignore and build context Reading, 5 min
    5. Try it: shrink an image from 1.4 GB to 20 MB Reading, 25 min
    6. Check: Dockerfiles Knowledge check, 5 min
    6 open
  5. 5. RegistriesPushing, pulling, private registries
    1. Registries, repositories and tags Reading, 5 min
    2. Private registries and credentials Reading, 5 min
    3. Try it: push to a registry Reading, 12 min
    4. Check: registries Knowledge check, 5 min
    4 open
  6. 6. Docker ComposeA local stack in one file
    1. Why Compose: a stack in one file Reading, 6 min
    2. Try it: app plus database with Compose Reading, 15 min
    3. From Compose to ComputeSphere with csph import compose Reading, 6 min
    4. Lab: from Compose to ComputeSphere Verified lab, 40 min
    5. Check: Compose Knowledge check, 5 min
    5 open
  7. 7. Persistent storageVolumes vs the container filesystem
    1. The container filesystem is temporary Reading, 6 min
    2. Volumes and bind mounts Reading, 6 min
    3. Try it: lose data, then keep it with a volume Reading, 15 min
    4. On ComputeSphere: SphereStor volumes mounted on a service Reading, 5 min
    5. Check: storage Knowledge check, 5 min
    5 open
  8. 8. Containerize a real appNode.js, Python and Go recipes
    1. A health endpoint in every app Reading, 6 min
    2. Recipe: containerize a Node.js app Reading, 6 min
    3. Recipe: containerize a Python app Reading, 6 min
    4. Recipe: containerize a Go app Reading, 6 min
    5. Try it: containerize a provided app Reading, 30 min
    6. Check: containerizing Knowledge check, 5 min
    6 open
Path challenge, 40 minLab: ship your own containerPush the image you built to your own public registry repository and deploy it to ComputeSphere with a health check, then prove it answers on its URL.