Installation Guide
How-To
Here’s an example of a default installation of zigbee2mqtt. Pay particular attention to the section “Configure Mount USB Devices” to configure the USB adapter to your container as those two paths should match.
Deployment Configuration
Set ZIGBEE2MQTT_CONFIG_MQTT_USER
, ZIGBEE2MQTT_CONFIG_MQTT_PASSWORD
if necessary, as this will override the specific value of config file. Leave empty if you plan to use custom config or you don’t have set a user on your MQTT broker.
For MQTT Server
Internal DNS Cluster IP can be used (default) of mqtt://mosquitto.mosquitto.svc.cluster.local
or you can use the external IP.
workload: main: podSpec: containers: main: env: USE_CUSTOM_CONFIG_FILE: false # This values are required for the autogenerated file to work. # ZIGBEE2MQTT_CONFIG_PERMIT_JOIN: false ZIGBEE2MQTT_CONFIG_MQTT_SERVER: "mqtt://mosquitto.mosquitto.svc.cluster.local" ZIGBEE2MQTT_CONFIG_MQTT_BASE_TOPIC: "zigbee2mqtt" ZIGBEE2MQTT_CONFIG_SERIAL_PORT: "/dev/ttyUSB0" ZIGBEE2MQTT_CONFIG_SERIAL_ADAPTER: "auto" ZIGBEE2MQTT_CONFIG_MQTT_USER: "mqtt_user" ZIGBEE2MQTT_CONFIG_MQTT_PASSWORD: "secretpassword"
Mount USB Devices
- Passthrough your USB device to your cluster node.
- Add a persistence configuration for your USB device
- Best practice is to do by ID as per below, in this example we use
/dev/serial/by-id/usb-ithead_SONOFF
persistence: zigbee: enabled: true type: device hostPath: /dev/serial/by-id/usb-ithead_SONOFF