-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.yml
183 lines (165 loc) · 4.04 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
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
version: '3'
volumes:
srs_web_data:
external: true
srs_open_data:
external: true
srs_ui_repo_data:
external: true
postgis-data:
external:
name: postgis_db_data
traefik-letsencrypt:
services:
reverse-proxy:
image: traefik:v2.4.9
command:
- "--accesslog=true"
- "--log.level=DEBUG"
- "--providers.docker=true"
- "--providers.docker.exposedbydefault=false"
- "--entrypoints.web.address=:80"
- "--entrypoints.websecure.address=:443"
- "--certificatesresolvers.myresolver.acme.httpchallenge=true"
- "--certificatesresolvers.myresolver.acme.httpchallenge.entrypoint=web"
#- "--certificatesresolvers.myresolver.acme.caserver=https://acme-staging-v02.api.letsencrypt.org/directory"
- "--certificatesresolvers.myresolver.acme.email=info@smartroadsense.it"
- "--certificatesresolvers.myresolver.acme.storage=/letsencrypt/acme.json"
ports:
- "80:80"
- "443:443"
volumes:
- "traefik-letsencrypt:/letsencrypt"
- "/var/run/docker.sock:/var/run/docker.sock"
data-access:
image: nginx:1.21-alpine
volumes:
- srs_open_data:/usr/share/nginx/html:ro
labels:
- "traefik.enable=true"
- "traefik.http.routers.data.rule=Host(`data.smartroadsense.it`)"
www-redirect:
image: schmunk42/nginx-redirect:0.6.0
expose:
- "80"
environment:
- "SERVER_REDIRECT=smartroadsense.it"
- "SERVER_REDIRECT_SCHEME=https"
labels:
- "traefik.enable=true"
- "traefik.http.routers.www.rule=Host(`www.smartroadsense.it`)"
web:
container_name: web
build: ./web
depends_on:
- ws
ui:
container_name: ui
build: ./ui
volumes:
- srs_web_data:/target:rw
- srs_ui_repo_data:/repo:rw
tiles:
container_name: tiles
build: ./tiles
env_file: config.env
command: nodemon server.js
volumes:
- ./tiles:/code:ro
depends_on:
- ws
labels:
- "traefik.enable=true"
- "traefik.http.routers.tiles.rule=Host(`tiles.smartroadsense.it`)"
agg-cli:
container_name: agg-cli
build: ./agg/cli
env_file: config.env
volumes:
- srs_open_data:/opendata:rw
- ./data:/data:rw
agg-web:
container_name: agg-web
build: ./agg/web
env_file: config.env
raw-cli:
container_name: raw-cli
build: ./raw/cli
env_file: config.env
volumes:
- ./raw/cli:/code:rw
- ./data:/data:rw
raw-web:
container_name: raw-web
build: ./raw/web
env_file: config.env
export:
container_name: export
build: ./export
env_file: config.env
volumes: ['./data:/data:rw']
data-api:
container_name: data-api
build: ./data-api
env_file: config.env
ports:
- "127.0.0.1:5555:5555"
bb:
container_name: bb
build: ./bb
env_file: config.env
ports:
- "127.0.0.1:8080:8080"
ws:
container_name: ws
build: ./ws
env_file: config.env
volumes:
- ./ws:/code/ws:rw
api:
container_name: api
build: ./api
env_file: config.env
volumes:
- ./api:/code/api:rw
map-reduce:
container_name: map-reduce
build: ./jobs/map-reduce
env_file: config.env
volumes:
- ./jobs/map-reduce:/code:ro
meta-updater:
container_name: meta-updater
build: ./jobs/meta-updater/
env_file: config.env
volumes:
- ./jobs/meta-updater:/code:ro
webhookmonitor:
container_name: webhookmonitor
image: lorenzck/webhook-dispatcher:1.1
env_file: config.env
volumes:
- ./webhooks/:/app/hooks/:ro
- /var/run/docker.sock:/var/run/docker.sock:rw
- ./:/code/:ro
db:
image: kartoza/postgis:11.0-2.5
volumes:
- postgis-data:/var/lib/postgresql
environment:
- ALLOW_IP_RANGE=0.0.0.0/0
- POSTGRES_MULTIPLE_EXTENSIONS=postgis,hstore,postgis_topology,ogr_fdw
env_file: config.env
ports:
- 5000:5432
restart: on-failure
healthcheck:
test: "exit 0"
raw-setup-db-cli:
image: smartroadsense/postgres-cli:3.0
volumes:
- ./db-setup:/db-schema
environment:
- PGPORT=5432
- PGHOST=db
env_file: config.env