1 |
%define name smeserver-geoip |
%define name smeserver-geoip |
2 |
%define version 1.2 |
%define version 1.2 |
3 |
%define release 5 |
%define release 10 |
4 |
|
|
5 |
Summary: SME Server geoip plugin |
Summary: SME Server geoip plugin |
6 |
Name: %{name} |
Name: %{name} |
17 |
Patch0: smeserver-geoip-conf-typo.patch |
Patch0: smeserver-geoip-conf-typo.patch |
18 |
Patch1: smeserver-geoip-fix-city-createlinks.patch |
Patch1: smeserver-geoip-fix-city-createlinks.patch |
19 |
Patch2: smeserver-geoip-1.2-check_badcountries.patch |
Patch2: smeserver-geoip-1.2-check_badcountries.patch |
20 |
|
Patch3: smeserver-geoip-1.2-check_badcountries-mailstats.patch |
21 |
|
Patch4: smeserver-geoip-1.2-bz10820-geoipv1-blockvountries-qpsmtpd.patch |
22 |
|
Patch5: smeserver-geoip-1.2-bz10815-display-country.patch |
23 |
|
|
24 |
%description |
%description |
25 |
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. |
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. |
46 |
%package -n smeserver-geoip2 |
%package -n smeserver-geoip2 |
47 |
Summary: SME Server geoip plugin v2 |
Summary: SME Server geoip plugin v2 |
48 |
Group: Email |
Group: Email |
49 |
|
Requires: smeserver-geoip |
50 |
Requires: perl-GeoIP2 |
Requires: perl-GeoIP2 |
51 |
Requires: GeoIP >= 1.6.5 |
Requires: GeoIP >= 1.6.5 |
52 |
BuildRequires: e-smith-devtools >= 1.13.1-03 |
BuildRequires: e-smith-devtools >= 1.13.1-03 |
60 |
#---------------------------------------------------- |
#---------------------------------------------------- |
61 |
|
|
62 |
%changelog |
%changelog |
63 |
|
* Sun Oct 20 2019 Jean-Philipe Pialasse <tests@pialasse.com> 1.2-10.sme |
64 |
|
- fix country not logged if no badcountries defined [SME: 10815] |
65 |
|
|
66 |
|
* Fri Oct 18 2019 Jean-Philipe Pialasse <tests@pialasse.com> 1.2-9.sme |
67 |
|
- revert blocking country for geoipv1 qpsmtpd plugin [SME: 10820] |
68 |
|
|
69 |
|
* Thu Jan 24 2019 Jean-Philipe Pialasse <tests@pialasse.com> 1.2-8.sme |
70 |
|
- make smeserver-geoip2 requires smeserver-geoip [SME: 10691] |
71 |
|
this will avoid having both packages sharing few files. |
72 |
|
|
73 |
|
* Tue Jan 15 2019 John Crisp <jcrisp@safeandsoundit.co.uk> 1.2-7.sme |
74 |
|
- Update check_badcountries to work with mailstats |
75 |
|
|
76 |
|
* Sat Jan 05 2019 Jean-Philipe Pialasse <tests@pialasse.com> 1.2-6.sme |
77 |
|
- remove crontab fragment for v1 [SME: 10691] |
78 |
|
|
79 |
* Sat Jan 05 2019 Jean-Philipe Pialasse <tests@pialasse.com> 1.2-5.sme |
* Sat Jan 05 2019 Jean-Philipe Pialasse <tests@pialasse.com> 1.2-5.sme |
80 |
- fix wrong loglevel LOGINFO instead of LOGNOTICE needed [SME: 10679] |
- fix wrong loglevel LOGINFO instead of LOGNOTICE needed [SME: 10679] |
81 |
- try first db v2 and back on v1 if not available [SME: 10691] |
- try first db v2 and back on v1 if not available [SME: 10691] |
140 |
%patch0 -p1 |
%patch0 -p1 |
141 |
%patch1 -p1 |
%patch1 -p1 |
142 |
%patch2 -p1 |
%patch2 -p1 |
143 |
|
%patch3 -p1 |
144 |
|
%patch4 -p1 |
145 |
|
%patch5 -p1 |
146 |
|
|
147 |
%build |
%build |
148 |
%{__mkdir_p} root/var/lib/GeoIP |
%{__mkdir_p} root/var/lib/GeoIP |
160 |
|grep -v 'usr/bin/geocountry.pl'\ |
|grep -v 'usr/bin/geocountry.pl'\ |
161 |
|grep -v 'smeserver-geopip-download-action' \ |
|grep -v 'smeserver-geopip-download-action' \ |
162 |
|grep -v 'templates2expand/etc/GeoIP.conf' \ |
|grep -v 'templates2expand/etc/GeoIP.conf' \ |
163 |
|
|grep -v '/etc/crontab/91_Update_Geoip_db' \ |
164 |
> %{name}-%{version}-filelist-v1 |
> %{name}-%{version}-filelist-v1 |
165 |
|
diff -u %{name}-%{version}-filelist %{name}-%{version}-filelist-v1 | grep -E "^\-"| sed -E 's/^\-//'|grep -v filelist > %{name}-%{version}-filelist-v2 |
166 |
|
|
167 |
%clean |
%clean |
168 |
rm -rf $RPM_BUILD_ROOT |
rm -rf $RPM_BUILD_ROOT |
176 |
|
|
177 |
|
|
178 |
|
|
179 |
%files -n smeserver-geoip2 -f %{name}-%{version}-filelist |
%files -n smeserver-geoip2 -f %{name}-%{version}-filelist-v2 |
180 |
%defattr(-,root,root,-) |
%defattr(-,root,root,-) |
181 |
|
|
182 |
%files -n smeserver-geoip1 -f %{name}-%{version}-filelist-v1 |
%files -n smeserver-geoip1 -f %{name}-%{version}-filelist-v1 |