File tree Expand file tree Collapse file tree 1 file changed +19
-1
lines changed
Expand file tree Collapse file tree 1 file changed +19
-1
lines changed Original file line number Diff line number Diff line change @@ -35,6 +35,20 @@ services:
3535 healthcheck :
3636 test : (wget --server-response --spider --quiet http://context/user-context.jsonld 2>&1 | awk 'NR==1{print $$2}'| grep -q -e "200") || exit 1
3737
38+ redis-sensors :
39+ labels :
40+ org.fiware : ' tutorial'
41+ image : redis:8.2.0-alpine
42+ container_name : redis
43+ hostname : redis-for-sensors
44+ ports :
45+ - " 6378:6379"
46+ volumes :
47+ - redis-data:/data
48+ healthcheck :
49+ test : ["CMD", "redis-cli","ping"]
50+ interval : 10s
51+
3852 # Databases
3953 mongo-db :
4054 labels :
@@ -119,6 +133,8 @@ services:
119133 image : quay.io/fiware/tutorials.iot-devices
120134 hostname : iot-sensors
121135 container_name : fiware-iot-devices
136+ depends_on :
137+ - redis-sensors
122138 networks :
123139 - default
124140 expose :
@@ -133,7 +149,8 @@ services:
133149 - IOTA_HTTP_PORT=${IOTA_SOUTH_PORT}
134150 - PIG_COUNT=${PIG_COUNT}
135151 - COW_COUNT=${COW_COUNT}
136-
152+ - REDIS_HOST=redis-for-sensors
153+
137154 # Tutorial acts as a Farm Management Information System
138155 tutorial :
139156 labels :
@@ -245,6 +262,7 @@ volumes:
245262 grafana : ~
246263 mongo-db : ~
247264 mongo-config : ~
265+ redis-data : ~
248266 data-models :
249267 driver : local
250268 driver_opts :
You can’t perform that action at this time.
0 commit comments