[Lunar-commits] <moonbase-other> mailman, logwatch: Resurrecting modules
Stefan Wold
ratler at lunar-linux.org
Sun Sep 2 11:00:24 CEST 2012
commit 6786a8c56d0b54420c43ca61b981d72ec4d48550
Author: Stefan Wold <ratler at lunar-linux.org>
Date: Sun, 02 Sep 2012 02:00:24 -0700
URL: https://github.com/lunar-linux/moonbase-other/commit/6786a8c56d0b54420c43ca61b981d72ec4d48550
mailman, logwatch: Resurrecting modules
---
mail/mailman/BUILD +26/-0
mail/mailman/CONFIGURE +75/-0
mail/mailman/DEPENDS +7/-0
mail/mailman/DETAILS +21/-0
mail/mailman/POST_INSTALL +10/-0
security/logwatch/BUILD +7/-0
security/logwatch/DEPENDS +2/-0
security/logwatch/DETAILS +17/-0
8 files changed, 165 insertions (+), 0 deletions (-)
--- /dev/null
+++ b/mail/mailman/BUILD
@@ -0,0 +1,26 @@
+(
+
+ add_priv_user mailman:mailman
+
+ mkdir /var/mailman 2>/dev/null
+ chown mailman.mailman /var/mailman 2>/dev/null
+ chmod 02775 /var/mailman 2>/dev/null
+
+ ./configure --prefix=/var/mailman \
+ --with-var-prefix=/var/mailman \
+ --with-username=mailman \
+ --with-groupname=mailman \
+ --with-python=/usr/bin/python \
+ --with-mail-gid=$MAIL_GID \
+ --with-cgi-gid=$MAILMAN_GID &&
+
+ make "CC=gcc" \
+ "OPT=$CFLAGS" \
+ "AUXLIBS=$AUXLIBS" \
+ "CCARGS=CCARGS" &&
+
+ prepare_install &&
+ make install
+
+) > $C_FIFO 2>&1
+
--- /dev/null
+++ b/mail/mailman/CONFIGURE
@@ -0,0 +1,75 @@
+# Read the config so we can show the user what is currently set
+. $MODULE_CONFIG
+
+###############################################
+# Mailmain CGI GID
+###############################################
+GET_GID=0
+if ! grep -q "MAILMAN_GID" $MODULE_CONFIG; then
+ if query "Do you want a custom CGI script group for the mailman (must match apache)?" n; then
+ GET_GID=1
+ else
+ MAILMAN_GID="nogroup"
+ echo "MAILMAN_GID=$MAILMAN_GID" >> $MODULE_CONFIG
+ fi
+else
+ if query "Change custom CGI group for mailman ($MAILMAN_GID)?" n; then
+ GET_GID=1
+ fi
+fi
+
+if [ "$GET_GID" == "1" ]; then
+ IS_THIS_CORRECT=0
+ while [ "$IS_THIS_CORRECT" == "0" ]; do
+ echo -en "${MODULE_COLOR}${MODULE}${DEFAULT_COLOR}: ${QUERY_COLOR}Enter group name:${DEFAULT_COLOR} "
+ read -e MAILMAN_GID
+ if [ "$MAILMAN_GID" == "" ]; then
+ message "${MODULE_COLOR}${MODULE}:${PROBLEM_COLOR} ! Error: mailman group name cannot be blank${DEFAULT_COLOR}"
+ else
+ if ! grep "^$MAILMAN_GID:.*$" /etc/group; then
+ message "${MODULE_COLOR}${MODULE}:${PROBLEM_COLOR} ! WARNING: group '$MAILMAN_GID' does not exist.${DEFAULT_COLOR}"
+ fi
+ if query "Is '$MAILMAN_GID' correct?" y; then
+ IS_THIS_CORRECT=1
+ fi
+ fi
+ done
+ echo "MAILMAN_GID=$MAILMAN_GID" >> $MODULE_CONFIG
+fi
+
+###############################################
+# Mailmain MAIL GID
+###############################################
+GET_GID=0
+if ! grep -q "MAIL_GID" $MODULE_CONFIG; then
+ if query "Do you want a custom MAIL group for mailman (must match mail server)?" n; then
+ GET_GID=1
+ else
+ MAIL_GID=$(id -g nobody)
+ echo "MAIL_GID=$MAIL_GID" >> $MODULE_CONFIG
+ fi
+else
+ if query "Change custom MAIL group for mailman ($MAIL_GID)?" n; then
+ GET_GID=1
+ fi
+fi
+
+if [ "$GET_GID" == "1" ]; then
+ IS_THIS_CORRECT=0
+ while [ "$IS_THIS_CORRECT" == "0" ]; do
+ echo -en "${MODULE_COLOR}${MODULE}${DEFAULT_COLOR}: ${QUERY_COLOR}Enter group name:${DEFAULT_COLOR} "
+ read -e MAIL_GID
+ if [ "$MAIL_GID" == "" ]; then
+ message "${MODULE_COLOR}${MODULE}:${PROBLEM_COLOR} ! Error: mailman group name cannot be blank${DEFAULT_COLOR}"
+ else
+ if ! grep "^$MAIL_GID:.*$" /etc/group; then
+ message "${MODULE_COLOR}${MODULE}:${PROBLEM_COLOR} ! WARNING: group '$MAIL_GID' does not exist.${DEFAULT_COLOR}"
+ fi
+ if query "Is '$MAIL_GID' correct?" y; then
+ IS_THIS_CORRECT=1
+ fi
+ fi
+ done
+ echo "MAIL_GID=$MAIL_GID" >> $MODULE_CONFIG
+fi
+
--- /dev/null
+++ b/mail/mailman/DEPENDS
@@ -0,0 +1,7 @@
+depends Python
+
+optional_depends httpd "" "" "(a web server is required)"
+optional_depends apache "" "" "(a web server is required)"
+optional_depends apache-mod_ssl "" "" "(a web server is required)"
+optional_depends postfix "" "" "(an MTA is required)"
+optional_depends exim "" "" "(an MTA is required)"
--- /dev/null
+++ b/mail/mailman/DETAILS
@@ -0,0 +1,21 @@
+ MODULE=mailman
+ VERSION=2.1.14
+ SOURCE=$MODULE-$VERSION.tgz
+ SOURCE_URL=$GNU_URL/$MODULE
+ SOURCE_VFY=sha1:c92de1a5ee2d8b0c83d29836b35bd422116c96f4
+ WEB_SITE=http://mailman.sourceforge.net
+ ENTERED=20020303
+ UPDATED=20100922
+ SHORT="Software to help manage electronic mail discussion lists"
+ PSAFE=no
+
+cat << EOF
+Mailman is software to help manage electronic mail discussion lists,
+much like Majordomo or Smartmail. Mailman gives each mailing list
+a unique web page and allows users to subscribe, unsubscribe, and
+change their account options over the web. Even the list manager can
+administer his or her list entirely via the web. Mailman has most of
+the features that people want in a mailing list management system,
+including built-in archiving, mail-to-news gateways, spam filters,
+bounce detection, digest delivery, and so on.
+EOF
--- /dev/null
+++ b/mail/mailman/POST_INSTALL
@@ -0,0 +1,10 @@
+crontab -u mailman /var/mailman/cron/crontab.in
+cp /var/mailman/scripts/mailman /etc/init.d/mailman
+
+if [ ! -d /var/mailman/lists/mailman ]; then
+ /var/mailman/bin/newlist -q mailman postmaster@`hostname` password
+ echo "Do not forget to add the aliases for the mailman list"
+fi
+
+/etc/init.d/mailman start
+/sbin/chkconfig --add mailman
--- /dev/null
+++ b/security/logwatch/BUILD
@@ -0,0 +1,7 @@
+(
+
+ sedit 's:mailer = /bin/mail:mailer = /usr/bin/mail:' conf/logwatch.conf &&
+ prepare_install &&
+ yes '' | bash install_logwatch.sh
+
+) > $C_FIFO 2>&1
--- /dev/null
+++ b/security/logwatch/DEPENDS
@@ -0,0 +1,2 @@
+depends heirloom-mailx
+depends perl
--- /dev/null
+++ b/security/logwatch/DETAILS
@@ -0,0 +1,17 @@
+ MODULE=logwatch
+ VERSION=7.4.0
+ SOURCE=$MODULE-$VERSION.tar.gz
+ SOURCE_URL=$SFORGE_URL/logwatch
+ WEB_SITE=http://www.logwatch.org
+ SOURCE_VFY=sha1:c0a07cf92e99fd48281e53fdaaef7cea72ca11f7
+ ENTERED=20040913
+ UPDATED=20110304
+ SHORT="Monitor log files realtime"
+
+cat << EOF
+Logwatch is a customizable log analysis system. Logwatch parses
+through your system's logs for a given period of time and creates
+a report analyzing areas that you specify, in as much detail as you
+require. Logwatch is easy to use and will work right out of the package
+on most systems.
+EOF
More information about the Lunar-commits
mailing list