2024-03-08 09:05:24 +00:00
|
|
|
FROM python:3.9-bullseye AS base
|
2021-02-17 13:06:07 +00:00
|
|
|
ENV PYTHONUNBUFFERED=1
|
2024-03-03 10:44:43 +00:00
|
|
|
RUN pip install poetry
|
2024-03-08 07:15:49 +00:00
|
|
|
WORKDIR /code
|
2024-03-08 09:05:24 +00:00
|
|
|
RUN apt-get update && apt-get install -y --no-install-recommends gettext-base libpq-dev graphviz
|
2024-03-08 07:15:49 +00:00
|
|
|
COPY pyproject.toml poetry.lock /code/
|
2024-03-03 10:44:43 +00:00
|
|
|
RUN poetry install --with dev --extras "postgresql"
|
2021-02-17 13:06:07 +00:00
|
|
|
COPY . /code/
|
2024-03-08 09:05:24 +00:00
|
|
|
CMD ./docker/docker-entrypoint.sh
|
|
|
|
|
|
|
|
FROM base AS ldap
|
|
|
|
ENV DEBIAN_FRONTEND=noninteractive
|
|
|
|
RUN apt-get install -y --no-install-recommends libldap-dev slapd libsasl2-dev
|
|
|
|
|
|
|
|
FROM base AS mysql
|
|
|
|
RUN poetry install --with dev --extras "mysql"
|
|
|
|
|
|
|
|
FROM base AS postgres
|
|
|
|
RUN poetry install --with dev --extras "postgresql"
|
|
|
|
|
|
|
|
FROM ldap AS mysql-ldap
|
|
|
|
RUN poetry install --with dev --extras "mysql ldap"
|
|
|
|
|
|
|
|
FROM ldap AS postgres-ldap
|
|
|
|
RUN poetry install --with dev --extras "postgresql ldap"
|