Package: postfix
Version: 2.4.6-1
Severity: wishlist
Tags: patch

Attached is a patch which adds an LSB header and adds a status command
to the init script as recommended by LSB.  Read more about LSB init
scripts here:

http://refspecs.freestandards.org/LSB_3.1.0/LSB-Core-generic/LSB-Core-generic/iniscrptact.html

thanks,
stew

-- System Information:
Debian Release: lenny/sid
  APT prefers testing
  APT policy: (990, 'testing'), (500, 'unstable')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.21-2-amd64 (SMP w/2 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash

Versions of packages postfix depends on:
ii  adduser                  3.105           add and remove users and groups
ii  debconf [debconf-2.0]    1.5.14          Debian configuration management sy
ii  dpkg                     1.14.7          package maintenance system for Deb
ii  libc6                    2.6.1-1         GNU C Library: Shared libraries
ii  libdb4.6                 4.6.19-1        Berkeley v4.6 Database Libraries [
ii  libsasl2-2               2.1.22.dfsg1-14 Authentication abstraction library
ii  libssl0.9.8              0.9.8g-1        SSL shared libraries
ii  lsb-base                 3.1-24          Linux Standard Base 3.1 init scrip
ii  netbase                  4.30            Basic TCP/IP networking system
ii  ssl-cert                 1.0.14          Simple debconf wrapper for openssl

postfix recommends no packages.

-- debconf information excluded
diff -ruN postfix-2.4.6.orig/debian/init.d postfix-2.4.6/debian/init.d
--- postfix-2.4.6.orig/debian/init.d    2007-11-17 07:00:39.000000000 -0500
+++ postfix-2.4.6/debian/init.d 2007-11-17 07:12:11.000000000 -0500
@@ -5,6 +5,18 @@
 # LaMont Jones <[EMAIL PROTECTED]>
 # based on sendmail's init.d script
 
+### BEGIN INIT INFO
+# Provides:          postfix mail-transport-agent
+# Required-Start:    $local_fs $remote_fs $syslog $named $network $time
+# Required-Stop:     $local_fs $remote_fs $syslog $named $network
+# Should-Start:      postgresql mysql clamav-daemon postgrey spamassassin
+# Should-Stop:       postgresql mysql clamav-daemon postgrey spamassassin
+# Default-Start:     2 3 4 5
+# Default-Stop:      0 1 6
+# Short-Description: start and stop the Postfix Mail Transport Agent
+# Description:       postfix is a Mail Transport agent
+### END INIT INFO
+
 PATH=/bin:/usr/bin:/sbin:/usr/sbin
 DAEMON=/usr/sbin/postfix
 NAME=Postfix
@@ -107,6 +119,17 @@
        fi
     ;;
 
+    status)
+       RUNNING=$(running)
+       if [ -n "$RUNNING" ]; then
+           log_success_msg "postfix is running"
+           exit 0
+       else
+           log_success_msg "postfix is not running"
+           exit 3
+       fi
+    ;;
+
     flush|check|abort)
        ${DAEMON} $1
     ;;

Reply via email to