version: "3.7" services: megaqc: image: multiqc/megaqc build: .. volumes: # Share the static files via a volume - static_volume:/app/megaqc/static depends_on: - db environment: - MEGAQC_PRODUCTION=${MEGAQC_PRODUCTION} - MEGAQC_SECRET=${MEGAQC_SECRET} - APP_MODULE=${APP_MODULE} - DB_HOST=${DB_HOST} - DB_PORT=${DB_PORT} - DB_NAME=${DB_NAME} - DB_USER=${DB_USER} - DB_PASS=${DB_PASS} db: image: postgres:latest volumes: - db_volume:/var/lib/postgresql/data/ environment: POSTGRES_HOST_AUTH_METHOD: trust nginx: image: nginx:latest volumes: # Mount the nginx conf - ./nginx.conf:/etc/nginx/nginx.conf:ro # Mount the self-signed certs - ${CRT_PATH}:/etc/nginx/megaqc.crt:ro - ${KEY_PATH}:/etc/nginx/megaqc.key:ro # Mount the static files from MegaQC so we can serve them efficiently - static_volume:/home/app/web/project/static ports: - 80:80 - 443:443 depends_on: - megaqc volumes: static_volume: db_volume: