Created attachment 228429 [details] new port, exposes php-fpm/staus metrics for Prometheus Exports php-fpm /status page into a format that Prometheus understands on port 9253. A build of https://github.com/hipages/php-fpm_exporter. My first port. Copy&pasted and googled my way into something that seems to work as intended. Tested only on FreeBSD 12.2 on AMD64, but the releases page on GitHub has binaries for ARM64 too, so I assume that also works. I'm not sure about PLIST_FILES, shouldn't it also list the rc.d script that it installs? I am not a Go developer, I don't actually fully understand what I did. It builds and it works-on-my-machines, that's all I know. 'make test' output: ===> Testing ./... ? github.com/hipages/php-fpm_exporter [no test files] ? github.com/hipages/php-fpm_exporter/cmd [no test files] === RUN TestCountProcessState --- PASS: TestCountProcessState (0.00s) === RUN TestCannotUnmarshalNumberIssue10 --- PASS: TestCannotUnmarshalNumberIssue10 (0.00s) === RUN TestInvalidCharacterIssue24 --- PASS: TestInvalidCharacterIssue24 (0.00s) === RUN TestJsonResponseFixer --- PASS: TestJsonResponseFixer (0.00s) === RUN TestParseURL --- PASS: TestParseURL (0.00s) PASS ok github.com/hipages/php-fpm_exporter/phpfpm 0.009s
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=e20d99399a25bb2f5203e9251b408a1da431962d commit e20d99399a25bb2f5203e9251b408a1da431962d Author: Vanilla I. Shu <vanilla@FreeBSD.org> AuthorDate: 2021-10-06 06:44:13 +0000 Commit: Vanilla I. Shu <vanilla@FreeBSD.org> CommitDate: 2021-10-06 07:13:57 +0000 net-mgmt/php-fpm_exporter: add port PR: 258916 Reported by: bgdnlp <freebsd.org at neant.ro> net-mgmt/Makefile | 1 + net-mgmt/php-fpm_exporter/Makefile (new) | 59 ++++++++++++++++ net-mgmt/php-fpm_exporter/distinfo (new) | 79 ++++++++++++++++++++++ .../files/php_fpm_exporter.in (new) | 66 ++++++++++++++++++ net-mgmt/php-fpm_exporter/pkg-descr (new) | 4 ++ 5 files changed, 209 insertions(+)
Committed, thanks. BTW, I remove GO_MODULES from Makefile, it's invalid variable name (should be GO_MODULE, you can check /usr/ports/Mk/Uses/go.mk for more details.)