version: '2.2'
services:
mytb:
restart: always
image: "thingsboard/tb-postgres"
ports:
- "8080:9090"
- "1883:1883"
- "5683:5683/udp"
environment:
TB_QUEUE_TYPE: in-memory
volumes:
- mytb-data:/data
- mytb-logs:/var/log/thingsboard
volumes:
mytb-data:
external: true
mytb-logs:
external: true
docker run
docker volume create mytb-data
docker volume create mytb-logs
docker run -d -p 8081:9090 -p 8082:1883 -v mytb-data:/data -v mytb-logs:/var/log/thingsboard thingsboard/tb-postgres
最简单的
docker run -d -p 8080:9090 -p 8081:1883 thingsboard/tb-postgres