-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #5 from Tony-xy-Liu/dev
update master
- Loading branch information
Showing
24 changed files
with
2,369 additions
and
646 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
/* | ||
!/src | ||
/src/**/__pycache__ | ||
/src/*.egg-info | ||
!/envs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,20 @@ | ||
__pycache__ | ||
|
||
.idea/ | ||
*_env/ | ||
*.sif | ||
*.egg-info | ||
|
||
tests/test_data/FabFos_DB/ | ||
trim_sequences.fasta.* | ||
|
||
/dist | ||
/build | ||
/conda_build | ||
/conda_recipe/* | ||
!/conda_recipe/compile_recipe.py | ||
!/conda_recipe/meta_template.yaml | ||
/data | ||
/scratch | ||
/docker/src | ||
/secrets |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
ARG CONDA_ENV=fabfos | ||
|
||
FROM condaforge/mambaforge as build-env | ||
# https://mamba.readthedocs.io/en/latest/user_guide/mamba.html | ||
|
||
# scope var from global | ||
ARG CONDA_ENV | ||
COPY ./envs/base.yml /opt/env.yml | ||
# Create conda environment: | ||
# name must match what is in conda.yml | ||
RUN mamba env create --no-default-packages -n $CONDA_ENV -f /opt/env.yml\ | ||
&& mamba clean -afy | ||
|
||
# use a smaller runtime image | ||
# jammy is ver. 22.04 LTS | ||
# https://wiki.ubuntu.com/Releases | ||
FROM ubuntu:jammy | ||
# scope var from global | ||
ARG CONDA_ENV | ||
COPY --from=build-env /opt/conda/envs/${CONDA_ENV} /opt/conda/envs/${CONDA_ENV} | ||
ENV PATH /opt/conda/envs/${CONDA_ENV}/bin:$PATH | ||
|
||
COPY ./src/fabfos /app/fabfos_src | ||
RUN echo "python -m fabfos_src \$@" >/app/fabfos && chmod +x /app/fabfos | ||
ENV PATH /app:$PATH | ||
ENV PYTHONPATH /app:$PYTHONPATH | ||
|
||
# Singularity uses tini, but raises warnings | ||
# we set it up here correctly for singularity | ||
ENV TINI_VERSION v0.19.0 | ||
ADD https://github.com/krallin/tini/releases/download/${TINI_VERSION}/tini /tini | ||
RUN chmod +x /tini | ||
|
||
## We do some umask munging to avoid having to use chmod later on, | ||
## as it is painfully slow on large directores in Docker. | ||
RUN old_umask=`umask` && \ | ||
umask 0000 && \ | ||
umask $old_umask | ||
|
||
# singularity doesn't use the -s flag, and that causes warnings | ||
ENTRYPOINT ["/tini", "-s", "--"] |
Oops, something went wrong.