Hello community,

here is the log from the commit of package postfix for 
openSUSE:12.1:Update:Test checked in at 2011-12-14 17:43:06
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:12.1:Update:Test/postfix (Old)
 and      /work/SRC/openSUSE:12.1:Update:Test/.postfix.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "postfix", Maintainer is "[email protected]"

Changes:
--------
--- /work/SRC/openSUSE:12.1:Update:Test/postfix/postfix.changes 2011-12-05 
15:51:45.000000000 +0100
+++ /work/SRC/openSUSE:12.1:Update:Test/.postfix.new/postfix.changes    
2011-12-14 17:43:08.000000000 +0100
@@ -1,0 +2,10 @@
+Tue Dec 13 14:43:57 UTC 2011 - [email protected]
+
+- Move the post map rebuild script into the start script 
+
+-------------------------------------------------------------------
+Tue Dec  6 11:07:00 UTC 2011 - [email protected]
+
+- Fix the last change in %post 
+
+-------------------------------------------------------------------

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ postfix.spec ++++++
--- /var/tmp/diff_new_pack.6D36Pd/_old  2011-12-14 17:43:08.000000000 +0100
+++ /var/tmp/diff_new_pack.6D36Pd/_new  2011-12-14 17:43:08.000000000 +0100
@@ -303,6 +303,7 @@
 mkdir -p %{buildroot}/etc/postfix/system
 install -m 0644 %{name}-SuSE/postfix.service       
%{buildroot}/lib/systemd/system/
 install -m 0755 %{name}-SuSE/update_chroot.systemd 
%{buildroot}/etc/postfix/system/update_chroot
+install -m 0755 %{name}-SuSE/rebuild_tables.systemd 
%{buildroot}/etc/postfix/system/rebuild_tables
 install -m 0755 %{name}-SuSE/wait_qmgr.systemd     
%{buildroot}/etc/postfix/system/wait_qmgr
 install -m 0755 %{name}-SuSE/cond_slp.systemd      
%{buildroot}/etc/postfix/system/cond_slp
 %endif
@@ -402,14 +403,6 @@
                 ln -s /usr/sbin/SuSEconfig.postfix 
/sbin/conf.d/SuSEconfig.postfix
         fi
 fi
-# Update the postmaps
-for i in `ls /etc/postfix/*db`
-do
-    b=$( basename $i .db );
-    if [ -e /etc/postfix/$b -a /etc/postfix/$b -nt $i ]; then
-        postmap /etc/postfix/$b;
-    fi
-done
 # before fillup we need to fix something
 [ \! -f %{_sysconfdir}/sysconfig/%{name} ] || %{__sed} -i \
  -e "s/POSTFIX_SMTPD_SENDERNT_RESTRICTIONS/POSTFIX_SMTPD_SENDER_RESTRICTIONS/" 
\
@@ -493,6 +486,7 @@
 %if 0%{?suse_version} >= 1140
 %dir /etc/postfix/system
 %config %attr(0755,root,root) /etc/postfix/system/update_chroot
+%config %attr(0755,root,root) /etc/postfix/system/rebuild_tables
 %config %attr(0755,root,root) /etc/postfix/system/wait_qmgr
 %config %attr(0755,root,root) /etc/postfix/system/cond_slp
 %config /lib/systemd/system/postfix.service

++++++ postfix-SuSE.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/postfix-SuSE/postfix.service 
new/postfix-SuSE/postfix.service
--- old/postfix-SuSE/postfix.service    2011-08-12 17:35:38.000000000 +0200
+++ new/postfix-SuSE/postfix.service    2011-12-13 15:45:39.000000000 +0100
@@ -27,6 +27,7 @@
 ExecStartPre=-/bin/echo 'Starting mail service (Postfix)'
 EnvironmentFile=-/etc/sysconfig/postfix
 ExecStartPre=/etc/postfix/system/update_chroot
+ExecStartPre=/etc/postfix/system/rebuild_tables
 ExecStart=/usr/sbin/postfix start
 ExecStartPost=/etc/postfix/system/wait_qmgr 60
 ExecStartPost=/etc/postfix/system/cond_slp register
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/postfix-SuSE/rc.postfix new/postfix-SuSE/rc.postfix
--- old/postfix-SuSE/rc.postfix 2011-08-22 11:29:28.000000000 +0200
+++ new/postfix-SuSE/rc.postfix 2011-12-13 13:44:15.000000000 +0100
@@ -61,6 +61,21 @@
     fi
 }
 
+rebuild_tables() {
+        if [ -n "${POSTFIX_UPDATE_MAPS/[yY][Ee][Ss]/}" ]; then
+            return
+        fi
+        # Update the postmaps
+        for i in $POSTFIX_MAP_LIST; do
+            m=/etc/postfix/$i;
+            d=$m.db
+            test -e "$d" || continue;
+            if [ -e $m -a $m -nt $d ]; then
+                postmap $m;
+            fi
+        done
+}
+
 chk_mysql_sock(){
   if [ -n "$($print_defaults mysqld)" ]; then
     MYSQL_SOCKET=$($print_defaults mysqld | grep -e '--socket[[:blank:]=]' | 
awk -F"=" '{print $2}')
@@ -198,6 +213,7 @@
         ## the echo return value is set appropriate.
 
        if ! checkproc -p $PIDFILE $MASTER_BIN; then
+               rebuild_tables
                $POSTFIX_BIN start > /dev/null 2>&1
        else
                rc_reset
@@ -246,9 +262,10 @@
 
        echo -n "Reload mail service (Postfix)"
 
+       rebuild_tables
        $POSTFIX_BIN reload > /dev/null 2>&1
        rc_status -v
-       POSTFIX_BIN flush > /dev/null 2>&1
+       $POSTFIX_BIN flush > /dev/null 2>&1
 
        ## Otherwise:
        #$0 stop  &&  $0 start
@@ -257,6 +274,7 @@
     reload)
         echo -n "Reload mail service (Postfix)"
 
+       rebuild_tables
        $POSTFIX_BIN reload > /dev/null 2>&1
        rc_status -v
        $POSTFIX_BIN flush > /dev/null 2>&1
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/postfix-SuSE/rebuild_tables.systemd 
new/postfix-SuSE/rebuild_tables.systemd
--- old/postfix-SuSE/rebuild_tables.systemd     1970-01-01 01:00:00.000000000 
+0100
+++ new/postfix-SuSE/rebuild_tables.systemd     2011-12-13 15:37:18.000000000 
+0100
@@ -0,0 +1,24 @@
+#!/bin/bash
+# Copyright (c) 2011 SUSE LINUX Products AG
+#
+# Author: Peter Varkoly
+# Please send feedback to http://www.suse.de/feedback/
+#
+# /etc/postfix/system/rebuild_tables
+#
+
+test -f /etc/sysconfig/postfix && . /etc/sysconfig/postfix
+
+if [ -n "${POSTFIX_UPDATE_MAPS/[yY][Ee][Ss]/}" ]; then
+    return
+fi
+# Update the postmaps
+for i in $POSTFIX_MAP_LIST; do
+    m=/etc/postfix/$i;
+    d=$m.db
+    test -e "$d" || continue;
+    if [ -e $m -a $m -nt $d ]; then
+        postmap $m;
+    fi
+done
+

-- 
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to