Omnik data logger now also can be installed in docker container. This makes it easy to integrate in a docker based environment. This is an alternative to using AppDaemon with HACS.
Install the docker image
Docker images can now be build from the docker folder. There is now a prepared image on docker hub.
Use the command docker pull jbouwh/omnikdatalogger
to pull the latest image.
To build image yourself from git:
git clone https://github.com/jbouwh/omnikdatalogger
cd omnikdatalogger/docker
docker build --tag jbouwh/omnikdatalogger:latest .
Running the docker image
In the folowing example assumed is that the config file outside the container is at /home/pi/.omnik/config.ini
(user pi). In the docker image the user is omnik
and the default location for the configuration inside the container is at /config.ini
The -p option is only needed when the localproxy client is used with the tcp_proxy plugin.
Use –device option to give direct access to a DSMR compliant USB monitoring cable. Alternatively use ser2net.
Run image in the background using the following command:
docker run -d -v /home/pi/.omnik/config.ini:/config.ini -p 10004:10004 --device /dev/ttyUSB0 --name omnikdatalogger jbouwh/omnikdatalogger:latest