Created attachment 240733 [details] [PATCH] www/grafana9: fix rc.d script procname (Patch attached.) After starting Grafana, running service grafana status or service grafana stop will say grafana is not running. This happens because rc.d checks that 1) the pidfile exists 2) the process id in the pidfile is running 3) the proccess name matches either the command, or procname After Grafana switched to a unified binary, grafana-server is a wrapper for "grafana server". The procname should therefore be set to %%PREFIX%%/bin/grafana instead of %%PREFIX%%/bin/grafana-server so rc.d process name check succeeds.
Comment on attachment 240733 [details] [PATCH] www/grafana9: fix rc.d script procname (In reply to dominik from comment #0) LGTM. Thx! Also it's needed to bump PORTREVISION and merge to 2023Q1.
Created attachment 240760 [details] [PATCH] www/grafana9: fix rc.d script procname and bump PORTREVISION Bumping PORTREVISION following maintainer's feedback. Rebased on current main.
Created attachment 240761 [details] www/grafana9: fix rc.d script procname and bump PORTREVISION Same as the previous, but squashed to a single commit. It seems Bugzilla doesn't play nice with git format-patch files containing multiple commits (eg. created with git format-patch -2).
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=d2f15374931e8b5c5c360a2ecd7794ff492d8d56 commit d2f15374931e8b5c5c360a2ecd7794ff492d8d56 Author: Dominik Banoviez <dominik@banoviez.com> AuthorDate: 2023-03-10 21:28:28 +0000 Commit: Robert Clausecker <fuz@FreeBSD.org> CommitDate: 2023-03-22 20:15:29 +0000 www/grafana9: fix rc.d script procname Grafana switched to a unified binary, changing `grafana-server` to be a wrapper script that executes `grafana server` in its place. This patch fixes `procname` in the rc.d script, so that rc.d's process name checking doesn't fail / the service gets properly reported as running. PR: 270098 MFH: 2023Q1 www/grafana9/Makefile | 1 + www/grafana9/files/grafana.in | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-)
A commit in branch 2023Q1 references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=889b2ceda43f9459cf339ede384eb744ce4f6075 commit 889b2ceda43f9459cf339ede384eb744ce4f6075 Author: Dominik Banoviez <dominik@banoviez.com> AuthorDate: 2023-03-10 21:28:28 +0000 Commit: Robert Clausecker <fuz@FreeBSD.org> CommitDate: 2023-03-22 20:19:06 +0000 www/grafana9: fix rc.d script procname Grafana switched to a unified binary, changing `grafana-server` to be a wrapper script that executes `grafana server` in its place. This patch fixes `procname` in the rc.d script, so that rc.d's process name checking doesn't fail / the service gets properly reported as running. PR: 270098 MFH: 2023Q1 (cherry picked from commit d2f15374931e8b5c5c360a2ecd7794ff492d8d56) www/grafana9/Makefile | 1 + www/grafana9/files/grafana.in | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-)
Thank you for your contribution.