-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathservices.compose.yml
More file actions
153 lines (137 loc) · 5.81 KB
/
services.compose.yml
File metadata and controls
153 lines (137 loc) · 5.81 KB
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
---
x-database-credentials: &dbEnvironment
PGHOST: ${DATABASE_HOST:-db}
PGUSER: ${DATABASE_USER:-postgres}
PGPASSWORD: ${DATABASE_PASSWORD:?postgres password required}
PGPORT: ${DATABASE_PORT:-5432}
PGDATABASE: ${DATABASE_NAME:-wisdom}
PGSSLMODE: ${DATABASE_SSL_MODE:-disable}
x-minio-credentials: &minioCredentials
MINIO_ENDPOINT: ${MINIO_HOST:-minio}
MINIO_CLIENT_ID: ${MINIO_USER:?minio user required}
MINIO_CLIENT_SECRET: ${MINIO_PASSWORD:?minio password required}
x-database-dependency: &dbDependency
db:
condition: ${DATABASE_REQUIRED_STATE:-service_healthy}
restart: true
required: true
x-extra-hosts: &extraHosts
extra_hosts:
- "host.docker.internal:host-gateway"
services:
authentication:
image: ghcr.io/wisdom-oss/service-user-management:${BACKEND_VERSION:-latest}
restart: unless-stopped
depends_on: *dbDependency
environment:
<<: *dbEnvironment
OIDC_CLIENT_ID: ${OIDC_CLIENT_ID:?oidc client id requried}
OIDC_CLIENT_SECRET: ${OIDC_CLIENT_SECRET:?oidc client secret requried}
OIDC_ISSUER: ${OIDC_ISSUER:?oidc issuer not set}
REDIS_URI: redis://redis:6379/1
labels:
- "traefik.enable=true"
- "traefik.http.routers.authentication.middlewares=authenticationPrefixStrip"
- "traefik.http.routers.authentication.rule=PathPrefix(`/api/auth`)"
- "traefik.http.middlewares.authenticationPrefixStrip.stripprefix.prefixes=/api/auth"
<<: *extraHosts
geodata:
image: ghcr.io/wisdom-oss/service-geo-data-rest:${BACKEND_VERSION:-latest}
restart: unless-stopped
scale: ${SERVICE_REPLICAS:-1}
depends_on: *dbDependency
environment: *dbEnvironment
labels:
- "traefik.enable=true"
- "traefik.http.routers.geodata.middlewares=geodataPrefixStrip"
- "traefik.http.routers.geodata.rule=PathPrefix(`/api/geodata`)"
- "traefik.http.middlewares.geodataPrefixStrip.stripprefix.prefixes=/api/geodata"
consumers:
image: ghcr.io/wisdom-oss/service-consumers:${BACKEND_VERSION:-latest}
restart: unless-stopped
scale: ${SERVICE_REPLICAS:-1}
depends_on: *dbDependency
environment: *dbEnvironment
labels:
- "traefik.enable=true"
- "traefik.http.routers.consumers.middlewares=consumersPrefixStrip"
- "traefik.http.routers.consumers.rule=PathPrefix(`/api/consumers`)"
- "traefik.http.middlewares.consumersPrefixStrip.stripprefix.prefixes=/api/consumers"
<<: *extraHosts
water-rights:
image: ghcr.io/wisdom-oss/service-water-rights:${BACKEND_VERSION:-latest}
restart: unless-stopped
scale: ${SERVICE_REPLICAS:-1}
depends_on: *dbDependency
environment: *dbEnvironment
labels:
- "traefik.enable=true"
- "traefik.http.routers.waterRights.middlewares=waterRightsPrefixStrip"
- "traefik.http.routers.waterRights.rule=PathPrefix(`/api/water-rights`)"
- "traefik.http.middlewares.waterRightsPrefixStrip.stripprefix.prefixes=/api/water-rights"
<<: *extraHosts
usage-forecasts:
image: ghcr.io/wisdom-oss/service-usage-forecasts:${BACKEND_VERSION:-latest}
restart: unless-stopped
scale: ${SERVICE_REPLICAS:-1}
depends_on: *dbDependency
environment: *dbEnvironment
labels:
- "traefik.enable=true"
- "traefik.http.routers.usageForecasts.middlewares=usageForecastsPrefixStrip"
- "traefik.http.routers.usageForecasts.rule=PathPrefix(`/api/water-usage-forecasts`)"
- "traefik.http.middlewares.usageForecastsPrefixStrip.stripprefix.prefixes=/api/water-usage-forecasts"
<<: *extraHosts
usage-history:
image: ghcr.io/wisdom-oss/service-water-usage-history:${BACKEND_VERSION:-latest}
restart: unless-stopped
scale: ${SERVICE_REPLICAS:-1}
depends_on: *dbDependency
environment: *dbEnvironment
labels:
- "traefik.enable=true"
- "traefik.http.routers.usageHistory.middlewares=usageHistoryPrefixStrip"
- "traefik.http.routers.usageHistory.rule=PathPrefix(`/api/water-usage-history`)"
- "traefik.http.middlewares.usageHistoryPrefixStrip.stripprefix.prefixes=/api/water-usage-history"
<<: *extraHosts
groundwater-levels:
image: ghcr.io/wisdom-oss/service-groundwater-levels:${BACKEND_VERSION:-latest}
restart: unless-stopped
scale: ${SERVICE_REPLICAS:-1}
depends_on: *dbDependency
environment: *dbEnvironment
labels:
- "traefik.enable=true"
- "traefik.http.routers.groundwaterLevels.middlewares=groundwaterLevelsPrefixStrip"
- "traefik.http.routers.groundwaterLevels.rule=PathPrefix(`/api/groundwater-levels`)"
- "traefik.http.middlewares.groundwaterLevelsPrefixStrip.stripprefix.prefixes=/api/groundwater-levels"
<<: *extraHosts
dwd-proxy:
image: ghcr.io/wisdom-oss/service-dwd-proxy:${BACKEND_VERSION:-latest}
restart: unless-stopped
scale: ${SERVICE_REPLICAS:-1}
environment:
REDIS_URI: redis://redis:6379
labels:
- "traefik.enable=true"
- "traefik.http.routers.dwdProxy.middlewares=dwdProxyPrefixStrip"
- "traefik.http.routers.dwdProxy.rule=PathPrefix(`/api/dwd`)"
- "traefik.http.middlewares.dwdProxyPrefixStrip.stripprefix.prefixes=/api/dwd"
smartmeters:
image: ghcr.io/wisdom-oss/service-smartmeter-rest:${BACKEND_VERSION:-latest}
restart: unless-stopped
scale: ${SERVICE_REPLICAS:-1}
depends_on: *dbDependency
environment: *dbEnvironment
labels:
- "traefik.enable=true"
- "traefik.http.routers.smartmeter.middlewares=smartmeterPrefixStrip"
- "traefik.http.routers.smartmeter.rule=PathPrefix(`/api/smartmeter`)"
- "traefik.http.middlewares.smartmeterPrefixStrip.stripprefix.prefixes=/api/smartmeter"
<<: *extraHosts
static-files:
image: ghcr.io/wisdom-oss/service-static-files:${BACKEND_VERSION:-latest}
restart: unless-stopped
scale: ${SERVICE_REPLICAS:-1}
environment: *minioCredentials
...