Skip to content
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

Missing linux groups cause HM-MOD-RPI-PCB connection to fail #18

Open
lhurt opened this issue Apr 3, 2024 · 0 comments
Open

Missing linux groups cause HM-MOD-RPI-PCB connection to fail #18

lhurt opened this issue Apr 3, 2024 · 0 comments

Comments

@lhurt
Copy link

lhurt commented Apr 3, 2024

The current docker images are missing the groups dialout, spi and gpio causing a failure when operating the HM-MOD-RPI-PCB hardware. The error reads
HomeMatic BidCoS: HM-MOD-RPI-PCB "My-HM-MOD-RPI-PCB": Error in file PhysicalInterfaces/Hm-Mod-Rpi-Pcb.cpp line 810 in function void BidCoS::Hm_Mod_Rpi_Pcb::doInit(): Failed to open GPIO value file "/sys/class/gpio/gpio18/value": Permission denied

This is cause by the absence of the groups mentioned and thus the homegear user can't be member of them. Adding the additional build step

FROM homegear/homegear:stable
ARG HOST_GROUP_GPIO_UID="gpio gruppen uid des hosts setzen"
ARG HOST_GROUP_I2C_UID="i2c gruppen uid des hosts setzen"
ARG HOST_GROUP_SPI_UID="spi gruppen uid des hosts setzen"

RUN groupadd -g $HOST_GROUP_GPIO_UID gpio && usermod -a -G gpio homegear && \
    groupadd -g $HOST_GROUP_I2C_UID i2c && usermod -a -G i2c homegear && \
    groupadd -g $HOST_GROUP_SPI_UID spi && usermod -a -G spi homegear

fixes this issue. As I suppose that this issue should be fixed in the install process of the respecting package rather than in the docker file I can't file a pull request because I don't know much about the debian apt procedures.

May I'd like to add the finding that the docker image doesn't work in debian bookworm at all because it seems to me that the access via /sys/class/gpio/gpio18/ was removed. I can file a separate ticket for this if you request me to do so.

@lhurt lhurt changed the title Missing users cause HM-MOD-RPI-PCB connection to fail Missing user groups cause HM-MOD-RPI-PCB connection to fail Apr 3, 2024
@lhurt lhurt changed the title Missing user groups cause HM-MOD-RPI-PCB connection to fail Missing linux groups cause HM-MOD-RPI-PCB connection to fail Apr 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant