-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
38 lines (24 loc) · 696 Bytes
/
Copy pathDockerfile
File metadata and controls
38 lines (24 loc) · 696 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
37
38
# FROM python:3.9
# ENV PYTHONDONTWRITEBYTECODE 1
# ENV PYTHONUNBUFFERED 1
# WORKDIR /app
# COPY requirements.txt .
# RUN pip install --upgrade pip
# RUN pip3 install -r requirements.txt
# COPY . /app/
# RUN python manage.py makemigrations
# RUN python manage.py migrate
# EXPOSE 8000
# CMD ["python", "manage.py", "runserver", "0.0.0.0:8000"]
FROM python:3.11.4-slim-bullseye
WORKDIR /app
ENV PYTHONUNBUFFERED 1
ENV PYTHONDONTWRITEBYTECODE 1
# install system dependencies
RUN apt-get update
# install dependencies
RUN pip install --upgrade pip
COPY ./requirements.txt /app/
RUN pip install -r requirements.txt
COPY . /app
ENTRYPOINT [ "gunicorn", "core.wsgi", "-b", "0.0.0.0:8000"]