Skip to content

Intermediate Practice Checklist

Level: Intermediate🚴🏻

Basic: Commands

Reading: Docker and Zombie Process



  • Run a container with --init.
  • Build an image and use tini as the entry point.

Exercise: Run a Container to Completion

Instead of running a long-lasting service, a container can also be run to completion to finish a task.


In Kubernetes, a job is usually a pod expected to run to completion with an exit code of 0.

  • Use a python image to run a container to completion with exit code 0.
    • It can be as simple as echo hello
    • You can try to run complicated commands.
  • Build an image to run a container to completion by default.
    • Use the Jupyter image built in the previous checklist.
    • Mount a script into the container and start the container to run the script to completion.
      • Commands: run, -v/--volume.
    • Build an image with the script shipped, and run the container to completion.