diff options
author | mandree <mandree@FreeBSD.org> | 2017-09-16 22:22:43 +0800 |
---|---|---|
committer | mandree <mandree@FreeBSD.org> | 2017-09-16 22:22:43 +0800 |
commit | 9691430b42833de17e19fecae59258eb74dff055 (patch) | |
tree | f83160728c5bb319fa556e7f3624f24191b59cfb /mail | |
parent | 332ccbad2f531e53c696b8250475bc6b035c7ca6 (diff) | |
download | freebsd-ports-gnome-9691430b42833de17e19fecae59258eb74dff055.tar.gz freebsd-ports-gnome-9691430b42833de17e19fecae59258eb74dff055.tar.zst freebsd-ports-gnome-9691430b42833de17e19fecae59258eb74dff055.zip |
Add a newsyslog configuration file, to rotate logs.
This enforces the EXAMPLES option because we can't keep
the .sample file in etc/newsyslog.conf.d/* - it would be processed
as the actual file, so we use %%EXAMPLESDIR%% for the distributed version.
Diffstat (limited to 'mail')
-rw-r--r-- | mail/mailman/Makefile | 12 | ||||
-rw-r--r-- | mail/mailman/files/mailman.newsyslog.sample.in | 11 | ||||
-rw-r--r-- | mail/mailman/pkg-plist | 2 |
3 files changed, 23 insertions, 2 deletions
diff --git a/mail/mailman/Makefile b/mail/mailman/Makefile index be9dfb25387c..0e76a39ceff8 100644 --- a/mail/mailman/Makefile +++ b/mail/mailman/Makefile @@ -3,7 +3,7 @@ PORTNAME= mailman DISTVERSION= 2.1.24 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= mail MASTER_SITES= GNU \ SF/${PORTNAME}/Mailman%202.1%20%28stable%29/${PORTVERSION} \ @@ -57,7 +57,7 @@ GROUPS= ${MM_GROUPNAME} MAILMANDIR= ${PREFIX}/${MM_DIR} PLIST_SUB= MMDIR=${MM_DIR} IMGDIR=${IMGDIR} MM_USERNAME=${MM_USERNAME} MM_GROUPNAME=${MM_GROUPNAME} -SUB_FILES= pkg-message pkg-install pkg-deinstall +SUB_FILES= pkg-message pkg-install pkg-deinstall mailman.newsyslog.sample SUB_LIST= MAILMANDIR=${MAILMANDIR} USER=${MM_USERNAME} GROUP=${MM_GROUPNAME} PYTHON_CMD="${PYTHON_CMD}" PORTDOCS= ACKNOWLEDGMENTS BUGS FAQ INSTALL NEWS README README-I18N.en \ @@ -83,6 +83,12 @@ MTA_DESC= Integrate with which MTA? .include <bsd.port.options.mk> +# enforce EXAMPLES option, necessary so that @sample +# can install the newsyslog file +.if empty(PORT_OPTIONS:MEXAMPLES) +PORT_OPTIONS+= EXAMPLES +.endif + .if ${PORT_OPTIONS:MNLS} USES+= gettext PLIST_SUB+= NLS="" @@ -170,6 +176,8 @@ pre-configure: .endif post-install: + ${MKDIR} ${STAGEDIR}${EXAMPLESDIR} + ${INSTALL_DATA} ${WRKDIR}/mailman.newsyslog.sample ${STAGEDIR}${EXAMPLESDIR} .for i in admindb admin confirm create edithtml listinfo options private \ rmlist roster subscribe ${STRIP_CMD} ${STAGEDIR}${MAILMANDIR}/cgi-bin/${i} diff --git a/mail/mailman/files/mailman.newsyslog.sample.in b/mail/mailman/files/mailman.newsyslog.sample.in new file mode 100644 index 000000000000..20c872eb75b4 --- /dev/null +++ b/mail/mailman/files/mailman.newsyslog.sample.in @@ -0,0 +1,11 @@ +# logfilename [owner:group] mode count size when flags [/pid_file] [sig_num] +%%MAILMANDIR%%/logs/bounce %%USER%%:%%GROUP%% 660 10 2000 * X %%MAILMANDIR%%/data/master-qrunner.pid +%%MAILMANDIR%%/logs/error %%USER%%:%%GROUP%% 660 10 2000 * X %%MAILMANDIR%%/data/master-qrunner.pid +%%MAILMANDIR%%/logs/locks %%USER%%:%%GROUP%% 660 10 2000 * X %%MAILMANDIR%%/data/master-qrunner.pid +%%MAILMANDIR%%/logs/mischief %%USER%%:%%GROUP%% 660 10 2000 * X %%MAILMANDIR%%/data/master-qrunner.pid +%%MAILMANDIR%%/logs/post %%USER%%:%%GROUP%% 660 10 2000 * X %%MAILMANDIR%%/data/master-qrunner.pid +%%MAILMANDIR%%/logs/qrunner %%USER%%:%%GROUP%% 660 10 2000 * X %%MAILMANDIR%%/data/master-qrunner.pid +%%MAILMANDIR%%/logs/smtp %%USER%%:%%GROUP%% 660 10 2000 * X %%MAILMANDIR%%/data/master-qrunner.pid +%%MAILMANDIR%%/logs/smtp-failure %%USER%%:%%GROUP%% 660 10 2000 * X %%MAILMANDIR%%/data/master-qrunner.pid +%%MAILMANDIR%%/logs/subscribe %%USER%%:%%GROUP%% 660 10 2000 * X %%MAILMANDIR%%/data/master-qrunner.pid +%%MAILMANDIR%%/logs/vette %%USER%%:%%GROUP%% 660 10 2000 * X %%MAILMANDIR%%/data/master-qrunner.pid diff --git a/mail/mailman/pkg-plist b/mail/mailman/pkg-plist index 10bf0889c441..24c6861ed94b 100644 --- a/mail/mailman/pkg-plist +++ b/mail/mailman/pkg-plist @@ -1,5 +1,7 @@ @postunexec if cmp -s %D/%%MMDIR%%/Mailman/mm_cfg.py %D/%%MMDIR%%/Mailman/mm_cfg.py.dist; then rm -f %D/%%MMDIR%%/Mailman/mm_cfg.py; fi @postunexec rm -f %D/%%MMDIR%%/Mailman/mm_cfg.pyc +@dir etc/newsyslog.conf.d +@sample %%EXAMPLESDIR%%/mailman.newsyslog.sample etc/newsyslog.conf.d/mailman.newsyslog %%IMGDIR%%/mailman-large.jpg %%IMGDIR%%/gnu-head-tiny.jpg %%IMGDIR%%/mailman.jpg |