-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathContainerfile
More file actions
36 lines (29 loc) · 831 Bytes
/
Copy pathContainerfile
File metadata and controls
36 lines (29 loc) · 831 Bytes
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
FROM docker.io/python:3.11-slim-bullseye
# set environment variables
ENV PIP_DISABLE_PIP_VERSION_CHECK=1
ENV PYTHONDONTWRITEBYTECODE=1
ENV PYTHONUNBUFFERED=1
# create directories
RUN mkdir -p /app/keeper
RUN mkdir /app/private-media
RUN mkdir /app/postgres_data
WORKDIR /app/keeper
# install system dependencies
RUN apt-get update && apt-get install -y \
git \
python3-dev \
build-essential \
libpq-dev \
netcat \
libmagic-dev
# install python dependencies
COPY requirements/ /app/keeper/requirements/
RUN pip install --upgrade pip && pip install -r requirements/dev.txt --use-pep517
# copy entrypoint.sh
COPY ./entrypoint.sh .
RUN sed -i 's/\r$//g' /app/keeper/entrypoint.sh
RUN chmod +x /app/keeper/entrypoint.sh
# copy project
COPY . .
# run entrypoint.sh
ENTRYPOINT ["/app/keeper/entrypoint.sh"]