Created attachment 215138 [details]
New port for NRPE4. I found this port as nrpe3 is marked as outdated but there is no new version since 2017, as only v4 receives update. V4 also introduces TLS1.3 support.
I took the Makefile from nrpe3 and adjusted to newest version.
- portlint -A is happy
- poudriere builds fine on 12.1 64bit
- poudriere testport runs fine on 12.1 64bit
- pkg installs fine and nagios checks a handled correctly
I decided to add a new port since the existing port is labeld as nrpe3, and with nrpe4 you need to add an additional parameter to make it backward compatible (which would break existing setups).
zeising@, sorry for adding you CC, but since you maintain nrpe3 maybe you want to have look.
(In reply to Michael Muenz from comment #1)
Don't apologize, it's ok to ask for help and reviews. :)
Is there anything in nrpe4 that breaks nrpe3 setups (I haven't looked myself). Otherwise, it might make sense to simply update nrpe3 to this version (and rename it) rather than have both versions. What do you think?
I'm open for both options but it seems when nrpe v4 wants to contact an instance of nrpe v3 (like when when you update the package on the server and not the agents), you have to adjust the syntax to use v3 full backwards compatibility.
It should work  as the changelog for 4.0.0 states, but I can't test all scenarios.
Sorry for sitting on this, I had forgot about it.
I believe the best way is to simply update nrpe to 4.0. If anyone still needs nrpe3, a separate port for that can be created.
Michael Muenz, are you OK with simply replacing NRPE3 with NRPE4? Do you want to maintain NRPE4?
sorry for late reply, was on vacation.
I'm not sure how this works since older port is called nrpe3. For me this sounds like creating a port "nrpe" and remove "nrpe3"?
Again, I'm unsure if this breaks existing setups when nrpe3 will be upgraded to v4.
I can take maintainership if there are no concerns.
Thank you both for working on this.
Two minor items I have noticed so far while testing.
1. In the event that both nrpe3 and nrpe4 appear in the ports tree concurrently, they will either need to be marked in CONFLICT with each other, or (perhaps better) their config files de-conflicted (sample, pkg-message, and rc script).
% pkg info -lF nrpe3-3.2.1.txz
% pkg info -lF nrpe4-4.0.3.txz
2. The config sample sets the PID location, which takes precedence over the port-configured default.
However, when I comment this out, the pid file is not written to where I expect it to be. Curiously, I have been unable to find the pid file, but the rc script is still able to status and stop the running process. This may affect nrpe3 as well. I haven't checked.