openhab / openhab-docker

Repository for building Docker containers for openHAB
https://www.openhab.org/
Eclipse Public License 2.0
209 stars 128 forks source link

doorbell binding not working due to lacking libsodium23 #436

Closed schroepf closed 4 months ago

schroepf commented 7 months ago

Summary

I'm user of the openhab/openhab docker image. For my doorbell I require the doorbird binding which seems to require libsodium23 to be installed on the system.

Expected Behavior

With a properly installed and setup doorbird binding the items provided through that binding should update as expected (esp. when ringing the doorbell).

Current Behavior

Possible Solution

libsodium required by doorbird binding

RUN apt-get update RUN apt-get install -y libsodium23


## Steps to Reproduce
- create a  openhab/openhab:4.0.4 docker instance
- install doorbird binding
- create doorbird thing:

Thing doorbird:d210x:DoorbellWe2 "Doorbird Doorbell D210FV" [ doorbirdHost="doorbird", userId="ghpwvc0002", userPassword="xxxxxxxxx", doorbellOffDelay=3, imageRefreshRate=30 ]

- add some doorbird items:

Switch doorbell_pressed_we2 "Doorbell Pressed [%s]" ["Switch"] { channel="doorbird:d210x:DoorbellWe2:doorbell" [profile="rawbutton-on-off-switch"] } DateTime doorbell_pressed_timestamp_we2 "Doorbell Pressed Timestamp [%1$tA, %1$tm/%1$td/%1$tY %1$tl:%1$tM %1$tp]"

- ring the doorbird doorbell device (in my case a D210FV)
- check the openhab logs and the item states

## Context

I was able to fix that issue by creating a custom Dockerfile which installs the libsodium23 package.

## Your Environment

- doorbird D210FV device connected via LAN (reachable via `doorbird` hostname in my LAN)
- openhab docker container running on raspberry pi
- I experienced the same issue already with the 3.0.3 version of the image

### Image

* openHAB version: 4.0.4
* Image tag used: 4.0.4

### Docker Host

* Operating System: Debian GNU/Linux 12 (bookworm) (Raspian Lite image)
* Docker Version: 24.0.7
* Kernel Version: 6.1.0-rpi7-rpi-v8
* Architecture: aarch64

### Configuration

- `compose.yaml`:

openhab_wohnung_2:

image: openhab/openhab:4.0.4

build: openhab_wohnung_2
container_name: openhab_wohnung_2
environment:
  - TZ=Europe/Berlin
  - CRYPTO_POLICY=unlimited
  - EXTRA_JAVA_OPTS=-Duser.timezone=Europe/Berlin
network_mode: "host"
volumes:
  - /etc/localtime:/etc/localtime:ro
  - /etc/timezone:/etc/timezone:ro
  - ./openhab_wohnung_2/openhab_conf:/openhab/conf
  - openhab_we2_addons:/openhab/addons
  - openhab_we2_userdata:/openhab/userdata
profiles:
  - openhab_wohnung_2
restart: always

volumes:: openhab_we2_addons: openhab_we2_userdata:

- `openhab_wohnung_2/Dockerfile`:

FROM openhab/openhab:4.0.4

libsodium required by doorbird binding

RUN apt-get update RUN apt-get install -y libsodium23

wborn commented 7 months ago

Did you already have a look at this?

https://github.com/openhab/openhab-docker/tree/main#missing-some-preinstalled-package

schroepf commented 7 months ago

Ah ok... then this is probably a feature, not a bug :)