Bug 205162

Summary: [NEW PORT] mail/postfix-dovecot2: Slave port with DOVECOT2 option enabled
Product: Ports & Packages Reporter: Nikolai Lifanov <lifanov>
Component: Individual Port(s)Assignee: Olli Hauer <ohauer>
Status: Closed FIXED    
Severity: Affects Some People CC: ohauer
Priority: --- Keywords: easy, feature, patch, patch-ready
Version: LatestFlags: koobs: maintainer-feedback? (ohauer)
Hardware: Any   
OS: Any   
Attachments:
Description Flags
mail/postfix-dovecot2 slave
none
poudriere testport log
none
mail/postfix-dovecot2 slave
none
mail/postfix: add postfix-dovecot2 slave port
none
[patch] dovecot is supported out of the box
none
mail/postfix: reroll ohauer's patch none

Description Nikolai Lifanov 2015-12-09 16:47:29 UTC
Created attachment 164021 [details]
mail/postfix-dovecot2 slave

Add a slave port for mail/postfix with dovecot2 option selected.
Quick postfix+freebsd Google query suggests that this is a common setup.

This is the only holdout from being able to use official binary packages
on several of my email systems.
Comment 1 Nikolai Lifanov 2015-12-09 16:48:44 UTC
Created attachment 164022 [details]
poudriere testport log
Comment 2 Nikolai Lifanov 2016-02-01 17:24:40 UTC
Created attachment 166408 [details]
mail/postfix-dovecot2 slave
Comment 3 Nikolai Lifanov 2016-02-01 17:25:57 UTC
Created attachment 166409 [details]
mail/postfix: add postfix-dovecot2 slave port
Comment 4 Olli Hauer freebsd_committer freebsd_triage 2016-02-14 20:48:01 UTC
Created attachment 166994 [details]
[patch] dovecot is supported out of the box

After study the postfix HISTORY and knowing dovecot is not needed to build dovecot SASL support I will commit something like the new patch.

At the moment my main issue is to find good short SASL_DESC so users are to much confused about the removal of the DOVECOT(2) OPTION.

Additional help for SASL will be provided via pkg-help, there we have the ability to write more text the in the ${OPTION}_DESC line.

Let me know what you think, any help with better wording is welcome.
Comment 5 Nikolai Lifanov 2016-02-15 01:32:25 UTC
I love this approach. As a note, in CentOS, postfix package comes with both Cyrus and Dovecot SASL support enabled:

$ postconf -a
cyrus
dovecot

If Cyrus SASL doesn't generate additional compile-time dependencies, can we enable this also? If not, Dovecot option would suit most users.
I am able to test the new package with Dovecot 2.
Comment 6 Olli Hauer freebsd_committer freebsd_triage 2016-02-15 04:45:48 UTC
Providing Cyrus support requires libsasl2.so (security/cyrus-sasl2).
Unfortunately this is also on postfix-current not modular like cdb,pcre,*sql and a reference to libsasl2.so is linked into most every postfix binary.
Comment 7 Nikolai Lifanov 2016-02-15 05:13:57 UTC
I thought as much (about Cyrus). Please proceed with your plan of enabling Dovecot support universally. Could you also bump port revision so that official packages are rebuilt?
Comment 8 Nikolai Lifanov 2016-02-15 05:21:31 UTC
Also, tiny nit about patch: HISOTRY should probably be HISTORY.
Comment 9 Nikolai Lifanov 2016-02-16 20:55:48 UTC
Created attachment 167095 [details]
mail/postfix: reroll ohauer's patch

This is just like the other patch attached to this PR, but rerolled to apply cleanly to mail/postfix (instead of -current).
One minor content change: s/always build in/always built in/.
Comment 10 Nikolai Lifanov 2016-02-16 21:08:23 UTC
The patch against mail/postfix that I posted passes "poudriere testport" and is currently running on one of my MTAs, sending and receiving mail with Dovecot 2 SASL.
Comment 11 commit-hook freebsd_committer freebsd_triage 2016-02-25 20:10:37 UTC
A commit references this bug:

Author: ohauer
Date: Thu Feb 25 20:09:57 UTC 2016
New revision: 409551
URL: https://svnweb.freebsd.org/changeset/ports/409551

Log:
  - rework SASL OPTIONS
    Dovecot SASL does not need any dependency, from now it will be always build into postfix
    and the default SASL unless Cyrus is also added (there is no conflict between them)

  - add support for FreeBSD 10.3 mailwrapper (install mailer.conf into LOCALBASE/mail instead /etc/mail)
  - add better reload support to rc script
  - display correct path in pkg-message
  - add support for postfix-sasl slave port
  - bump PORTREVISION

  Many Thanks to all testers!

  PR:	195662
  PR: 	205162

Changes:
  head/mail/postfix/Makefile
  head/mail/postfix/files/pkg-install.in
  head/mail/postfix/files/pkg-message.in
  head/mail/postfix/files/postfix.in
  head/mail/postfix/pkg-help
Comment 12 commit-hook freebsd_committer freebsd_triage 2016-02-25 20:26:46 UTC
A commit references this bug:

Author: ohauer
Date: Thu Feb 25 20:26:09 UTC 2016
New revision: 409556
URL: https://svnweb.freebsd.org/changeset/ports/409556

Log:
  - update to 3.0.4
  - rework SASL OPTIONS
    Dovecot SASL does not need any dependency, from now it will be always build into postfix

  - EAI is now mandantory, else mails can be lost
  - add support for FreeBSD 10.3 mailwrapper (install mailer.conf into LOCALBASE/mail instead /etc/mail)
  - add better reload support to rc script
  - display correct path in pkg-message
  - add support for postfix-sasl slave port
  - remove nativ SPF support, patch is no longer maintained and there are alternatives in the ports tree
  - remove VDA support (seems VDA project is dead and unmaintaned)

  Many Thanks to all testers!

  PR:	195662
  PR: 	205162

Changes:
  head/mail/postfix-current/Makefile
  head/mail/postfix-current/distinfo
  head/mail/postfix-current/files/pkg-install.in
  head/mail/postfix-current/files/pkg-message.in
  head/mail/postfix-current/files/postfix.in
  head/mail/postfix-current/pkg-help
Comment 13 commit-hook freebsd_committer freebsd_triage 2016-02-25 20:33:50 UTC
A commit references this bug:

Author: ohauer
Date: Thu Feb 25 20:33:43 UTC 2016
New revision: 409557
URL: https://svnweb.freebsd.org/changeset/ports/409557

Log:
  - add postfix SASL slave port to the tree

  Requested by many

  PR:	195662
  PR: 	205162

Changes:
  head/mail/Makefile
  head/mail/postfix-current-sasl/
  head/mail/postfix-current-sasl/Makefile
  head/mail/postfix-sasl/
  head/mail/postfix-sasl/Makefile
Comment 14 Olli Hauer freebsd_committer freebsd_triage 2016-02-25 20:44:33 UTC
Hope I haven't overlooked something!

Thanks for your patience!