From a17c3d71331d6919fc5559de1991af6721a12343 Mon Sep 17 00:00:00 2001 From: msinkec Date: Fri, 23 Oct 2020 12:22:04 +0200 Subject: [PATCH] Added Docker stuff. --- Dockerfile | 9 +++++++++ docker-compose.yml | 9 +++++++++ 2 files changed, 18 insertions(+) create mode 100644 Dockerfile create mode 100644 docker-compose.yml diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..b0fd78d --- /dev/null +++ b/Dockerfile @@ -0,0 +1,9 @@ +FROM python:3.9 + +COPY app.py /usr/src/portal-webapp/ +COPY templates /usr/src/portal-webapp/templates +WORKDIR /usr/src/portal-webapp + +RUN pip install --no-cache-dir flask flask-dropzone gunicorn + +CMD ["gunicorn", "--bind", "0.0.0.0:80", "-w", "1", "--access-logfile", "-", "app:app"] diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..e208cc5 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,9 @@ +version: "3" +services: + webapp: + build: . + restart: always + ports: + - 127.0.0.1:5000:80 + volumes: + - /tmp/uploads/:/usr/src/portal-webapp/uploads