From 2d0d66bbaf261c931cfb3532cbe3943c9006f75b Mon Sep 17 00:00:00 2001 From: js2264 Date: Wed, 6 Sep 2023 19:36:40 +0200 Subject: [PATCH] docker: switch to micromamba in Dockerfile --- Dockerfile | 31 ++++++++++--------------------- environment.yml | 2 +- 2 files changed, 11 insertions(+), 22 deletions(-) diff --git a/Dockerfile b/Dockerfile index 83cb6f2..3867833 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,27 +1,16 @@ -FROM continuumio/miniconda3:4.9.2 +FROM mambaorg/micromamba:latest LABEL Name=hicstuff Version=3.2.0 -COPY * ./ /app/ -WORKDIR /app +COPY --chown=$MAMBA_USER:$MAMBA_USER . ./ -RUN conda update -y conda -RUN conda config --add channels bioconda +## Install dependencies +RUN micromamba install -y -n base --file environment.yml && \ + micromamba install -y -n base pip && \ + micromamba clean --all --yes -# Get 3rd party packages directly from conda -RUN conda install -c conda-forge -y \ - pip \ - bowtie2 \ - minimap2 \ - bwa \ - samtools \ - htslib \ - pysam \ - cooler \ - pairtools && conda clean -afy +## Install hicstuff +RUN micromamba run python3 -m pip install -e . -RUN pip install -Ur requirements.txt -# Using pip: -RUN pip install . -#CMD ["python3", "-m", "hicstuff.main"] -ENTRYPOINT [ "hicstuff" ] +WORKDIR /home/mambauser/ +ENTRYPOINT [ "/bin/bash" ] diff --git a/environment.yml b/environment.yml index 299a529..279cf42 100644 --- a/environment.yml +++ b/environment.yml @@ -1,4 +1,4 @@ -name: base +name: hicstuff channels: - conda-forge - bioconda