Bug 250961

Summary: dns/powerdns: Adjust dependencies for tools
Product: Ports & Packages Reporter: Juraj Lutter <otis>
Component: Individual Port(s)Assignee: freebsd-ports-bugs (Nobody) <ports-bugs>
Status: Closed FIXED    
Severity: Affects Only Me CC: mikael, tremere
Priority: --- Flags: tremere: maintainer-feedback+
Version: Latest   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
dns/powerdns: Fix dependencies
none
Fix dependencies, drop user privileges, always depend on protobuf and fix rc script
tremere: maintainer-approval+
Add pdns user to UIDs
none
dns/powerdns: Fix dependencies
none
Add missing patch and bump PORTREVISION tremere: maintainer-approval+

Description Juraj Lutter freebsd_committer freebsd_triage 2020-11-08 17:40:01 UTC
Created attachment 219468 [details]
dns/powerdns: Fix dependencies

Hi,

please find the patch attached. It does:

- Adjust dependencies (IXFRTOOL needs yaml-cpp)
- Explicitly disable decaf and sodium in case they are not enabled.
  Otherwise they default to "auto" and if detected in the system,
  stage-qa reports unresolved dependency.
- Bump PORTREVISION
Comment 1 Ralf van der Enden 2020-11-11 07:52:24 UTC
Created attachment 219541 [details]
Fix dependencies, drop user privileges, always depend on protobuf and fix rc script


Juraj, thanks for your patch. Only libsodium is detected automatically, so I adjusted your patch a bit.

I also had some other changes ready, so why not add those as well:
- Drop user privilges for worker processes to pdns/pdns (UID is new; GUID already exists)
- Always depend on protobuf. I do the same for dnsdist and powerdns-recursor
- Actually do something with the pdns_flags variable in the rc-script instead of just mentioning it in the comment block
Comment 2 Ralf van der Enden 2020-11-11 07:55:21 UTC
Created attachment 219542 [details]
Add pdns user to UIDs


This adds the pdns user on an open slot; the GUID is used, but not an issue since I use another already existing one. If that's not ok, please adjust accordingly or tell me so I can redo the patch.
Comment 3 Ralf van der Enden 2020-11-12 08:45:49 UTC
Q&A:
portlint: OK (1 warning about pkg-descr length)
testport: OK (12.2, amd64)
Comment 4 Mikael Urankar freebsd_committer freebsd_triage 2020-11-15 16:11:38 UTC
(In reply to Ralf van der Enden from comment #3)
I have the following error on 13amd64:
===========================================================================
====> Running Q/A tests (stage-qa)
====> Checking for pkg-plist issues (check-plist)
===> Parsing plist
===> Checking for items in STAGEDIR missing from pkg-plist
Error: Orphaned: %%PORTDOCS%%%%DOCSDIR%%/4.3.0_to_4.3.1_schema.sqlite3.sql
===> Checking for items in pkg-plist which are not in STAGEDIR
===> Error: Plist issues found.
Comment 5 Mikael Urankar freebsd_committer freebsd_triage 2020-11-15 16:18:53 UTC
(In reply to Mikael Urankar from comment #4)
with default options
Comment 6 Juraj Lutter freebsd_committer freebsd_triage 2020-11-15 16:56:03 UTC
Created attachment 219704 [details]
dns/powerdns: Fix dependencies

- Better formatted patch (with context)
- Fixed pkg-plist
Comment 7 Mikael Urankar freebsd_committer freebsd_triage 2020-11-15 19:01:40 UTC
Thanks!
Comment 8 commit-hook freebsd_committer freebsd_triage 2020-11-15 19:02:22 UTC
A commit references this bug:

Author: mikael
Date: Sun Nov 15 19:01:31 UTC 2020
New revision: 555419
URL: https://svnweb.freebsd.org/changeset/ports/555419

Log:
  dns/powerdns: Adjust dependencies for tools

  - Adjust dependencies (IXFRTOOL needs yaml-cpp)
  - Explicitly disable decaf and sodium in case they are not enabled.
    Otherwise they default to "auto" and if detected in the system,
    stage-qa reports unresolved dependency.
  - Drop user privilges for worker processes to pdns/pdns (UID is new; GUID already exists)
  - Always depend on protobuf. I do the same for dnsdist and powerdns-recursor
  - Actually do something with the pdns_flags variable in the rc-script instead of just mentioning it in the comment block
  - Bump PORTREVISION

  PR:		250961
  Submitted by:	Juraj Lutter, Ralf van der Enden
  Approved by:	Ralf van der Enden (maintainer)

Changes:
  head/UIDs
  head/dns/powerdns/Makefile
  head/dns/powerdns/files/pdns.in
  head/dns/powerdns/pkg-plist
Comment 9 Ralf van der Enden 2020-11-16 15:18:34 UTC
The diff wasn't fully committed. The patch to set the default UID and GUID is missing from the port.

This is the file:
files/patch-pdns_common__startup.cc

Thanks in advance.
Comment 10 Ralf van der Enden 2020-11-16 15:24:20 UTC
Created attachment 219732 [details]
Add missing patch and bump PORTREVISION
Comment 11 commit-hook freebsd_committer freebsd_triage 2020-11-16 15:30:21 UTC
A commit references this bug:

Author: mikael
Date: Mon Nov 16 15:30:14 UTC 2020
New revision: 555485
URL: https://svnweb.freebsd.org/changeset/ports/555485

Log:
  dns/powerdns: add missing patch

  PR:		250961
  Submitted by:	Ralf van der Enden (maintainer)

Changes:
  head/dns/powerdns/Makefile
  head/dns/powerdns/files/patch-pdns_common__startup.cc