Bug 213132 - Bypass mailer.conf activation prompt when installing mail/postfix non-interactively
Summary: Bypass mailer.conf activation prompt when installing mail/postfix non-interac...
Status: Closed Feedback Timeout
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: Olli Hauer
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-09-30 23:43 UTC by xenophon+fbsdports
Modified: 2020-10-12 01:51 UTC (History)
2 users (show)

See Also:
bugzilla: maintainer-feedback? (ohauer)


Attachments
Patch to mail/postfix/files/pkg-install.in adding the "-t 0" test to the ask() function (495 bytes, patch)
2016-09-30 23:43 UTC, xenophon+fbsdports
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description xenophon+fbsdports 2016-09-30 23:43:11 UTC
Created attachment 175324 [details]
Patch to mail/postfix/files/pkg-install.in adding the "-t 0" test to the ask() function

I'm having some trouble automating the deployment of Postfix on FreeBSD, and it comes down to the mailer.conf activation prompt in the pkg-install script.  The behavior I want is for pkg-install to check whether standard input is open and connected to a terminal, a la the "-t 0" argument to /bin/test.  If standard input is not connected to a terminal, then the "ask()" function in the script should return the default value.  This makes it possible to install Postfix non-interactively.  The attached patch implements this behavior, and I've tested both cases, when stdin is a terminal and when it is not.
Comment 1 tw109363 2020-10-12 01:51:28 UTC
MARKED AS SPAM