-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
48 lines (39 loc) · 1.3 KB
/
Dockerfile
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
39
40
41
42
43
44
45
46
47
48
FROM ubuntu:20.04
MAINTAINER Spashev Nurken
ENV LANG C.UTF-8
ENV LC_ALL C.UTF-8
ENV PYTHONFAULTHANDLER 1
ENV PYTHONBUFFERED 1
ENV PIP_DISABLE_PIP_VERSION_CHECK 1
ENV PYTHONDONTWRITEBYTECODE 1
ENV PYTHONUNBUFFERED 1
# Add alpine mirrors
RUN apt-get update \
&& apt-get install -y software-properties-common \
&& add-apt-repository ppa:deadsnakes/ppa \
&& apt-get update \
&& apt-get install -y tzdata \
&& apt-get install -y python3.11 python3-pip \
&& apt-get install -y --no-install-recommends python3-dev \
&& apt-get install -y --no-install-recommends nginx \
&& apt-get install -y --no-install-recommends libpq-dev \
&& apt-get install -y --no-install-recommends apt-utils \
&& apt-get install -y --no-install-recommends libc-dev \
&& apt-get install -y --no-install-recommends gcc \
&& apt-get install -y --no-install-recommends gettext \
&& apt-get install -y --no-install-recommends screen \
&& apt-get clean
# Set python requirements
WORKDIR /code
# Install python dependencies
COPY src/app /code
RUN pip install --upgrade pip
RUN pip install -r requirements.txt \
&& pip install Redis \
&& pip install uvicorn \
&& pip install psycopg2 \
&& pip install flake8 \
&& pip install pytest-django
EXPOSE 8010
COPY docker/start.uvicorn.sh ./
RUN chmod +x ./start.uvicorn.sh