Production RStudio + DESeq2 + clusterProfiler environment for bulk RNA-seq (bRNA3F).
2.2K
Production-ready RStudio environment for bulk RNA-seq analysis with DESeq2, clusterProfiler, and comprehensive Bioconductor packages.
# Pull the image
docker pull voldog/250829_rstudio:2.0
# Run RStudio Server (access at http://localhost:8787)
docker run -d \
-p 8787:8787 \
-e PASSWORD=yourpassword \
-v $(pwd):/workspace \
--name rstudio \
voldog/250829_rstudio:2.0
# Or run interactive R session
docker run -it --rm \
-v $(pwd):/workspace \
voldog/250829_rstudio:2.0 \
R
Default credentials: username: rstudio, password: set via -e PASSWORD=yourpassword
RNA-seq Analysis:
DESeq2 - Differential expression analysistximport - Import transcript-level quantificationsGenomicFeatures - Genome annotation handlingrtracklayer - Genome track manipulationGene Set Analysis:
clusterProfiler - Gene set enrichment and ORAenrichplot - GSEA visualization (gseaplot2, Manhattan plots)fgsea - Fast GSEA implementationmsigdbr - MSigDB gene set accessAnnotation:
org.Hs.eg.db - Human genome annotationorg.Mm.eg.db - Mouse genome annotationAnnotationDbi - Annotation database interfacebiomaRt - BioMart web service queriesVisualization:
ComplexHeatmap - Advanced heatmap generationEnhancedVolcano - Publication-quality volcano plotsggrepel - Smart label placementpheatmap - Pretty heatmapsRColorBrewer - Color palettesThis image is the official environment for the bRNA3F enterprise RNA-seq analysis template:
# Clone and run bRNA3F in container
git clone https://github.com/crmlab-uab/bRNA3F.git
cd bRNA3F
docker run -d \
-p 8787:8787 \
-e PASSWORD=rnaseq2024 \
-v $(pwd):/data/bRNA3F \
-w /data/bRNA3F \
--name brna3f \
voldog/250829_rstudio:2.0
Then access RStudio at http://localhost:8787 and render:
# Working directory is /data/bRNA3F
rmarkdown::render("bRNA3F.Rmd",
params = list(config_file = "config/config.yaml"),
output_file = "output/analysis_report.html")
Required directory structure:
bRNA3F/
āāā data/
ā āāā sf/ # Salmon quantification files (*.sf)
ā āāā genome/ # Auto-downloaded genome references
ā āāā genesets/ # Auto-downloaded MSigDB gene sets
āāā config/ # Configuration files
āāā output/ # Analysis results (HTML, CSV, plots)
āāā logs/ # Execution logs
# Example DESeq2 workflow
library(DESeq2)
library(tximport)
# Import Salmon quantifications
files <- list.files("data/salmon", pattern = ".sf", full.names = TRUE)
txi <- tximport(files, type = "salmon", txOut = FALSE)
# DESeq2 analysis
dds <- DESeqDataSetFromTximport(txi, colData = samples, design = ~ condition)
dds <- DESeq(dds)
results <- results(dds, contrast = c("condition", "treated", "control"))
# GSEA with clusterProfiler
library(clusterProfiler)
gene_list <- results$log2FoldChange
names(gene_list) <- rownames(results)
gene_list <- sort(gene_list, decreasing = TRUE)
gsea_result <- gseGO(geneList = gene_list,
OrgDb = org.Hs.eg.db,
ont = "BP",
keyType = "ENSEMBL")
Mount your analysis directory with proper structure:
# For bRNA3F project
docker run -d \
-p 8787:8787 \
-e PASSWORD=explore \
-v /path/to/bRNA3F:/data/bRNA3F \
-w /data/bRNA3F \
--name rstudio-explore \
voldog/250829_rstudio:2.0
# Or for custom project with specific mounts
docker run -d \
-p 8787:8787 \
-e PASSWORD=explore \
-v /path/to/salmon_quants:/data/sf \
-v /path/to/results:/output \
-w /workspace \
--name rstudio-custom \
voldog/250829_rstudio:2.0
# Mount complete bRNA3F project (recommended)
docker run -d \
-p 8787:8787 \
-e PASSWORD=yourpassword \
-v $(pwd):/data/bRNA3F \
-w /data/bRNA3F \
voldog/250829_rstudio:1.9
# Mount specific directories for separation
docker run -d \
-p 8787:8787 \
-e PASSWORD=yourpassword \
-v $(pwd)/data/sf:/data/bRNA3F/data/sf \
-v $(pwd)/output:/data/bRNA3F/output \
-v $(pwd)/config:/data/bRNA3F/config \
-w /data/bRNA3F \
voldog/250829_rstudio:1.9
# Use named volumes for persistent genome/genesets cache
docker volume create brna3f-genome
docker volume create brna3f-genesets
docker run -d \
-p 8787:8787 \
-e PASSWORD=yourpassword \
-v $(pwd):/data/bRNA3F \
-v brna3f-genome:/data/bRNA3F/data/genome \
-v brna3f-genesets:/data/bRNA3F/data/genesets \
-w /data/bRNA3F \
voldog/250829_rstudio:1.9
PASSWORD - RStudio password (required)ROOT=true - Enable root access in containerDISABLE_AUTH=true - Disable RStudio authentication (not recommended for production)USERID - Match host user ID (default: 1000)GROUPID - Match host group ID (default: 1000)# Limit resources for large datasets
docker run -d \
-p 8787:8787 \
-e PASSWORD=yourpassword \
--memory="16g" \
--cpus="8" \
-v $(pwd):/data/bRNA3F \
-w /data/bRNA3F \
voldog/250829_rstudio:1.9
# Install additional packages to persistent volume
docker run -d \
-p 8787:8787 \
-e PASSWORD=yourpassword \
-e R_LIBS_USER=/data/bRNA3F/rlibs \
-v $(pwd):/data/bRNA3F \
-w /data/bRNA3F \
voldog/250829_rstudio:1.9
This image has been validated on:
Real-world testing:
Typical DESeq2 analysis (50 samples, 20K genes):
Parallel processing speedup:
# Check container logs
docker logs rstudio
# Common fix: ensure port 8787 is available
docker run -d -p 8888:8787 -e PASSWORD=yourpassword voldog/250829_rstudio:1.9
# Access at http://localhost:8888
# Increase Docker memory limit (Docker Desktop: Settings ā Resources)
docker run -d -p 8787:8787 -e PASSWORD=yourpassword --memory="32g" voldog/250829_rstudio:1.9
# Or in R, enable memory-efficient caching
options(parallelly.maxWorkers.localhost = 4)
# Install system dependencies for specific packages
docker exec -it rstudio bash
apt-get update && apt-get install -y libgdal-dev # For spatial packages
R -e "install.packages('sf')"
# Match host user ID (important for Linux)
docker run -d \
-p 8787:8787 \
-e PASSWORD=yourpassword \
-e USERID=$(id -u) \
-e GROUPID=$(id -g) \
-v $(pwd):/data/bRNA3F \
-w /data/bRNA3F \
voldog/250829_rstudio:1.9
For production use:
-e PASSWORD=$(openssl rand -base64 32)--cap-drop=ALL --cap-add=CHOWN,SETUID,SETGIDdocker pull voldog/250829_rstudio:latestdocker scan voldog/250829_rstudio:1.9Local development only:
# Disable auth for localhost testing (not recommended for production)
docker run -d \
-p 127.0.0.1:8787:8787 \
-e DISABLE_AUTH=true \
-v $(pwd):/data/bRNA3F \
-w /data/bRNA3F \
voldog/250829_rstudio:1.9
2.0 - Current production release (Nov 2025)latest - Always points to newest stable versiondev - Development builds (may be unstable)This image is provided under the MIT License. Base Rocker images are under GPL-2.
Maintained by: CRM Lab, University of Alabama at Birmingham
Contact: [email protected]ā
ā If you find this image useful, please star the bRNA3F repositoryā !
Content type
Image
Digest
sha256:0806d7427ā¦
Size
5.5 GB
Last updated
7 months ago
docker pull voldog/250829_rstudio