From c008c037facaf632dc9923bb2ecd4c9542c14c9d Mon Sep 17 00:00:00 2001 From: clarkzjw Date: Wed, 10 Jan 2018 20:45:07 +0800 Subject: + add Dockerfile --- Dockerfile | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) (limited to 'Dockerfile') diff --git a/Dockerfile b/Dockerfile index 49de25f..985f527 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,22 @@ -FROM python:3.6.0 +FROM python:3.6.0 as builder +LABEL maintainer=clarkzjw +RUN pip install virtualenv -FROM nginx +COPY requirements.txt /app/requirements.txt +COPY bootstrap.py /app/bootstrap.py + +RUN /app/bootstrap.py + +ADD . /app + +WORKDIR /app + +RUN /bin/bash -c "source /app/.venv/bin/activate && make html" + + +FROM nginx:alpine + +COPY --from=builder /app/_build/html /usr/share/nginx/html -- cgit v1.2.3