theimo1221 / victron-mqtt-consumer

Library to connect to a victron and provide Device data
Apache License 2.0
2 stars 1 forks source link

docker container #1

Open albundy0815 opened 10 months ago

albundy0815 commented 10 months ago

would it be possible, that you could provide a docker image or document how to do it? I'm having home assistant with portainer running. The victron solution is working but not sure, when they implement the influxdb 2 connection. In a thread I've found this project from you, but I'm having issues, how to install it (especially on portainer/docker). I tried some things but it seems, that my knowledge is definitely not the best regarding linux :(

theimo1221 commented 10 months ago

Hi @albundy0815

This is a npm library which you can include into any node application. There are guides out there how to build a docker container running a node as application.

Regarding usage of this library you might want to take a look at: https://github.com/theimo1221/victron-mqtt-consumer/blob/main/__tests__/influx.test.ts which gives an example of establishing connection to victron via mqtt and starting influxdb logging.

albundy0815 commented 9 months ago

Hi @theimo1221, thanks for the hints regarding Docker. Right now I tried to install it manually without using docker but same here... I'm having issues with installation - also due to that, that I'm not a developer. Maybe you can provide a short documentation, how this project can be installed "correct" and which settings needs to be done after the installation. It would be very helpful (for me and I guess, also for other users here, which doesn't have developer knowledge, but using victron products ;) )

theimo1221 commented 9 months ago

Hello @albundy0815 ,

I'm sorry but the scope of this library is different to docker. This libraries "purpose" is to be included in some other javascript application. By adding this to another application you get a tool to read all data from the victron device and (if you want) store it in an influx db. So storing in influx db is more a additional goodie as we have the data anyways.

I myself use this library in my home-automation system (see https://github.com/Hoffmation/Hoffmation-Base/blob/main/src/server/services/victron/victron-device.ts ) to turn on additional consumer based on Battery level.

As a conclusion you could say this library is more like a tool for other applications, what you are looking for seems to be a standalone docker container/application.

Best regards

Thiemo

albundy0815 commented 9 months ago

Hi @theimo1221, thanks for the clarification. I'll wait till Victron will provide a stand-alone-version which also provides to write the data into an exitsting InfluxDB2 (due to size limitation of InfluxDB1). Hopefully they will provide a solution soon. ;)