|
楼主 |
发表于 2023-10-11 08:00:27
|
显示全部楼层
我喜欢用docker-compose:
version: '3'
services:
esphome:
container_name: esphome
image: esphome/esphome:2023.9.3
volumes:
- /root/esphome/config:/config
- /etc/localtime:/etc/localtime:ro
devices:
- "/dev/ttyUSB0:/dev/ttyUSB0"
restart: always
privileged: true
network_mode: host
emqx:
container_name: emqx
image: emqx/emqx:5.3.0
restart: unless-stopped
privileged: true
volumes:
- /root/emqx/data:/opt/emqx/data
- /root/emqx/log:/opt/emqx/log
network_mode: host
environment:
- TZ=Asia/Shanghai
frigate:
container_name: frigate
privileged: true # this may not be necessary for all setups
restart: unless-stopped
image: ghcr.io/blakeblackshear/frigate:0.12.1
shm_size: "512mb" # update for your cameras based on calculation above
environment:
- TZ=Asia/Shanghai
network_mode: host
devices:
- /dev/bus/usb:/dev/bus/usb # passes the USB Coral, needs to be modified for other versions
# - /dev/apex_0:/dev/apex_0 # passes a PCIe Coral, follow driver instructions here https://coral.ai/docs/m2/get-started/#2a-on-linux
- /dev/dri/renderD128 # for intel hwaccel, needs to be updated for your hardware
volumes:
- /etc/localtime:/etc/localtime:ro
- /root/frigate/config/config.yml:/config/config.yml
- /root/frigate/media:/media/frigate
- /root/frigate/config:/db
- type: tmpfs # Optional: 1GB of memory, reduces SSD/SD Card wear
target: /tmp/cache
tmpfs:
size: 1000000000
# ports:
# - "5000:5000"
# - "8554:8554" # RTSP feeds
# - "8555:8555/tcp" # WebRTC over tcp
# - "8555:8555/udp" # WebRTC over udp
environment:
FRIGATE_RTSP_PASSWORD: "password"
node-red:
container_name: node-red
image: nodered/node-red:3.1.0
environment:
- TZ=Asia/Shanghai
# ports:
# - "1880:1880"
network_mode: host
volumes:
- /root/nodered/data:/data
restart: unless-stopped
zigbee2mqtt:
container_name: zigbee2mqtt
image: koenkk/zigbee2mqtt:1.33.0
restart: unless-stopped
privileged: true
volumes:
- /root/zigbee2mqtt/data:/app/data
- /run/udev:/run/udev:ro
ports:
# Frontend port
- 8080:8080
environment:
- TZ=Asia/Shanghai
# devices:
# Make sure this matched your adapter location
# - /dev/serial/by-id/usb-Texas_Instruments_TI_CC2531_USB_CDC___0X00124B0018ED3DDF-if00:/dev/ttyACM0 |
|