-
Notifications
You must be signed in to change notification settings - Fork 61
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Thought about conversion to docker? #75
Comments
I don't mind converting it to docker and even have a pull request for this |
I’ll have a look tomorrow, I don’t think so. |
Docker file here:
It's a weird dockerfile, as I had a custom build process for arm64, arm32 and amd64. I think you can do it now with travis ci building the containers. I don't think I moved the code, but possibly the conf file location.
Mine:
|
Sorry if I am butting in on anyone but I a noobie and am trying to get BG1 mqtt working. Can someone please point me in the direction of a forum or something to show me the way. thank you |
Has anyone tried BG1 with mqtt all the current guides no longer work? |
@eschava hello, back again!! I've redone the process now, and using volume maps to the mqtt.conf file directly so it doesn't have to move in the projest file.. I do have some code alterations around a log file, but it might not be important, I think I can lose them. |
Hi! Do I need only the Dockerfile file from your branch? |
Yeah probably. I did make some code changes relating to logging in the mqtt.py. But suspect they're not needed. Also my dockerfile was for python 3 (some print adjustments). I've got a compose file that can show the volume mounting for the conf file and commands which we can add to the readme if you want. |
added. Thanks for your efforts! |
So the next step, if we confirm that's working is getting dockerhub to automatically build it. I might kill my branch, and pull from master (is that where the added docker file is?). The I can test the dockerfile and show you the docker hub config for build |
Does your image support Raspberry Pi 4 (with Raspberry OS 32bit) architecture?
Thanks |
Possibly not at the moment as it is built with docker hub. And while I used to have a travis integration for another project that did build manifests - a travis update broke the emulation need to build on a pi. Unfortunately you might need to pull the source and build the image on a pi. |
I've had some unsuccessful attempts to compile @eschava's broadlink-mqtt as a docker image.
Full build output here: broadlink-mqtt_docker_compile_error.txt I managed to get over this by adding the following 2 lines in Dockerfile
(I am not sure if the libffi-dev libraries are really necessary, but the env. variable CRYPTOGRAPHY_DONT_BUILD_RUST=1 is necessary for sure to avoid the attempt to compile rust). The container obviously does not start without the configuration files:
Now I am in the process of mapping the external configuration files, but they are in the same place as the binaries, so probably the mounts must be done at file level and not at directory/volume level. (each of the config files: mqtt.conf, logging.conf, custom.conf should be mounted separately in the container). How about mqtt.log?
@psyciknz : Can you please share your docker-composer.yml file that you've been mentioning above? thanks a lot |
Ok. I might be able to look at adding that of @eschava can (or you if you want to make a pull request. Not sure I'll be able to format this (GitHub on the phone). But here's my compose file.
Hope it helps. I'm away for the next week but can look into this once back, as I have another python service I used to multi arch build via travis but it stopped working. Maybe they've fixed the problem. |
Thank you!
I wasn't able to find this parameter in the configuration template files nor in the broadlink-mqtt documentation... Any ideas on how to solve this? thanks! |
I Have that in the MQTT.conf I’m not sure how custom.conf relates to MQTT.conf. And depending how you’re doing your compose file if it’s being picked up. |
I mapped the custom.conf file in docker-compose.yml:
I did some more investigation and it seems that the custom.conf file is ignored. This explains why adding the logdir parameter in I did all configuration directly in mqtt.conf and the container is starting correctly. However I am still not able to execute commands stored in
Still have to do some more troubleshooting. Has the way of running commands changed in broadlink-mqtt?
Example:
Thank you! |
I still use this, have for a couple of years, old version though from when I did the multiple devices code.
I converted it to a docker container a while back. If you’re interested in the docker file
The text was updated successfully, but these errors were encountered: