Skip to content
Snippets Groups Projects
Commit 37851f35 authored by Dominik Brilhaus's avatar Dominik Brilhaus
Browse files

Merge branch 'docker-dependencies' into 'main'

Docker dependencies

See merge request !18
parents c6bd3390 1a41155e
No related branches found
No related tags found
1 merge request!18Docker dependencies
Pipeline #9435 passed
# DESeq2
Workflow used for **differential gene expression analysis**
## DESeq2 docs
- https://bioconductor.org/packages/release/bioc/html/DESeq2.html
## Importing kallisto output with tximport
- https://bioconductor.org/packages/release/bioc/vignettes/tximport/inst/doc/tximport.html#kallisto
## Run pure script (to test)
### Install R dependencies for deseq2
```R
if (!require("BiocManager", quietly = TRUE))
install.packages("BiocManager")
BiocManager::install("DESeq2")
library("DESeq2")
BiocManager::install("tximport")
library("tximport")
BiocManager::install("rhdf5")
library("rhdf5")
```
## Multi-package containers
- R and combinations of library dependencies are available as multi-package containers from [BioContainers](https://github.com/BioContainers/multi-package-containers)
- Searched for `repo:BioContainers/multi-package-containers deseq2 tximport rhdf5`
- and found `quay.io/biocontainers/mulled-v2-05fd88b9ac812a9149da2f2d881d62f01cc49835:a10f0e3a7a70fc45494f8781d33901086d2214d0-0` :tada:
#!/usr/bin/env cwl-runner #!/usr/bin/env cwl-runner
doc: | doc: |
DESeq2 example workflow DESeq2 example workflow for **differential gene expression analysis**
This workflow runs DESeq2 on the output of the kallisto workflow This workflow runs DESeq2 on the output of the kallisto workflow
and the metadata file. and the metadata file.
It runs an R script, deseq2.R, which ideally should be split into three sub scripts and accordingly three workflow steps It runs an R script, deseq2.R, which ideally should be split into three sub scripts and accordingly three workflow steps
...@@ -9,6 +10,17 @@ doc: | ...@@ -9,6 +10,17 @@ doc: |
2. Prep / run deseq2 2. Prep / run deseq2
3. Plot results 3. Plot results
## DESeq2 docs:
https://bioconductor.org/packages/release/bioc/html/DESeq2.html
## Importing kallisto output with tximport
https://bioconductor.org/packages/release/bioc/vignettes/tximport/inst/doc/tximport.html#kallisto
## Multi-package containers
- R and combinations of library dependencies are available as multi-package containers from [BioContainers](https://github.com/BioContainers/multi-package-containers)
- Searched for `repo:BioContainers/multi-package-containers deseq2 tximport rhdf5`
- and found `quay.io/biocontainers/mulled-v2-05fd88b9ac812a9149da2f2d881d62f01cc49835:a10f0e3a7a70fc45494f8781d33901086d2214d0-0` :tada:
cwlVersion: v1.2 cwlVersion: v1.2
class: CommandLineTool class: CommandLineTool
hints: hints:
......
# Use an official R base image
FROM rocker/shiny:4.4
# Install R packages
RUN R -q -e 'install.packages("ggplot2")'
EXPOSE 3838
# Set the working directory to /app
WORKDIR /app
# Default command to run when the container starts
CMD ["R"]
...@@ -3,7 +3,6 @@ ...@@ -3,7 +3,6 @@
# Load libraries # Load libraries
library(shiny) library(shiny)
library(RColorBrewer)
library(ggplot2) library(ggplot2)
# CLI arguments # CLI arguments
...@@ -65,4 +64,5 @@ server <- function(input, output, session) { ...@@ -65,4 +64,5 @@ server <- function(input, output, session) {
# Launch app # Launch app
shinyApp(ui, server) sa <- shinyApp(ui, server)
runApp(sa, port = 3838)
...@@ -4,8 +4,9 @@ cwlVersion: v1.2 ...@@ -4,8 +4,9 @@ cwlVersion: v1.2
class: CommandLineTool class: CommandLineTool
# hints: # hints:
# DockerRequirement: # DockerRequirement:
# dockerPull: # dockerImageId: "shiny"
# dockerFile: {$include: "Dockerfile"}
requirements: requirements:
- class: InitialWorkDirRequirement - class: InitialWorkDirRequirement
......
# Use an official R base image
FROM rocker/r-ver:4.1.3
# Install system dependencies for R packages and other utilities
RUN apt-get update && apt-get install -y \
libcurl4-openssl-dev \
libssl-dev \
libxml2-dev \
git \
build-essential \
&& rm -rf /var/lib/apt/lists/*
# Install BiocManager
RUN R -e "install.packages('BiocManager')"
# Install Bioconductor version 3.14
RUN R -e "BiocManager::install(version = '3.11')"
# Install sleuth from Bioconductor
RUN R -e "BiocManager::install('sleuth')"
# Install other necessary CRAN packages
RUN R -e "install.packages('jsonlite', repos='https://cran.r-project.org')"
# Set the working directory to /app
WORKDIR /app
# Default command to run when the container starts
CMD ["R"]
...@@ -4,9 +4,6 @@ cwlVersion: v1.2 ...@@ -4,9 +4,6 @@ cwlVersion: v1.2
class: CommandLineTool class: CommandLineTool
hints: hints:
# DockerRequirement:
# dockerImageId: "sleuth"
# dockerFile: {$include: "Dockerfile"}
DockerRequirement: DockerRequirement:
dockerPull: quay.io/biocontainers/mulled-v2-fdd016122f200fdc6dc30f6ea2fd0000e8067dff:f9531f6ac1f44332eff70b5912d7d5f3ebe8df38-0 dockerPull: quay.io/biocontainers/mulled-v2-fdd016122f200fdc6dc30f6ea2fd0000e8067dff:f9531f6ac1f44332eff70b5912d7d5f3ebe8df38-0
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment