Hi guys,
My flat mate and I have recently developed an MQTT bridge for unraid, with support for homeassistant autodiscovery, which also features a REST end point. It allows you to control the servers array state, monitor power status, control VM state as well as hotplug USBs to VMs.
Let me know if there are major things missing or wrong. Though this is very early stages still so don’t expect it to be completely flawless. But let me know if it is useful! If you have any problems please join our discord https://discord.gg/Qa3Bjr9
If anyone wants to help us extend it you can check out the source code in a repository by the same user as the docker-templates. (Limited to two links, though we are long time HomeAssistant users we are new to the forums as a poster).
I’m crazy excited to give this a go. I’m just having some trouble getting started and receiving the following error in unraid when adding a socket container:
Pulling image: https://github.com/ElectricBrainUK/docker-templates
**TOTAL DATA PULLED:** 0 B
Command:root@localhost:# /usr/local/emhttp/plugins/dynamix.docker.manager/scripts/docker run -d --name='unraid-api' --net='bridge' --log-opt max-size='50m' --log-opt max-file='1' -e TZ="Australia/Sydney" -e HOST_OS="Unraid" 'https://github.com/ElectricBrainUK/docker-templates'
/usr/bin/docker: invalid reference format: repository name must be lowercase.
See '/usr/bin/docker run --help'.
**The command failed
I’ve also never tried to add my own container so I could be going about it all wrong.
Hey Linton,
Thanks a lot for trying it out! It looks like you’re trying to pull the docker image however that link is to the template repo, the image is available from here: https://hub.docker.com/r/electricbrainuk/unraidapi
However are you trying to add the docker to unraid?
If so what you need to do is paste that link (https://github.com/ElectricBrainUK/docker-templates) in the docker templates section at the bottom of the docker tab in the unraid ui. Then when you click add container it will be listed as an option.
It may be better to chat on our discord if you’re still having issues, the invite is in the first post (would post again but can’t post more than 2 links).
I use glances for that with unraid. take a look at the link above. Install a docker container with glances and add it via the integrations menu with Homeassistant.
Its great because of the docker stats, would be nice to have glances build in, wont be that hard.
You can set it in server mode then let it export to an MQTT server or run in in WEB mode and connect the homeassistant integration to it.
Hey,
So I use glances for the machine stats you are after, cpu usage etc. However for docker and server control (all but parity check but I can always add that) I’d use the unraid API.
To set up glances you simply add a section in your configuration.yaml and for the unraid API if you have an MQTT broker already with autodiscovery you just need to connect it to that.
Ah okay, so in order to set up mqtt you need to install an MQTT broker (there are dockers available for both home assistant and unraid) and connect both home assistant and the unraid API to it.
Warning: store_clean_interval is no longer needed.
Error: Duplicate user value in configuration.
Error found at /config/mosquitto.conf:21.
Error: Unable to open configuration file.
Hey, what is this error from the mqtt broker? It looks like there is something wrong with your config file there is a mosquito.conf.example in the conf.d directory that should show you how to set it up