This repository has been archived by the owner on Mar 21, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
106 lines (99 loc) · 2.09 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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
version: '3.4'
volumes:
db_data:
db_wal:
services:
database:
image: timescale/timescaledb-postgis:1.4.2-pg11
ports:
- 5432
environment:
- POSTGRES_DB=boten
- POSTGRES_USER=boten
- POSTGRES_PASSWORD=insecure
- PGDATA=/data
- POSTGRES_INITDB_WALDIR=/wal
volumes:
- db_data:/data
- db_wal:/wal
app:
build:
context: .
target: app
image: docker-registry.data.amsterdam.nl/datapunt/waarnemingen-boten:${VERSION:-latest}
ports:
- 8000:8000
environment:
- SECRET_KEY
volumes:
- ./src:/src
- ./deploy:/deploy
depends_on:
- database
dev:
build:
context: .
target: dev
ports:
- 8000:8000
environment:
- DEBUG=true
- SECRET_KEY=dev
- PYTHONBREAKPOINT
volumes:
- ./src:/src
- ./deploy:/deploy
depends_on:
- database
entrypoint: /deploy/wait-for-it.sh database:5432 --
command: python manage.py runserver 0.0.0.0:8000
test:
build:
context: .
target: tests
volumes:
- ./src:/src
- ./tests:/tests
- ./deploy:/deploy
environment:
- SECRET_KEY=tests
- DJANGO_SETTINGS_MODULE=config.settings
- LOG_LEVEL=ERROR
- PYTEST_ADDOPTS
depends_on:
- database
entrypoint: /deploy/wait-for-it.sh database:5432 --
import_waternet:
build:
context: .
target: dev
ports:
- 8000:8000
environment:
- DEBUG=true
- SECRET_KEY=dev
volumes:
- ./src:/src
- ./deploy:/deploy
depends_on:
- database
entrypoint: /deploy/wait-for-it.sh database:5432 --
command: python manage.py import_waternet
scrape_waternet:
build:
context: .
target: dev
ports:
- 8000:8000
environment:
- DEBUG=true
- SECRET_KEY=dev
- WATERNET_USERNAME
- WATERNET_PASSWORD
volumes:
- ./src:/src
- ./deploy:/deploy
depends_on:
- database
entrypoint: /deploy/wait-for-it.sh database:5432 --
command: python manage.py scrape_waternet