-
Notifications
You must be signed in to change notification settings - Fork 2
/
Dockerfile
27 lines (23 loc) · 941 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
ARG VERSION=3.8
FROM python:${VERSION}-bookworm
COPY requirements.txt requirements-dev.txt /tmp/
# when testing a new version of the github datatrails-python repo copy the wheel
# (generated by 'task wheel') from that repo and uncomment
# the following lines. Also comment out the datatrails-archivist line in
# requirements.txt.
# cp ~/git/datatrails-python/dist/*.whl .
# That way one can test an unreleased version of github datatrails-samples.
# NB dont forget to recomment before merging !!
# COPY datatrails*.whl /tmp/
# RUN python3 -m pip -qq install /tmp/datatrails*.whl \
# && rm -f /tmp/datatrails*.whl
RUN python3 -m pip -qq install --upgrade pip \
&& python3 -m pip -qq install -r /tmp/requirements-dev.txt \
&& rm -f /tmp/requirements-dev.txt \
&& rm -f /tmp/requirements.txt
ENV USER=api
ENV HOME=/home/${USER}
RUN mkdir -p ${HOME}
ENV PYTHONPATH=${HOME}/samples
ENV PATH=${HOME}/.local/bin:${PATH}
WORKDIR ${HOME}