David Cook
25b1ada137
This patch adds the User directive to the koha-worker systemd unit file Test plan: 0a. DO NOT APPLY PATCH YET 0b. Start a Koha testing environment running systemd 1. koha-worker --stop kohadev 2. cp debian/templates/koha-worker@.service /etc/systemd/system/. 3. systemctl start koha-worker@kohadev.service 4. ps -efww | grep "background_jobs_worker" 5. Note koha-worker is running as root 6. APPLY THE PATCH 7. cp debian/templates/koha-worker@.service /etc/systemd/system/. 8. systemctl daemon-reload 9. systemctl restart koha-worker@kohadev.service 10. ps -efww | grep "background_jobs_worker" 11. Note that koha-worker is now running as kohadev-koha Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
19 lines
462 B
Desktop File
19 lines
462 B
Desktop File
# koha-worker@.service
|
|
# /etc/systemd/system/koha-worker@.service
|
|
[Unit]
|
|
Description=Koha Task Queue Worker
|
|
After=syslog.target network.target
|
|
|
|
[Service]
|
|
User=%i-koha
|
|
Environment=PERL5LIB=/usr/share/koha/lib
|
|
Environment=KOHA_CONF=/etc/koha/sites/%i/koha-conf.xml
|
|
ExecStart=/usr/share/koha/bin/background_jobs_worker.pl
|
|
Restart=on-failure
|
|
RestartSec=5s
|
|
StartLimitBurst=3
|
|
StartLimitInterval=60
|
|
SyslogIdentifier=%i-koha-worker
|
|
|
|
[Install]
|
|
WantedBy=multi-user.target
|