-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yaml
64 lines (60 loc) · 1.79 KB
/
docker-compose.yaml
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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
version: "3.7"
services:
app:
build: .
depends_on:
- redis
volumes:
- "${DOCKER_INPUT_PATH}:/volumes/input:ro"
- "${DOCKER_OUTPUT_PATH}:/volumes/output"
- "${DOCKER_TMP_PATH}:/volumes/tmp"
environment:
FLASK_APP: isimip_files_api.app
FLASK_CONFIG: config.toml
FLASK_BASE_URL: "http://${DOCKER_HOSTNAME}:${DOCKER_PORT}/api/v2"
FLASK_OUTPUT_URL: "http://${DOCKER_HOSTNAME}:${DOCKER_PORT}/api/output"
FLASK_REDIS_URL: redis://redis:6379
FLASK_INPUT_PATH: /volumes/input
FLASK_OUTPUT_PATH: /volumes/output
FLASK_TMP_PATH: /volumes/tmp
env_file: .env
worker:
build: .
command: rq worker
depends_on:
- redis
volumes:
- "${DOCKER_INPUT_PATH}:/volumes/input:ro"
- "${DOCKER_OUTPUT_PATH}:/volumes/output"
- "${DOCKER_TMP_PATH}:/volumes/tmp"
environment:
FLASK_APP: isimip_files_api.app
FLASK_CONFIG: config.toml
FLASK_BASE_URL: "http://${DOCKER_HOSTNAME}:${DOCKER_PORT}/api/v2"
FLASK_OUTPUT_URL: "http://${DOCKER_HOSTNAME}:${DOCKER_PORT}/api/output"
FLASK_REDIS_URL: redis://redis:6379
FLASK_INPUT_PATH: /volumes/input
FLASK_OUTPUT_PATH: /volumes/output
FLASK_TMP_PATH: /volumes/tmp
RQ_REDIS_URL: redis://redis:6379
RQ_WORKER_CLASS: isimip_files_api.worker.Worker
env_file: .env
caddy:
image: caddy
restart: unless-stopped
cap_add:
- NET_ADMIN
ports:
- "${DOCKER_PORT}:80"
volumes:
- "${DOCKER_OUTPUT_PATH}:/volumes/output"
- "$PWD/Caddyfile:/etc/caddy/Caddyfile"
- "${DOCKER_CADDY_PATH}/data:/data"
- "${DOCKER_CADDY_PATH}/config:/config"
redis:
image: redis
command: redis-server --appendonly yes
restart: always
volumes:
- "${DOCKER_REDIS_PATH}:/data"
env_file: .env