-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile-old
44 lines (28 loc) · 962 Bytes
/
Dockerfile-old
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
FROM --platform=linux/amd64 python:3.9.7 as build
ARG DEBIAN_FRONTEND=noninteractive
# Configure Poetry
ENV POETRY_VERSION=1.3.2
ENV POETRY_HOME=/app/poetry
ENV POETRY_VENV=/app/poetry-venv
ENV POETRY_CACHE_DIR=/app/.cache
# Install poetry separated from system interpreter
RUN python3 -m venv $POETRY_VENV \
&& $POETRY_VENV/bin/pip install -U pip setuptools \
&& $POETRY_VENV/bin/pip install poetry==${POETRY_VERSION}
# Add `poetry` to PATH
ENV PATH="${PATH}:${POETRY_VENV}/bin"
WORKDIR /app
# Copy Dependencies
COPY poetry.lock pyproject.toml ./
RUN /bin/bash -c 'source $POETRY_VENV/bin/activate && \
poetry install'
FROM --platform=linux/amd64 python:3.9.7 as runtime
# Configure Poetry
# ENV POETRY_VERSION=1.3.2
# ENV POETRY_VENV=/app/poetry-venv
WORKDIR /app
#COPY --from=indexing_environment $POETRY_VENV $POETRY_VENV
COPY --from=build /app .
COPY . ES-Services
EXPOSE 7000
ENTRYPOINT ["/app/ES-Services/docker-run-entrypoints.sh"]