forked from openwrt/asu
-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.yml
40 lines (37 loc) · 888 Bytes
/
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
version: "3.5"
services:
db:
image: postgres
restart: always
environment:
POSTGRES_PASSWORD: changeme
POSTGRES_DB: asu
POSTGRES_USER: asu
volumes:
- "./asu/utils/tables.sql:/docker-entrypoint-initdb.d/tables.sql"
server:
build: .
environment:
- FLASK_APP=asu
- LC_ALL=C.UTF-8
- LANG=C.UTF-8
command: sh -c 'sh .wait-for db:5432 -- flask loaddb && gunicorn3 -b 0.0.0.0:8000 asu:app'
volumes:
- "./config.yml:/asu/config.yml"
ports:
- 8000
depends_on:
- db
worker:
build: .
environment:
- FLASK_APP=asu
- LC_ALL=C.UTF-8
- LANG=C.UTF-8
command: sh -c 'sh .wait-for server:8000 -t 300 -- flask run-worker'
volumes:
- "./config.yml:/asu/config.yml"
- "./worker/:/asu/worker/"
- "./updater/:/asu/updater/"
depends_on:
- db