-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile-workflow-py
30 lines (23 loc) · 1.11 KB
/
Dockerfile-workflow-py
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
# docker build -t gcr.io/clingen-dev/clinvar-ingest-workflow-py:latest -f Dockerfile-workflow-py .
# gcloud run jobs execute clinvar-ingest-workflow-py --region us-central1 --update-env-vars='directory=/pub/clinvar/xml/VCV_xml_old_format,host=https://ftp.ncbi.nlm.nih.gov/,last_modified=2024-01-07T15:47:16,name=ClinVarVariationRelease_2024-02.xml.gz,release_date=2024-02-01,released=2024-02-01T15:47:16,size=3298023159'
# Build Image
FROM python:3.11-slim-bullseye as build
ENV VIRTUAL_ENV=/opt/venv
RUN python3 -m venv $VIRTUAL_ENV
ENV PATH="$VIRTUAL_ENV/bin:$PATH"
WORKDIR /app
COPY ./clinvar_ingest ./clinvar_ingest
COPY pyproject.toml .
RUN python -m pip install .
# Runtime Image
FROM python:3.11-slim-bullseye as runtime
RUN apt update && apt install -y curl
COPY --from=build /opt/venv /opt/venv
COPY log_conf.json /app/log_conf.json
COPY misc/bin/workflow.py /app/workflow.py
COPY misc/bin/workflow-copy-only.py /app/workflow-copy-only.py
COPY misc/bin/bq_ingester.py /app/bq_ingester.py
ENV VIRTUAL_ENV=/opt/venv
ENV PATH="$VIRTUAL_ENV/bin:$PATH"
ENV GCLOUD_PROJECT="clingen-dev"
CMD ["python3", "/app/workflow.py"]