albertogeniola / ha-meross-local-broker

HomeAssistant addon that handles LAN-local MQTT and API service for Meross Devices.
Apache License 2.0
31 stars 13 forks source link

Unable to launch the addon with docker locally #37

Closed Devstored closed 11 months ago

Devstored commented 1 year ago

Good morning,

Being a Home Assistant user under Docker, I would like to use your addon in standalone mode with Docker. I used your files: https://github.com/albertogeniola/ha-meross-local-broker/tree/main/.local_debug

I correctly executed: build_addon_locally.sh = OK I then wanted to run: run_addon_locally.sh = KO

However I have the following error:

WARNING: The requested image's platform (linux/amd64) does not match the detected host platform (linux/arm64/v8) and no specific platform was requested
s6-rc: info: service s6rc-oneshot-runner: starting
s6-rc: info: service s6rc-oneshot-runner successfully started
s6-rc: info: service fix-attrs: starting
fix-attrs: info: applying /etc/fix-attrs.d/50-mosquitto
s6-chown: fatal: unable to chown /etc/mosquitto/certs/ca.conf
server.conf: No such file or directory
fix-attrs: warning: fix-attrs is deprecated, please fix volume permissions in your container manager instead
fix-attrs: warning: some fix files failed to apply
s6-rc: warning: unable to start service fix-attrs: command exited 1
/run/s6/basedir/scripts/rc.init: warning: s6-rc failed to properly bring all the services up! Check your logs (in /run/uncaught-logs/current if you have in-container logging) for more information.
/run/s6/basedir/scripts/rc.init: fatal: stopping the container.
s6-rc: info: service s6rc-oneshot-runner: stopping
s6-rc: info: service s6rc-oneshot-runner successfully stopped

Looks like it can't find "server.conf".

Have you encountered this problem?

Thank you so much !

albertogeniola commented 1 year ago

Hi @Devstored , first of all, let me state that running this container in stand-alone mode is not supported at the moment and won't work.

In any case, it looks like the container is not able to set the permissions on server.conf and ca.conf. Both those files are contained in /etc/mosquitto/certs/. It looks like the image you built is not valid or is missing such files. Rebuild the image and make sure those files are in place within the image.

xela1 commented 1 year ago

first of all, let me state that running this container in stand-alone mode is not supported at the moment and won't work.

Hi @albertogeniola do you have any plans to allow this to be run in stand-alone, I also don't run HA supervised, but would love this

albertogeniola commented 11 months ago

Hi @xela1 , I have no plans to add support for running the addon without HomeAssistant, I am sorry about that. In any case, it shouldn't be so hard to make this addon to work as stand-alone container. It would be great if anyone else could spend some time in creating the stand-alone component using this code.