fix re-adding duplicated configuration blocks in post script [release 2.12.2-2mamba;Sat Jan 28 2023]
This commit is contained in:
parent
b74c98e7bb
commit
9270d397a5
@ -3,7 +3,7 @@
|
||||
|
||||
Name: amavisd-new
|
||||
Version: 2.12.2
|
||||
Release: 1mamba
|
||||
Release: 2mamba
|
||||
Summary: An interface between mailer (MTA) and content checkers: virus scanners, and/or SpamAssassin
|
||||
Group: System/Servers
|
||||
Vendor: openmamba
|
||||
@ -80,9 +80,6 @@ install -D -m0644 %{SOURCE1} %{buildroot}%{_unitdir}/amavisd.service
|
||||
%systemd_postun_with_restart amavisd
|
||||
|
||||
%pre
|
||||
if [ $1 -gt 1 ]; then
|
||||
/sbin/chkconfig --del amavisd 2>/dev/null
|
||||
fi
|
||||
if [ $1 -ge 1 ]; then
|
||||
/usr/sbin/groupadd vscan -g %{vscan_gid} 2>/dev/null
|
||||
/usr/sbin/useradd -u %{vscan_uid} -c 'Virus Scan user' -d /var/amavis -g vscan -s /bin/false vscan 2>/dev/null
|
||||
@ -98,9 +95,9 @@ if [ $1 -ge 1 ]; then
|
||||
sed -i "s|# \$mydomain = .*|\$mydomain = '$DOMAIN';|" %{_sysconfdir}/amavisd.conf
|
||||
postconf -e "strict_rfc821_envelopes = yes"
|
||||
sudo postconf -e "content_filter = smtp-amavis:[127.0.0.1]:10024"
|
||||
[ "`grep amavisfeed %{_sysconfdir}/postfix/master.cf`" ] || {
|
||||
grep -q amavisd %{_sysconfdir}/postfix/master.cf || {
|
||||
cat >> %{_sysconfdir}/postfix/master.cf << _EOF
|
||||
# BEGIN of amavaisd-new configuration
|
||||
# BEGIN of amavisd-new configuration
|
||||
smtp-amavis unix - - n - 2 smtp
|
||||
-o smtp_data_done_timeout=1200
|
||||
-o smtp_send_xforward_command=yes
|
||||
@ -132,7 +129,7 @@ _EOF
|
||||
postfix reload
|
||||
}
|
||||
fi
|
||||
exit 0
|
||||
:
|
||||
|
||||
%preun
|
||||
%systemd_preun amavisd
|
||||
@ -140,7 +137,7 @@ if [ $1 -eq 0 ]; then
|
||||
/usr/sbin/userdel vscan 2>/dev/null
|
||||
/usr/sbin/groupdel vscan 2>/dev/null
|
||||
fi
|
||||
exit 0
|
||||
:
|
||||
|
||||
%files
|
||||
%defattr(-,root,root)
|
||||
@ -152,6 +149,9 @@ exit 0
|
||||
%doc LICENSE TODO
|
||||
|
||||
%changelog
|
||||
* Sat Jan 28 2023 Silvan Calarco <silvan.calarco@mambasoft.it> 2.12.2-2mamba
|
||||
- fix re-adding duplicated configuration blocks in post script
|
||||
|
||||
* Wed Dec 29 2021 Automatic Build System <autodist@mambasoft.it> 2.12.2-1mamba
|
||||
- automatic version update by autodist
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user