1 Mosquitto
Matt Cupp edited this page 2026-05-29 17:35:45 -04:00

Mosquitto

MQTT message broker. Handles pub/sub messaging between Frigate (camera NVR) and Home Assistant — Frigate publishes detection events; Home Assistant subscribes to them.

Where it runs

  • Host: Nexus (192.168.1.226)
  • Port: 1883 (MQTT), 9001 (WebSockets)
  • No web UI — MQTT protocol only
  • Managed by: Komodo (server nexus, Stack mosquitto)
  • Compose file: mosquitto/docker-compose.yml in homelab-docker repo

Docker

Nexus runs Docker via snap. Always use docker compose (with a space).

Configuration

Config, data, and logs are bind-mounted from Nexus:

Mount Host path
Config /mnt/server/containers/mosquitto/config
Data /mnt/server/containers/mosquitto/data
Logs /mnt/server/containers/mosquitto/log

The broker config lives at /mnt/server/containers/mosquitto/config/mosquitto.conf. Edit it on Nexus and restart the container for changes to take effect.

Integrations

Publisher Subscriber Topic pattern
Frigate Home Assistant frigate/#

Frigate's mqtt: block in its config points to 192.168.1.226:1883. Home Assistant's MQTT integration is configured under Settings → Devices & Services → MQTT with broker 192.168.1.226, port 1883.

Renovate Note

Image is pinned to eclipse-mosquitto:2 (major-version tag). Renovate will open PRs for minor and patch updates within the 2.x line automatically.

Troubleshooting

# Container logs
ssh matt@192.168.1.226 'docker logs mosquitto --tail 50'

# Test connectivity from any machine with mosquitto-clients installed
mosquitto_pub -h 192.168.1.226 -t test -m hello
mosquitto_sub -h 192.168.1.226 -t test

# Restart the container
ssh matt@192.168.1.226 'docker compose -f /mnt/server/containers/mosquitto/docker-compose.yml restart'

If Home Assistant loses MQTT and shows devices as unavailable, check that Mosquitto is running first, then reload the MQTT integration in HA: Settings → Devices & Services → MQTT → (three dots) → Reload.