summaryrefslogtreecommitdiffstats
path: root/centos/rspamd.spec
diff options
context:
space:
mode:
authorAndrew Lewis <nerf@judo.za.org>2015-03-12 08:05:57 +0200
committerAndrew Lewis <nerf@judo.za.org>2015-03-12 08:21:48 +0200
commitfb122509cfd3e12ef2078a061872f6db222c1b05 (patch)
treee2c44331b6187d0a4880eaa2edeb11acbf84d3ac /centos/rspamd.spec
parent71a8799f17f8a00bc681e07dbdbb82c165ec0163 (diff)
downloadrspamd-fb122509cfd3e12ef2078a061872f6db222c1b05.tar.gz
rspamd-fb122509cfd3e12ef2078a061872f6db222c1b05.zip
RPM: Patch systemd service for CentOS7 & fix broken filesystem attributes
Diffstat (limited to 'centos/rspamd.spec')
-rw-r--r--centos/rspamd.spec12
1 files changed, 7 insertions, 5 deletions
diff --git a/centos/rspamd.spec b/centos/rspamd.spec
index cc548fab7..c9d539182 100644
--- a/centos/rspamd.spec
+++ b/centos/rspamd.spec
@@ -55,10 +55,10 @@ Source0: https://rspamd.com/downloads/%{name}-%{version}.tar.xz
%if 0%{?el6}
Source1: %{name}.init
Source2: %{name}.logrotate
-%else
-Source3: %{name}.service
%endif
+Patch0: %{name}.service.patch
+
%description
Rspamd is a rapid, modular and lightweight spam filter. It is designed to work
with big amount of mail and can be easily extended with own filters written in
@@ -97,8 +97,6 @@ lua.
%{__install} -d -p -m 0755 %{buildroot}%{_localstatedir}/run/rspamd
%{__install} -p -D -m 0644 %{SOURCE2} %{buildroot}%{_sysconfdir}/logrotate.d/%{name}
%{__install} -d -p -m 0755 %{buildroot}%{rspamd_logdir}
-%else
-%{__install} -p -D -m 0644 %{SOURCE3} %{buildroot}%{_unitdir}/%{name}.service
%endif
%{__install} -d -p -m 0755 %{buildroot}%{rspamd_home}
@@ -115,6 +113,10 @@ rm -rf %{buildroot}
%service_add_pre %{name}.socket
%endif
+%if 0%{?el7}
+%patch0 -p0
+%endif
+
%post
%if 0%{?suse_version}
%service_add_post %{name}.service
@@ -191,7 +193,7 @@ fi
%if 0%{?el6}
%dir %{rspamd_logdir}
%endif
-%attr(-, rspamd, rspamd) %dir %{rspamd_home}
+%attr(-, _rspamd, _rspamd) %dir %{rspamd_home}
%dir %{rspamd_confdir}/lua/regexp
%dir %{rspamd_confdir}/lua
%dir %{rspamd_confdir}