--- rpms/smeserver-geoip/contribs9/smeserver-geoip.spec 2018/06/19 13:20:57 1.8 +++ rpms/smeserver-geoip/contribs9/smeserver-geoip.spec 2019/01/05 05:03:30 1.11 @@ -1,6 +1,6 @@ %define name smeserver-geoip %define version 1.2 -%define release 1 +%define release 4 Summary: SME Server geoip plugin Name: %{name} @@ -12,10 +12,10 @@ Source: %{name}-%{version}.tar.gz Packager: Doug Kruhm BuildRoot: /var/tmp/%{name}-%{version}-%{release}-buildroot BuildArchitectures: noarch -Requires: perl-GeoIP2 Requires: GeoIP >= 1.6.5 BuildRequires: e-smith-devtools >= 1.13.1-03 -#Patch0: smeserver-geoip-remove-createlink-add-geoip-download-actions.patch +Patch0: smeserver-geoip-conf-typo.patch +Patch1: smeserver-geoip-fix-city-createlinks.patch %description The GEOIP plugin lets us know which country our mail server is receiving mail from. If we're receiving too much spam from a particular country, this will help track it down and then use that info to reject connections from that country. This ends up taking the load off our servers. @@ -23,7 +23,49 @@ The GEOIP plugin lets us know which coun CHANGE THE CONFIG DB: config setprop qpsmtpd BadCountries (i.e. config setprop qpsmtpd BadCountries BR) SIGNAL EVENT: signal-event email-update +#---------------------------------------------------- + +%package -n smeserver-geoip1 +Summary: SME Server geoip plugin v1 +Group: Email +Requires: perl-Geo-IP +Requires: GeoIP >= 1.6.5 +BuildRequires: e-smith-devtools >= 1.13.1-03 + +%description -n smeserver-geoip1 +The GEOIP plugin lets us know which country our mail server is receiving mail from. If we're receiving too much spam from a particular country, this will help track it down and then use that info to reject connections from that country. This ends up taking the load off our servers. + +CHANGE THE CONFIG DB: config setprop qpsmtpd BadCountries (i.e. config setprop qpsmtpd BadCountries BR) +SIGNAL EVENT: signal-event email-update +#---------------------------------------------------- + +%package -n smeserver-geoip2 +Summary: SME Server geoip plugin v2 +Group: Email +Requires: perl-GeoIP2 +Requires: GeoIP >= 1.6.5 +BuildRequires: e-smith-devtools >= 1.13.1-03 + + +%description -n smeserver-geoip2 +The GEOIP plugin lets us know which country our mail server is receiving mail from. If we're receiving too much spam from a particular country, this will help track it down and then use that info to reject connections from that country. This ends up taking the load off our servers. + +CHANGE THE CONFIG DB: config setprop qpsmtpd BadCountries (i.e. config setprop qpsmtpd BadCountries BR) +SIGNAL EVENT: signal-event email-update +#---------------------------------------------------- + %changelog +* Fri Jan 04 2019 Jean-Philipe Pialasse 1.2-4.sme +- split smeserver-geoip into smeservergeoip and smeserver-geoip2 for compatibility [SME: 10691] +- workaround to find for plugin compatibility + +* Mon Oct 29 2018 John Crisp 1.2-3.sme +- Fix Use of uninitialized value $city in string eq +- Fix createlinks geoip-update action + +* Sat Jun 23 2018 John Crisp 1.2-2.sme +- Fix typo in createlinks + * Tue Jun 12 2018 John Crisp 1.2-1.sme - Update to latest v2 DBs [SME: 9033] - add geocity.pl and geocountry.pl test files @@ -69,7 +111,8 @@ SIGNAL EVENT: signal-event email-update %prep %setup -#%patch0 -p1 +%patch0 -p1 +%patch1 -p1 %build %{__mkdir_p} root/var/lib/GeoIP @@ -81,6 +124,14 @@ rm -rf $RPM_BUILD_ROOT rm -f %{name}-%{version}-filelist /sbin/e-smith/genfilelist $RPM_BUILD_ROOT > %{name}-%{version}-filelist +cat %{name}-%{version}-filelist \ +|grep -v 'etc/e-smith/templates/etc/GeoIP.conf' \ +|grep -v 'usr/bin/geocity.pl' \ +|grep -v 'usr/bin/geocountry.pl'\ +|grep -v 'smeserver-geopip-download-action' \ +|grep -v 'templates2expand/etc/GeoIP.conf' \ + > %{name}-%{version}-filelist-v1 + %clean rm -rf $RPM_BUILD_ROOT @@ -88,5 +139,16 @@ rm -rf $RPM_BUILD_ROOT %postun -%files -f %{name}-%{version}-filelist +%files -f %{name}-%{version}-filelist-v1 %defattr(-,root,root) + + + +%files -n smeserver-geoip2 -f %{name}-%{version}-filelist +%defattr(-,root,root,-) + +%files -n smeserver-geoip1 -f %{name}-%{version}-filelist-v1 +%defattr(-,root,root,-) + + +