Page 1 of 1

what about portsettings etc. in docker?

Posted: Sunday 02 November 2025 0:22
by BartSr
Hi, making domoticz run in container.
I am looking for docu about portsettings etc for rfxcom and other usb devices
Maybe more, but trying.
MQTT broker is running but how to check domoticz is connected via mqtt?
Anyone who helps me out?

Re: what about portsettings etc. in docker?

Posted: Sunday 02 November 2025 1:14
by waltervl
See the wiki: https://wiki.domoticz.com/Docker
To check Domoticz is connected to MQTT check the log (the same as Domoticz without Docker...)

Re: what about portsettings etc. in docker?

Posted: Wednesday 05 November 2025 19:06
by BartSr
After spending far over a day I still get stuck. It seems there's something wrong with volumes in the docker-compose.yaml
It happens that after running the container there's an empty database. I understood that just if container is running you see the database with two files being 'part' of the database. But I just see domoticz.db only.

In contradiction to the wiki setup for zigbee2mqtt which shows a complete docker-compose.yaml this is missing in the wiki for docker.
What's best way to get out of this labyrinth?

As the docker setup failed I tried bare installation which proceeded well until an error stopped unpackking the files while almost done.

Any advices are welcome.
Mosquitto and z2m went very easy with usecof docker.

Thanks for helping me out.

Re: what about portsettings etc. in docker?

Posted: Wednesday 05 November 2025 19:07
by BartSr
This regards hardware HPthinclientT630 with Ubuntu 24
After spending far over a day I still get stuck. It seems there's something wrong with volumes in the docker-compose.yaml
It happens that after running the container there's an empty database. I understood that just if container is running you see the database with two files being 'part' of the database. But I just see domoticz.db only.

Code: Select all

services:
  domoticz:
    image: domoticz/domoticz:latest
    container_name: domoticz
    restart: unless-stopped
    ports:
      - "8080:8080"   # Web interface
      - "1443:1443"   # HTTPS (optioneel)
      - "6144:6144/udp" # Domoticz UDP (voor sommige ap>
    volumes:
#      - ./home/bart/Domoticz:/home/bart/Domoticz
      - /home/bart/domoticz/config:/config
#      - /home/bart/domoticz/config:/opt/domoticz
      - /home/bart/domoticz/scripts:/opt/domoticz/scrip>
      - /home/bart/domoticz/plugins:/opt/domoticz/plugi>
      - /home/bart/domoticz/log:/opt/domoticz/log
      - /home/bart/domoticz/backup:/opt/domoticz/backups
      - /home/bart/domoticz/data:/opt/domoticz/data
    environment:
#      - PUID=1000       # Pas aan naar de gebruiker op>
#      - PGID=1000       # Pas aan naar de groep op je >
      - TZ=Europe/Amsterdam  # Pas aan naar jouw tijdzo>
    devices:
      - "/dev/serial/by-id/usb-RFXCOM_RFXtrx433_A1BFAMG>

The file might be bit messy but this is me latest try
In contradiction to the wiki setup for zigbee2mqtt which shows a complete docker-compose.yaml this is missing in the wiki for docker.
What's best way to get out of this labyrinth?

As the docker setup failed I tried bare installation which proceeded well until an error stopped unpackking the files while almost done.

Any advices are welcome.
Mosquitto and z2m went very easy with usecof docker.

Thanks for helping me out.

Re: what about portsettings etc. in docker?

Posted: Wednesday 05 November 2025 19:24
by waltervl
Did you check https://hub.docker.com/r/domoticz/domoticz ?
And especially this section;
Usage with docker-compose

mkdir /opt/domoticz
cd /opt/domoticz

Inside this folder create a file (docker-compose.yml) with the following contents

docker-compose.yml
Then after starting the container the database should popup in /opt/domoticz/config

But you can choose any folder on your system where to store the docker-compose.yml as that is the root for the volume from the outside.
Inside the container it is always /opt/domoticz/userdata

On my Ubuntu system I had no write acces as normal user in folder /opt so I created the docker compose in /home/<user>/domoticz-docker

Re: what about portsettings etc. in docker?

Posted: Wednesday 05 November 2025 21:04
by BartSr
Oops, overlooked the link to that docker page.
Just a few seconds and it was done.
Thanks again Walter.

Re: what about portsettings etc. in docker?

Posted: Friday 07 November 2025 10:06
by waltervl
You are welcome.
In your case I would not use tag latest but stable, eg

Code: Select all

image: domoticz/domoticz:stable
When using latest you will get all beta's en all stables, whatever is created latest.