forked from StaPH-B/docker-builds
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
74 lines (51 loc) · 2.38 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
ARG LIMA_VER="2.12.0"
## Builder ##
FROM ubuntu:jammy AS builder
ARG LIMA_VER
ARG DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y \
wget \
build-essential \
gfortran \
r-base
# build required R packages
RUN R -e "install.packages(c('ggplot2', 'dplyr', 'tidyr' ,'viridis', 'scales', 'data.table', 'hexbin'), quietly = TRUE, warn.conflicts = FALSE, repos = 'http://cran.us.r-project.org')"
# Rscripts
RUN wget -P /usr/local/bin/ https://github.com/PacificBiosciences/barcoding/raw/master/scripts/r/report_summary.R \
https://github.com/PacificBiosciences/barcoding/raw/master/scripts/r/report_detail.R &&\
chmod +x /usr/local/bin/report_summary.R /usr/local/bin/report_detail.R
## App ##
FROM ubuntu:jammy AS app
ARG LIMA_VER
LABEL base.image="ubuntu:jammy"
LABEL dockerfile.version="1"
LABEL software="Lima"
LABEL software.version="${LIMA_VER}"
LABEL description="The PacBio Barcode Demultiplixer & Primer Remover"
LABEL website="https://github.com/PacificBiosciences/barcoding"
LABEL license="https://github.com/PacificBiosciences/barcoding/blob/master/LICENSE"
LABEL maintainer="Kutluhan Incekara"
LABEL maintainer.email="[email protected]"
RUN apt-get update && apt-get install --no-install-recommends -y \
wget \
r-base &&\
apt-get autoclean && rm -rf /var/lib/apt/lists/*
COPY --from=builder /usr/local/lib/R/site-library/ /usr/local/lib/R/site-library/
COPY --from=builder /usr/local/bin/ /usr/local/bin/
RUN wget https://github.com/PacificBiosciences/barcoding/releases/download/v${LIMA_VER}/lima.tar.gz &&\
tar -C /usr/local/bin -xvf lima.tar.gz &&\
rm lima.tar.gz
ENV LC_ALL=C
CMD lima -h && lima-undo -h
WORKDIR /data
FROM app AS test
RUN lima -h && lima-undo -h
# download test files
RUN wget -q https://downloads.pacbcloud.com/public/dataset/HiFiViral/Jan_2022/HiFiViral_Barcoded_M13_Primer_Plate.fasta \
https://downloads.pacbcloud.com/public/dataset/HiFiViral/Jan_2022/InqabaOmicronSamples_Barcoded_Sample.csv \
https://downloads.pacbcloud.com/public/dataset/HiFiViral/Jan_2022/m64187e_211217_130958.hifi_reads.bam
# run test
RUN lima m64187e_211217_130958.hifi_reads.bam HiFiViral_Barcoded_M13_Primer_Plate.fasta demux.hifi.bam --biosample-csv InqabaOmicronSamples_Barcoded_Sample.csv --hifi-preset ASYMMETRIC &&\
cat demux.hifi.lima.summary
RUN report_summary.R demux.hifi.lima.report &&\
ls | grep png