Bug#899058: ITP: domoticz -- Home automation system
Le 07/06/2018 à 19:03, Thibaut Paumard a écrit : > Strangely, this build of domoticz advertises itself as Version: 3.2112 > in http://localhost:8080/#/About, not 3.8153. Dear Federico, It turns out that the version string is determined at build-time based on the git history. We should patch the build system to advertise the revision number we think we are packaging (see getgit.cmake). > dzVents is outdated in it > and some of the scripts I've been running for months on a > community-provided build of 3.8153 on a Synology NAS don't work with > this version. Turns out I'm actually running a build of the development branch, precisely because I wanted a more advanced version of dzVents. Kind regards, Thibaut.
Bug#899058: ITP: domoticz -- Home automation system
Dear Federico, I've had some success building domoticz on buster using your git repository with some modifications (see attached patch): - in order to use Z-Wave hardware, add libopenzwave1.5-dev as a build-dependency, provide a dummy libopenzwave.pc file and set PKG_CONFIG_PATH to find it. Ideally one would prefer the libopenzwave package to provide this file. - in order to have dzVents to work at all, change ExecStart path from /usr/sbin to /usr/lib/domoticz. - Change dependency from liblua5.2 (which does not seem to exist in the archive?) to liblua5.2-1. Further experiments not included in patch: In order to get persistence working in dzVents, I actually had to copy all of /usr/lib/domoticz/scripts to /var/lib/domoticz/scripts and add -userdata /var/lib/domoticz/ to ExecStart. I think this removes the need to change the executable path, but it would need some care to be done properly in the package. Strangely, this build of domoticz advertises itself as Version: 3.2112 in http://localhost:8080/#/About, not 3.8153. dzVents is outdated in it and some of the scripts I've been running for months on a community-provided build of 3.8153 on a Synology NAS don't work with this version. Kind regards, Thibaut. diff --git a/debian/control b/debian/control index 690e2f3..2ca483c 100644 --- a/debian/control +++ b/debian/control @@ -16,6 +16,7 @@ Build-Depends: cmake, libpthread-stubs0-dev, libsqlite3-dev, libtinyxml-dev, + libopenzwave1.5-dev, python3-dev Standards-Version: 4.1.4 Homepage: https://www.domoticz.com/ @@ -28,7 +29,7 @@ Depends: ${shlibs:Depends}, ${misc:Depends}, adduser, libjsoncpp1, - liblua5.2, + liblua5.2-0, libmosquittopp1, libtinyxml2.6.2v5 Description: Home automation system diff --git a/debian/domoticz.service b/debian/domoticz.service index 139d9cf..f5f1a37 100644 --- a/debian/domoticz.service +++ b/debian/domoticz.service @@ -14,7 +14,7 @@ KillSignal=SIGTERM User=domoticz Group=domoticz -ExecStart=/usr/sbin/domoticz \ +ExecStart=/usr/lib/domoticz/domoticz \ -www ${HTTP_PORT} \ -sslwww ${HTTPS_PORT} \ -wwwroot /usr/lib/domoticz/www/ \ diff --git a/debian/libopenzwave.pc b/debian/libopenzwave.pc new file mode 100644 index 000..4a0d75f --- /dev/null +++ b/debian/libopenzwave.pc @@ -0,0 +1,5 @@ +Name: libopenzwave +Version: +Description: +Libs: -lopenzwave +Cflags: diff --git a/debian/rules b/debian/rules index 85bbca9..c539e02 100755 --- a/debian/rules +++ b/debian/rules @@ -6,6 +6,8 @@ export DEB_LDFLAGS_MAINT_APPEND = -Wl,--as-needed include /usr/share/dpkg/default.mk # provides DEB_VERSION +export PKG_CONFIG_PATH=$(CURDIR)/debian + %: dh $@
Bug#899058: ITP: domoticz -- Home automation system
Hello Federico Ceratto, On Fri, May 18, 2018 at 07:33:21PM +0100, Federico Ceratto wrote: > Package: wnpp > Severity: wishlist > Owner: Federico Ceratto> > * Package name: domoticz [...] > The package will be maintained at https://salsa.debian.org/debian/domoticz [...] Thanks for packaging domoticz. I've not used it myself but I hear good things about it and think it'll be a great addition to the debian archive. I had a quick look at the packaging bits in your git repo and have some questions and comments. Maybe something can be useful for you, but maybe not. Anyway... I see you're using alot of the security features in your service file, great! I wish more packages where better at using these features. I can't help but wonder though if it's not possible for you to use DynamicUser=yes ? You seem to already use some of the strict limitations implied by DynamicUser=yes anyway. Using it would allow you to get away without creating a static system user for your service, but your service also won't be able to create any persistent files (which I don't know if you might need). You also added a 'default' file. Personally I think the only good usage for a default file is with init scripts. Unless I missed something you seem to not have any init script so I don't think that argument applies here. Thus I'd suggest you switch from EnvironmentFile to plainly setting the variables via Environment=. That way users can easily ports via 'systemctl edit ...' the same way they would override any other thing in the service. (Fwiw, I think splitting out the port numbers to an environment variable like you did can be useful even when not using a default file. If the ExecStart line is long and has many different arguments overriding the entire line completely for just a simple port change might be suboptimal for upgrades where you might add, remove or change another unrelated command line argument. Thus being able to just override the environment variable is safer.) Not really willing to take on any (co-)maintainership, but if there's a limited task you think I can help out with don't be shy to ask. (Ofcourse since I'm not a user myself, yet, I'll need help from someone who is to test whatever I implement though.) Regards, Andreas Henriksson PS. You already seem to be very well versed with systemd services but in case you're not already familiar with DynamicUser=yes information about it can be found, except from the systemd documentation ofcourse, at http://0pointer.net/blog/dynamic-users-with-systemd.html
Bug#899058: ITP: domoticz -- Home automation system
Dear Federico, great. Others have tried before you, you may find the state of the previous attemps on alioth in /git/debian-iot/domoticz.git/, in case that helps. Feel free to not use it, though. The debian-iot team (debian-iot-maintainers alioth list) should be interested in co-maintaining. Regards, Thibaut. Le 18/05/2018 à 20:33, Federico Ceratto a écrit : Package: wnpp Severity: wishlist Owner: Federico Ceratto* Package name: domoticz Version : 3.8153 Upstream Author : https://github.com/domoticz/domoticz/graphs/contributors * URL : http://www.domoticz.com/ * License : GPLv3 Programming Lang: C, C++, JavaScript Description : Home automation system Domoticz is a Home Automation System that lets you monitor and configure various devices like: Lights, Switches, various sensors/meters like Temperature, Rain, Wind, UV, Electra, Gas, Water and much more. Notifications/Alerts can be sent to any mobile device. The package will be maintained at https://salsa.debian.org/debian/domoticz It might be used in FreedomBox as there are no other home automation packages currently in Debian. Co-maintainers are welcome.
Bug#899058: ITP: domoticz -- Home automation system
Package: wnpp Severity: wishlist Owner: Federico Ceratto* Package name: domoticz Version : 3.8153 Upstream Author : https://github.com/domoticz/domoticz/graphs/contributors * URL : http://www.domoticz.com/ * License : GPLv3 Programming Lang: C, C++, JavaScript Description : Home automation system Domoticz is a Home Automation System that lets you monitor and configure various devices like: Lights, Switches, various sensors/meters like Temperature, Rain, Wind, UV, Electra, Gas, Water and much more. Notifications/Alerts can be sent to any mobile device. The package will be maintained at https://salsa.debian.org/debian/domoticz It might be used in FreedomBox as there are no other home automation packages currently in Debian. Co-maintainers are welcome.