This lesson is being piloted (Beta version)

Introduction to Docker: Glossary

Key Points

Introduction
  • First key point. Brief Answer to questions.

Pulling Images
  • Pull images with docker pull

  • List images with docker images

  • Image tags distinguish releases or version and are appended to the image name with a colon

Running Containers
  • Run containers with docker run

  • Monitor containers with docker ps

  • Exit interactive sessions just as you would a shell

  • Restart stopped containers with docker start

File I/O with Containers
  • First key point. Brief Answer to questions.

Writing Dockerfiles and Building Images
  • Dockerfiles are written as text file commands to the Docker engine

  • Docker images are built with docker build

  • Docker images can have multiple tags associated to them

  • Docker images can use COPY to copy files into them during build

Removal of Containers and Images
  • Remove containers with docker rm

  • Remove images with docker rmi

  • Perform faster cleanup with docker container prune, docker image prune, and docker system prune

Coffee break
  • Breaks are helpful in the service of learning

Gitlab CI for Automated Environment Preservation
  • gitlab CI allows you to re-build a container that encapsulates the environment each time new commits are pushed to the analysis repo.

  • This functionality is enabled by adding a Dockerfile to your repo that specifies how to build the environment, and an image-building stage to the .gitlab-ci.yml file.

Running our Containerized Analysis
  • Containerized analysis environments allow for fully reproducible code testing and development, with the convenience of working on your local machine.

  • Fortunately, there are tools to help you automate all of this.

Optional: Running Containers on LXPLUS Using Singularity
  • Singularity needs to be used for running containers on LXPLUS.

  • To run your own container, you need to run Singularity manually.

Bonus: Using CMD and ENTRYPOINT in Dockerfiles
  • CMD provide defaults for an executing container

  • CMD can provide options for ENTRYPOINT

  • ENTRYPOINT allows you to configure commands that will always run for an executing container

Challenge Examples
  • Containers are extensive

Glossary

FIXME