File tree Expand file tree Collapse file tree
DOCUMENTATION/content/documentation Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -1121,6 +1121,30 @@ docker-compose up -d grafana
11211121
11221122
11231123
1124+ <br >
1125+ <a name =" Use-Mosquitto " ></a >
1126+ ## Use Mosquitto (MQTT Broker)
1127+
1128+ 1 - Configure Mosquitto: Change Port using ` MOSQUITTO_PORT ` if you wish to. Default is port 9001.
1129+
1130+ 2 - Run the Mosquitto Container (` mosquitto ` ) with the ` docker-compose up ` command:
1131+
1132+ ``` bash
1133+ docker-compose up -d mosquitto
1134+ ```
1135+
1136+ 3 - Open your command line and use a MQTT Client (Eg. https://github.com/mqttjs/MQTT.js ) to subscribe a topic and publish a message.
1137+
1138+ 4 - Subscribe: ` mqtt sub -t 'test' -h localhost -p 9001 -C 'ws' -v `
1139+
1140+ 5 - Publish: ` mqtt pub -t 'test' -h localhost -p 9001 -C 'ws' -m 'Hello!' `
1141+
1142+
1143+
1144+
1145+
1146+
1147+
11241148<br >
11251149<a name =" CodeIgniter " ></a >
11261150
Original file line number Diff line number Diff line change @@ -39,6 +39,8 @@ volumes:
3939 driver : ${VOLUMES_DRIVER}
4040 elasticsearch :
4141 driver : ${VOLUMES_DRIVER}
42+ mosquitto :
43+ driver : ${VOLUMES_DRIVER}
4244
4345services :
4446
@@ -1304,3 +1306,15 @@ services:
13041306 backend :
13051307 aliases :
13061308 - fetchmail
1309+
1310+ # ## MOSQUITTO Broker #########################################
1311+ mosquitto :
1312+ build :
1313+ context : ./mosquitto
1314+ volumes :
1315+ - ${DATA_PATH_HOST}/mosquitto/data:/mosquitto/data
1316+ ports :
1317+ - " ${MOSQUITTO_PORT}:9001"
1318+ networks :
1319+ - frontend
1320+ - backend
Original file line number Diff line number Diff line change @@ -619,3 +619,7 @@ MAILU_ADMIN=true
619619MAILU_WEBMAIL=rainloop
620620# Dav server implementation (value: radicale, none)
621621MAILU_WEBDAV=radicale
622+
623+ ### MOSQUITTO #################################################
624+
625+ MOSQUITTO_PORT=9001
Original file line number Diff line number Diff line change 1+ FROM eclipse-mosquitto:latest
2+
3+ LABEL maintainer="Luis Coutinho <luis@luiscoutinho.pt>"
4+
5+ COPY mosquitto.conf /mosquitto/config/
You can’t perform that action at this time.
0 commit comments