before send to remote
This commit is contained in:
28
Dockerfile
Normal file
28
Dockerfile
Normal file
@@ -0,0 +1,28 @@
|
||||
# pull official base image
|
||||
FROM python:3.9.6-alpine
|
||||
|
||||
# set work directory
|
||||
WORKDIR /usr/src/app
|
||||
|
||||
# set environment variables
|
||||
ENV PYTHONDONTWRITEBYTECODE 1
|
||||
ENV PYTHONUNBUFFERED 1
|
||||
|
||||
# install psycopg2 dependencies
|
||||
RUN apk update && apk add postgresql-dev gcc python3-dev musl-dev
|
||||
|
||||
# install dependencies
|
||||
RUN pip install --upgrade pip
|
||||
COPY ./requirements.txt .
|
||||
RUN pip install -r requirements.txt
|
||||
|
||||
# copy entrypoint.sh
|
||||
COPY ./entrypoint.sh .
|
||||
RUN sed -i 's/\r$//g' /usr/src/app/entrypoint.sh
|
||||
RUN chmod +x /usr/src/app/entrypoint.sh
|
||||
|
||||
# copy project
|
||||
COPY . .
|
||||
|
||||
# run entrypoint.sh
|
||||
ENTRYPOINT ["/usr/src/app/entrypoint.sh"]
|
Reference in New Issue
Block a user