- Build the image with
docker build \
--build-arg QUARTO_ARCH=amd64 \
--build-arg ROOT=true \
-t ghcr.io/meshinchi-lab/bioc_seurat_azimuth:2026.01 .
- Run a container interactively
Be sure to define a location for the RENV cache and possible just used a shared RENV library PATH, to avoid installing the same software packages everytime the container is re-started.
Most Ubuntu package dependencies needed for scRNA-seq and other high-level data analysis packages are installed in the docker container, like HDF5, lib-gsl, magick etc.
The container image also includes the most complex Bioconductor packages already installed, like Seurat, SeuratObject, GSVA, and spatial analyses dependencies.
# renv cache and library paths
# note: these R package directories are NOT github repositories, but exist next to the github analysis code repos that use these R packages.
CACHE="$HOME/github_repos/R"
LIBRARY="$HOME/github_repos/R-4.5"
docker run \
-e USERID=$(id -u) \
-e GROUPID=$(id -g) \
-e DEFAULT_USER=$USER \
-e ROOT=true \
-e RENV_PATHS_CACHE=$CACHE \
-e RENV_PATHS_LIBRARY=$LIBRARY \
-v $HOME/github_repos:/$HOME/github_repos \
-v /mnt:/mnt \
--memory-reservation 64GB \
--cpus 8 \
--rm -ti -p 127.0.0.1:8780:8787 \
ghcr.io/meshinchi-lab/bioc_seurat_azimuth:2026.01
See the official documentation for more information on RStudio server using Docker.
- Open a project with RENV or initialze a new RENV
Initialize:
# R console
# to access the Seurat, GSVA, packages from the container, you must set the external paths during renv initialization
renv_settings <- list("external.libraries"="/usr/local/lib/R/site-library")
renv::init(settings = renv_settings)
# confirm that it includes "/usr/local/lib/R/site-library"
.libPaths()
library(Seurat)
library(GSVA)
Jenny L. Smith https://orcid.org/0000-0003-0402-2779