]> source.dussan.org Git - rspamd.git/commitdiff
[Minor] RPM/DEB: fix log directory ownership on systemd platforms
authorAndrew Lewis <nerf@judo.za.org>
Sun, 11 Jun 2017 20:28:25 +0000 (22:28 +0200)
committerAndrew Lewis <nerf@judo.za.org>
Sun, 11 Jun 2017 20:28:25 +0000 (22:28 +0200)
centos/rspamd.spec
debian/rules

index 0e7819c0b3612d3571457999873c56f08e61eb75..125682e9148f024c216a0c5e36769cfcc443a1d4 100644 (file)
@@ -110,9 +110,13 @@ lua.
 %if 0%{?el6}
 %{__install} -p -D -m 0755 %{SOURCE1} %{buildroot}%{_initrddir}/%{name}
 %{__install} -d -p -m 0755 %{buildroot}%{_localstatedir}/run/rspamd
-%endif
 %{__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 %{SOURCE2} %{buildroot}%{_sysconfdir}/logrotate.d/%{name}
+%{__install} -d -p -m 0755 %{buildroot}%{rspamd_logdir}
+%{__chown} %{rspamd_user}:%{rspamd_group} %{buildroot}%{rspamd_logdir}
+%endif
 
 %{__install} -d -p -m 0755 %{buildroot}%{rspamd_home}
 %{__install} -p -D -d -m 0755 %{buildroot}%{_sysconfdir}/%{name}/local.d/
index 224478f32753cad1dda3f17ee422a4d9e89a7421..b512a6576e1a1f325a9ef1c733c743fda1fd375f 100755 (executable)
@@ -47,3 +47,4 @@ override_dh_auto_clean:
 override_dh_fixperms:
        dh_fixperms
        chmod 750 $(CURDIR)/debian/rspamd/var/lib/rspamd
+       chmod 750 $(CURDIR)/debian/rspamd/var/log/rspamd