Skip to content

Docker-Compose deployment

The ResIOT team created a single, fully configurable image for ResIOT LoRaWAN Network Server & IoT Platform, the name is resiot/resiot:1000020

note 1: at each reboot the resiot/resiot:1000020 image proceeds with automatic updating to the latest version available
note 2: at the first start, wait a couple of minutes to allow time to perform all the necessary configurations

Docker-Compose Basic Example with LoRaWAN Gateway connected via UDP

In this example we have:

IP of the server to be reached from the outside and from the gateways: 155.156.157.158
Tcp port to access the platform via web: 58089
ResIOT Platform access address is: http://155.156.157.158:58089
Tcp port for Grpc protocol: 58096
Grpc host for gateway connection: 155.156.157.158:58096
Udp port for gateway connection: 57678
persistent volume folders to backup: ./resiotdata , ./rdbdata , ./dbdata
persistent volume for use by ResIOT for automatic updates and files that do not need to be backed up: ./resiotupdfld

remember to open the firewall ports:
58089 TCP
58096 TCP
57678 UDP

contents of docker-compose.yaml file:

version: "3.2"
services:
   dbresiot:
     image: postgres:12.5-alpine
     volumes:
       - ./dbdata:/var/lib/postgresql/data
     restart: always
     environment:
       POSTGRES_USER: resiotdb
       POSTGRES_PASSWORD: yourpasswordtest
       POSTGRES_DB: resiotcore
       PGDATA: /var/lib/postgresql/data/pgdata
   rdb:
     image: redis:5.0.10-alpine
     volumes:
       - ./rdbdata:/data
     restart: always
   mqtt:
     image: eclipse-mosquitto
     restart: always
   resiot:
     depends_on:
       - dbresiot
       - mqtt
       - rdb
     image: resiot/resiot:1000020
     ports:
       - "58089:8088"
       - "58096:8095"
       - "57678:7677/udp"
     volumes:
       - ./resiotupdfld:/run
       - ./resiotdata:/data
     restart: always
     environment:
       NO_LNS: n
       NO_PLA: n
       RESIOT_DB_TYPE: postgres
       RESIOT_DB_URL: postgres://resiotdb:yourpasswordtest@dbresiot:5432/resiotcore?sslmode=disable
       RESIOT_REDIS_URL: redis://rdb:6379
       RESIOT_MQTT_URL: tcp://mqtt:1883
       RESIOT_LORA_BAND: EU_863_870
       RESIOT_LORA_NETID: A0B1B2
       RESIOT_EXTERNAL_ACCESS_UDP_HOST: 155.156.157.158
       RESIOT_EXTERNAL_ACCESS_UDP_PORT: 57678
       RESIOT_EXTERNAL_ACCESS_GRPC_HOST: 155.156.157.158:58096