This patch introduces the koha-systemd package, which provides native systemd service units for managing Koha instances. Each service type (Plack, Zebra, SIP, Z3950, workers, indexers) is managed as a separate systemd unit using instance templates. The package includes: - 8 service templates (plack, zebra, sip, z3950, worker, worker-long, indexer, es-indexer) - 2 target units (koha@.target for per-instance, koha.target for global) - Helper script (koha-systemd-ctl) for managing services All service units include: - KOHA_HOME environment variable pointing to /usr/share/koha - WorkingDirectory set to /var/lib/koha/%i - Proper user/group permissions (%i-koha) This allows granular control over individual services per instance and leverages systemd features like dependency management, resource limits, and journald logging. Test plan: 1. Build and install the package 2. Enable services for an instance 3. Verify all services start correctly 4. Check journalctl logs show no errors Signed-off-by: Tomás Cohen Arazi <tomascohen@theke.io> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk> Signed-off-by: Pedro Amorim <pedro.amorim@openfifth.co.uk> |
||
|---|---|---|
| .. | ||
| docs | ||
| scripts | ||
| source | ||
| systemd | ||
| templates | ||
| README.build | ||
| bd-to-depends | ||
| build-git-snapshot | ||
| changelog | ||
| clean | ||
| compat | ||
| control | ||
| control.in | ||
| copyright | ||
| koha-common.README.Debian | ||
| koha-common.bash-completion | ||
| koha-common.config | ||
| koha-common.cron.d | ||
| koha-common.cron.daily | ||
| koha-common.cron.hourly | ||
| koha-common.cron.monthly | ||
| koha-common.default | ||
| koha-common.dirs | ||
| koha-common.docs | ||
| koha-common.init | ||
| koha-common.install | ||
| koha-common.links | ||
| koha-common.logrotate | ||
| koha-common.postinst | ||
| koha-common.preinst | ||
| koha-common.service | ||
| koha-common.templates | ||
| koha-core.bash-completion | ||
| koha-core.config | ||
| koha-core.default | ||
| koha-core.dirs | ||
| koha-core.docs | ||
| koha-core.init | ||
| koha-core.install | ||
| koha-core.links | ||
| koha-core.logrotate | ||
| koha-core.postinst | ||
| koha-core.preinst | ||
| koha-core.templates | ||
| koha-full.postinst | ||
| koha-post-install-setup | ||
| koha-systemd.README.Debian | ||
| koha-systemd.dirs | ||
| koha-systemd.install | ||
| koha-systemd.postinst | ||
| koha-systemd.prerm | ||
| koha.README.Debian | ||
| koha.apache-ports | ||
| koha.config | ||
| koha.dirs | ||
| koha.install | ||
| koha.postinst | ||
| koha.postrm | ||
| koha.prerm | ||
| list-deps | ||
| rules | ||
| unavailable.html | ||
| update-control | ||
README.build
In order to build .deb packages, following debian packages need to be present (installed): devscripts pbuilder dh-make fakeroot As root (or sudo) execute: pbuilder create Executing build-git-snapshot without any arguments will leave package and the rest in some pbuilder dir, eg. /var/cache/pbuilder/result It is highly recommended that --buildresult option is used.