03-Mar-2025
Docker can also be used to define software environments and settings for benchmarking studies:
CAMI Challenge: an independent evaluation of several tools in the field of metagenomics.
[…] We defined standards for submitting the software itself, along with parameter settings and required databases and implemented them in Docker container templates … 1
Docker can also be used to define software environments and settings for benchmarking studies:
For reproducibility, participants could submit a Docker container containing the complete workflow, a Bioconda script or a software repository with detailed installation instructions […] 1
Check OS on local machine
Pull Ubuntu (Linux) image
$ docker pull ubuntu:16.04 16.04: Pulling from library/ubuntu 22dc81ace0ea: Pull complete ... Digest: sha256:e348fbbea0e0a0e73ab0370de151e7800684445c509d46195aef73e090a49bd6 Status: Downloaded image for ubuntu:16.04
$ docker pull ubuntu:16.04 16.04: Pulling from library/ubuntu 22dc81ace0ea: Pull complete ... Digest: sha256:e348fbbea0e0a0e73ab0370de151e7800684445c509d46195aef73e090a49bd6 Status: Downloaded image for ubuntu:16.04
$ docker pull ubuntu:16.04 16.04: Pulling from library/ubuntu 22dc81ace0ea: Pull complete ... Digest: sha256:e348fbbea0e0a0e73ab0370de151e7800684445c509d46195aef73e090a49bd6 Status: Downloaded image for ubuntu:16.04
Check OS on local machine
Run the container interactively and check OS version
$ docker run -it ubuntu:16.04 root@407b0fd13fe5:/## uname -a Linux 407b0fd13fe5 4.9.60-linuxkit-aufs [...] x86_64 GNU/Linux
$ docker run -it ubuntu:16.04 root@407b0fd13fe5:/## uname -a Linux 407b0fd13fe5 4.9.60-linuxkit-aufs [...] x86_64 GNU/Linux
$ docker run -it ubuntu:16.04 root@407b0fd13fe5:/## uname -a Linux 407b0fd13fe5 4.9.60-linuxkit-aufs [...] x86_64 GNU/Linux
$ docker run -it ubuntu:16.04 root@407b0fd13fe5:/## uname -a Linux 407b0fd13fe5 4.9.60-linuxkit-aufs [...] x86_64 GNU/Linux
Local project/
directory:
$ ls |- doc/ |- data/ |- code/ |- logs/ |- results/ |- Snakefile |- config.yml |- environment.yml |- Dockerfile |- README.md
$ ls |- doc/ |- data/ |- code/ |- logs/ |- results/ |- Snakefile |- config.yml |- environment.yml |- Dockerfile |- README.md
$ ls |- doc/ |- data/ |- code/ |- logs/ |- results/ |- Snakefile |- config.yml |- environment.yml |- Dockerfile |- README.md
Docker container file system:
$ docker run \ -v $PWD/data:/home/data \ ubuntu:16.04 \ ls |- bin/ |- dev/ |- etc/ |- home/ | |- data/ |- lib/ |- sys/ |- usr/
$ docker run \ -v $PWD/data:/home/data \ ubuntu:16.04 \ ls |- bin/ |- dev/ |- etc/ |- home/ | |- data/ |- lib/ |- sys/ |- usr/
$ docker run \ -v $PWD/data:/home/data \ ubuntu:16.04 \ ls |- bin/ |- dev/ |- etc/ |- home/ | |- data/ |- lib/ |- sys/ |- usr/
root
access, making it suitable for work at HPCs![]() |
![]() |
---|---|
Runs as a daemon process with superuser privileges | Runs as a regular user |
Images stored centrally | Image files that you can move around. |
Isolates the host and container file system by default | Containers have access to host file system |
Well-supported on Mac, Linux and Windows | Limited support on Mac and Windows |