forked from HeroCTF/deploy-dynamic
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
43 lines (39 loc) · 1.13 KB
/
docker-compose.yml
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
32
33
34
35
36
37
38
39
40
41
42
43
---
version: "3.3"
services:
nginx:
image: nginx:stable-alpine
restart: always
volumes:
- ./nginx/nginx.conf:/etc/nginx/nginx.conf
- ./nginx/certs/:/etc/nginx/certs/
ports:
- 443:443
depends_on:
- app
app:
build: .
restart: always
volumes:
- ./app:/app/app
- ./app.py:/app/app.py
- ./config.json:/app/config.json
- /var/run/docker.sock:/var/run/docker.sock
depends_on:
- postgres
environment:
DEBUG: ${DEBUG}
ADMIN_ONLY: ${ADMIN_ONLY}
DATABASE_URI: postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@postgres/${POSTGRES_DB}
ENABLE_RECAPTCHA: ${ENABLE_RECAPTCHA}
RECAPTCHA_SITE_KEY: ${RECAPTCHA_SITE_KEY}
RECAPTCHA_SECRET_KEY: ${RECAPTCHA_SECRET_KEY}
postgres:
image: postgres:14
restart: always
volumes:
- ./data:/var/lib/postgresql/data
environment:
POSTGRES_USER: ${POSTGRES_USER:?Please provide a PostgreSQL username}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:?Please provide a PostgreSQL password.}
POSTGRES_DB: ${POSTGRES_DB:?Please provide a PostgreSQL database name.}