-
Notifications
You must be signed in to change notification settings - Fork 0
/
agent.json.yml
68 lines (62 loc) · 1.89 KB
/
agent.json.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
version: "3.5"
volumes:
mongodb: ~
services:
################
# Applications #
################
# MQTT Broker for IOT Agent
mosquitto:
image: eclipse-mosquitto:latest
container_name: mosquitto
ports:
- "1883:1883"
- "9001:9001" # Optional: for WebSocket support
restart: always
volumes:
- ./mosquitto:/mosquitto
#JSON IOT Agent that supports HTTP, MQTT and AMQP
iot-agent:
image: quay.io/fiware/iotagent-json:3.1.0-distroless
hostname: iot-agent
container_name: fiware-iot-agent
depends_on:
- mongodb
- mosquitto
expose:
- "4041"
- "7896"
ports:
- "4041:4041"
- "7896:7896"
environment:
- "IOTA_CB_URL=${CONTEXT_BROKER_URL}"
- "IOTA_NORTH_PORT=4041"
- "IOTA_REGISTRY_TYPE=mongodb"
- "IOTA_MONGO_HOST=mongodb"
- "IOTA_MONGO_PORT=27017"
- "IOTA_MONGO_DB=iotagent-json"
- "IOTA_HTTP_PORT=7896"
- "IOTA_PROVIDER_URL=${IOT_AGENT_URL}"
- "IOTA_CB_NGSI_VERSION=ld" # To work with NGSI-LD brokers
- "IOTA_FALLBACK_TENANT=openiot"
- "IOTA_FALLBACK_PATH=/"
- "IOTA_MQTT_HOST=mosquitto" # MQTT broker service
- "IOTA_MQTT_PORT=1883" # MQTT service port
- "IOTA_JSON_LD_CONTEXT=${CONTEXT_FILE}"
- "IOTA_TIMESTAMP=true" # Supply timestamp information with each measurement
- "IOTA_AUTOCAST=true" # Ensure number values are read as numbers not strings
- "IOTA_LOG_LEVEL=DEBUG"
#############
# Databases #
#############
# Storage for IOT agent
mongodb:
image: mongo:4.2
hostname: mongodb
container_name: db-mongo
ports:
- "27017:27017"
command: --bind_ip_all
volumes:
- mongodb:/data