-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathDockerfile
45 lines (33 loc) · 966 Bytes
/
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
# Get image
FROM condaforge/mambaforge
# Add args for building
ARG UID
ARG GID
# Metadata
LABEL Name=hicberg Version=0.0.1
# Update base components and set-up mamba
RUN apt-get update && apt-get install -y gcc
RUN mamba config --add channels bioconda
RUN mamba install -c conda-forge -y pip \
&& mamba clean -afy
# # Add non root user
RUN apt update
RUN apt install -y sudo
RUN addgroup --gid $GID nonroot
RUN adduser --uid $UID --gid $GID --disabled-password --gecos "" nonroot
RUN echo 'nonroot ALL=(ALL) NOPASSWD: ALL' >> /etc/sudoers
#Install bowtie2 and samtools
RUN mamba install bioconda::bowtie2
RUN mamba install bioconda::samtools
RUN mamba install bioconda::bedtools
RUN mamba install bioconda::ucsc-bedgraphtobigwig
# Copy necessary files
COPY --chown=nonroot:nonroot * ./ /app/
# COPY * ./ /app/
# Set working directory
WORKDIR /app
RUN chmod 777 /app/*
# Install HiC-BERG
RUN pip install -e .
# Switch to non root user
USER nonroot