| 1 |
FROM python:3.12-slim-bookworm |
| 2 |
|
| 3 |
ENV PYTHONUNBUFFERED 1 |
| 4 |
ENV PYTHONDONTWRITEBYTECODE 1 |
| 5 |
|
| 6 |
RUN apt-get update \ |
| 7 |
# dependencies for building Python packages |
| 8 |
&& apt-get install -y build-essential \ |
| 9 |
&& apt-get install -y texlive \ |
| 10 |
&& apt-get install -y texlive-latex-extra \ |
| 11 |
&& apt-get install -y dvipng \ |
| 12 |
&& apt-get install -y python3-sphinx \ |
| 13 |
# Translations dependencies |
| 14 |
&& apt-get install -y gettext \ |
| 15 |
# cleaning up unused files |
| 16 |
&& apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false \ |
| 17 |
&& rm -rf /var/lib/apt/lists/* |
| 18 |
|
| 19 |
# # Requirements are installed here to ensure they will be cached. |
| 20 |
COPY /requirements /requirements |
| 21 |
|
| 22 |
# All imports needed for autodoc. |
| 23 |
RUN pip install -r /requirements/docs.txt -r /requirements/default.txt |
| 24 |
|
| 25 |
COPY . /celery |
| 26 |
|
| 27 |
RUN pip install /celery |
| 28 |
|
| 29 |
COPY docker/docs/start /start-docs |
| 30 |
RUN sed -i 's/\r$//g' /start-docs |
| 31 |
RUN chmod +x /start-docs |
| 32 |
|
| 33 |
WORKDIR /docs |