Revert "Revert "Merge branch 'Docker' into master""

This reverts commit a955e9f564.
This commit is contained in:
2022-08-02 09:44:25 +02:00
parent b89cbc8484
commit 8653166154
9 changed files with 159 additions and 19 deletions

24
Dockerfile Normal file
View File

@@ -0,0 +1,24 @@
FROM python:3.9-slim
ENV PYTHONUNBUFFERED 1
WORKDIR /konova
# Install some dependencies
RUN apt update
RUN apt install -y gdal-bin redis-server nginx
# Copy requirements file into workspace and install all dependencies
COPY ./requirements.txt /konova/
RUN pip install --upgrade pip
RUN pip install -r requirements.txt
# Remove nginx default configuration and replace with own configuration
RUN rm /etc/nginx/sites-enabled/default
COPY ./nginx.conf /etc/nginx/conf.d
# Copy rest of project into workspace
COPY . /konova/
# Move static files in designated folder
RUN python manage.py collectstatic --noinput