You need to mount /opt/domoticz/userdata to a directory outside of the container
once you do that the script directory under userdata is used
after that manually(only once) create the following directories to that place
in my case
i mounted external directory domoticz/docker to /op/domoticz/userdata
after that i created on my synology
/volume1/docker/domoticz/scripts/dzVents/generated_scripts
/volume1/docker/domoticz/scripts/dzVents/scripts
/volume1/docker/domoticz/scripts/logrotate
/volume1/docker/domoticz/scripts/templates
Emax wrote: Thursday 10 March 2022 13:32
Experimenting further with scripts on the official docker image i notice that blocky scripts are generated ok but on the dzvents part it fails with:
Code: Select all
2021-03-18 21:19:18.108 Status: dzVents: Write file: /opt/domoticz/userdata/scripts/dzVents/generated_scripts/Script #2.lua
2021-03-18 21:19:18.108 Error: EventSystem: problem writing file: /opt/domoticz/userdata/scripts/dzVents/generated_scripts/Script #2.lua
i suspect this is because of a issue with read/writing rights in the container.
I tried to set the correct rights through putty with:
Code: Select all
docker exec -it DomoTest chmod -R 777 /opt/domoticz/userdata/
Just moved from docker container Linuxserver/Domotiz 2020.2 version to official Domoticz docker 2022.1 and got the exact same problem. Creating the directories solved the issue, but the root cause seems to be that the container creates the scripts-directory in /opt/domiticz/scripts/, while Domoticz expects it to be at /opt/domoticz/userdata/scripts/
So it seems to be an issue with creation of the container. Was this already adresses somewhere?
[/quote]