forked from MultiQC/MegaQC
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
31 lines (27 loc) · 871 Bytes
/
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
# Compile the JS in an isolated container
FROM node:16
COPY . /app
WORKDIR /app
RUN npm install
RUN npm run build
# Setup the final container that will we run
FROM tiangolo/meinheld-gunicorn-flask:python3.8
LABEL authors="phil.ewels@scilifelab.se,denis.moreno@scilifelab.se" \
description="Docker image running MegaQC with Gunicorn"
# Tell MegaQC to use postgres / psycopg2
ENV MEGAQC_PRODUCTION=1 \
MEGAQC_SECRET="SuperSecretValueYouShouldReallyChange" \
MEGAQC_CONFIG="" \
APP_MODULE=megaqc.wsgi:app\
DB_HOST="127.0.0.1" \
DB_PORT="5432" \
DB_NAME="megaqc" \
DB_USER="megaqc" \
DB_PASS="megaqcpswd"
COPY . /app
# Patch in a custom start script
COPY ./start.sh /start.sh
RUN chmod +x /start.sh
# Copy the compiled JS in from the other node container
COPY --from=0 /app/megaqc/static/ /app/megaqc/static/
RUN pip install /app[prod]