-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy pathDockerfile
80 lines (58 loc) · 1.43 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
70
71
72
73
74
75
76
77
78
79
80
#
# Stage: build
#
FROM python:3.11.0-bullseye AS build_deps
LABEL pav_stage=build_deps
ENV PAV_BASE=/opt/pav
WORKDIR ${PAV_BASE}
# Binary dependencies (samtools, minimap2, LRA...)
RUN mkdir -p ${PAV_BASE}/files/docker
COPY files/docker/build_deps.sh ${PAV_BASE}/files/docker
RUN files/docker/build_deps.sh
RUN rm -rf files
#
# Stage: stage pav files
#
FROM python:3.11.0-bullseye AS stage_pav
LABEL pav_stage=stage_pav
ENV PAV_BASE=/opt/pav
WORKDIR ${PAV_BASE}
# Copy PAV files into the container
COPY files/ ${PAV_BASE}/files/
COPY scripts/ ${PAV_BASE}/scripts/
COPY dep/ ${PAV_BASE}/dep/
COPY pavlib/ ${PAV_BASE}/pavlib/
COPY rules/ ${PAV_BASE}/rules/
COPY Snakefile Dockerfile *.md ${PAV_BASE}/
#
# Stage: pav
#
FROM python:3.11.0-bullseye AS pav
LABEL pav_stage=pav
ENV PAV_VERSION="2.4.6"
ENV PAV_BASE=/opt/pav
LABEL org.jax.becklab.author="Peter Audano<[email protected]>"
LABEL org.jax.becklab.name="PAV"
LABEL org.jax.becklab.version="${PAV_VERSION}"
WORKDIR ${PAV_BASE}
# Base python and snakemake
RUN pip3 install \
biopython \
intervaltree \
matplotlib \
matplotlib-venn \
numpy \
pandas \
pysam \
scipy \
snakemake \
pulp \
drmaa \
joblib
# Copy from build
COPY --from=build_deps ${PAV_BASE} ${PAV_BASE}
COPY --from=stage_pav ${PAV_BASE} ${PAV_BASE}
RUN files/docker/build_home.sh
# Runtime environment
ENV PATH="${PATH}:${PAV_BASE}/bin"
ENTRYPOINT ["/opt/pav/files/docker/run"]