postfix/rc.postfix

Tue, 28 Aug 2012 18:29:30 +0200

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Tue, 28 Aug 2012 18:29:30 +0200
changeset 534
d2d0020cfafa
permissions
-rw-r--r--

Update from Drupal 6.x to 7.x and introduce several new HTML5 themes. Because
many themes from Drupal 6.x have since been abandoned, left unmaintained, or
not ported to Drupal 7.x, this package has changed in size and utility.

     1 #!@l_prefix@/bin/openpkg rc
     2 ##
     3 ##  rc.postfix -- Run-Commands
     4 ##
     6 %config
     7     MTA_name="postfix"
     8     MTA_aliases_file="@l_prefix@/etc/postfix/aliases"
     9     MTA_aliases_update="cd @l_prefix@/etc/postfix && @l_prefix@/sbin/postalias aliases"
    10     postfix_enable="$openpkg_rc_def"
    11     postfix_log_prolog="true"
    12     postfix_log_epilog="true"
    13     postfix_log_numfiles="10"
    14     postfix_log_minsize="1M"
    15     postfix_log_complevel="9"
    16     postfix_sum_flags=""
    18 %status -u @l_susr@ -o
    19     postfix_usable="no"
    20     postfix_active="no"
    21     @l_prefix@/sbin/postfix check >/dev/null 2>&1 && postfix_usable="yes"
    22     @l_prefix@/libexec/postfix/master -t >/dev/null 2>&1 || postfix_active="yes"
    23     echo "postfix_enable=\"$postfix_enable\""
    24     echo "postfix_usable=\"$postfix_usable\""
    25     echo "postfix_active=\"$postfix_active\""
    27 %start -u @l_susr@
    28     rcService postfix enable yes || exit 0
    29     rcService postfix active yes && exit 0
    30     @l_prefix@/sbin/postfix start
    32 %stop -u @l_susr@
    33     rcService postfix enable yes || exit 0
    34     rcService postfix active no  && exit 0
    35     @l_prefix@/sbin/postfix stop
    36     sleep 2
    38 %restart -u @l_susr@
    39     rcService postfix enable yes || exit 0
    40     rcService postfix active no  && exit 0
    41     rc postfix stop start
    43 %reload -u @l_susr@
    44     rcService postfix enable yes || exit 0
    45     rcService postfix active no  && exit 0
    46     @l_prefix@/sbin/postfix reload
    48 %daily -u @l_susr@
    49     rcService postfix enable yes || exit 0
    51     #   rotate summary logfile
    52     shtool rotate -f \
    53         -n ${postfix_log_numfiles} -s 0 \
    54         -z ${postfix_log_complevel} -m 644 -o @l_musr@ -g @l_mgrp@ \
    55         @l_prefix@/var/postfix/log/postfix.sum
    57     #   generate summary logfile
    58     logfiles="@l_prefix@/var/postfix/log/postfix.log"
    59     if [ -f "@l_prefix@/var/postfix/log/postfix.log.0" ]; then
    60         logfiles="$logfiles @l_prefix@/var/postfix/log/postfix.log.0"
    61     fi
    62     @l_prefix@/sbin/pflogsumm -d yesterday -h 10 -u 10 -i \
    63         --iso_date_time --problems_first --smtpd_stats --verbose_msg_detail \
    64         ${postfix_sum_flags} \
    65         ${logfiles} >@l_prefix@/var/postfix/log/postfix.sum 2>/dev/null
    67     #   rotate logfile
    68     shtool rotate -f \
    69         -n ${postfix_log_numfiles} -s ${postfix_log_minsize} -d \
    70         -z ${postfix_log_complevel} -m 644 -o @l_musr@ -g @l_mgrp@ \
    71         -P "$postfix_log_prolog" \
    72         -E "$postfix_log_epilog" \
    73         @l_prefix@/var/postfix/log/postfix.log

mercurial