mirror of
https://github.com/status-im/spiff-arena.git
synced 2025-01-10 02:05:40 +00:00
89bfc25f35
a195512fd do not install dev dependencies when building docker image w/ burnettk git-subtree-dir: spiffworkflow-backend git-subtree-split: a195512fd94dc57b4b84c5d8fdce40f224650f50
29 lines
704 B
Docker
29 lines
704 B
Docker
FROM ghcr.io/sartography/python:3.11
|
|
|
|
RUN pip install poetry
|
|
RUN useradd _gunicorn --no-create-home --user-group
|
|
|
|
RUN apt-get update && \
|
|
apt-get install -y -q \
|
|
gcc libssl-dev \
|
|
curl git-core libpq-dev \
|
|
gunicorn3 default-mysql-client
|
|
|
|
WORKDIR /app
|
|
COPY pyproject.toml poetry.lock /app/
|
|
RUN poetry install --without dev
|
|
|
|
RUN set -xe \
|
|
&& apt-get remove -y gcc python3-dev libssl-dev \
|
|
&& apt-get autoremove -y \
|
|
&& apt-get clean -y \
|
|
&& rm -rf /var/lib/apt/lists/*
|
|
|
|
COPY . /app/
|
|
|
|
# run poetry install again AFTER copying the app into the image
|
|
# otherwise it does not know what the main app module is
|
|
RUN poetry install --without dev
|
|
|
|
CMD ./bin/boot_server_in_docker
|