postfix-mailgraph/postfix-mailgraph.spec

changeset 536
94aa9476a1c1
parent 235
8b7e29d77c37
equal deleted inserted replaced
4:fa06e7ae03fc 5:bb86d4b5b390
30 Distribution: OpenPKG Community 30 Distribution: OpenPKG Community
31 Class: EVAL 31 Class: EVAL
32 Group: Mail 32 Group: Mail
33 License: GPL 33 License: GPL
34 Version: 1.14 34 Version: 1.14
35 Release: 20091101 35 Release: 20091102
36 36
37 # list of sources 37 # list of sources
38 Source0: http://mailgraph.schweikert.ch/pub/mailgraph-%{version}.tar.gz 38 Source0: http://mailgraph.schweikert.ch/pub/mailgraph-%{version}.tar.gz
39 Source1: rc.postfix-mailgraph 39 Source1: rc.postfix-mailgraph
40 Patch0: postfix-mailgraph.patch 40 Patch0: postfix-mailgraph.patch
99 %files -f files 99 %files -f files
100 100
101 %clean 101 %clean
102 rm -rf $RPM_BUILD_ROOT 102 rm -rf $RPM_BUILD_ROOT
103 103
104 %post
105 # after upgrade, restart service
106 [ $1 -eq 2 ] || exit 0
107 eval `%{l_rc} postfix-mailgraph status 2>/dev/null`
108 [ ".$postfix_mailgraph_active" = .yes ] && %{l_rc} postfix-mailgraph restart
109 exit 0
110
111 %preun
112 # before erase, stop service and remove log files
113 [ $1 -eq 0 ] || exit 0
114 %{l_rc} postfix-mailgraph stop 2>/dev/null
115 rm -f $RPM_INSTALL_PREFIX/var/postfix-mailgraph/run/*.log* >/dev/null 2>&1 || true
116 rm -f $RPM_INSTALL_PREFIX/var/postfix-mailgraph/run/*.pid >/dev/null 2>&1 || true
117 exit 0
118

mercurial