From 28587b814b10d30b11143cca3d86e83fc37d1e45 Mon Sep 17 00:00:00 2001 From: David Sommerseth Date: Fri, 12 May 2017 01:17:29 +0200 Subject: [PATCH] Install and take ownership of a few more directories - rhbz#1444601 /run/openvpn-client using %{_rundir} /run/openvpn-server - rhbz#922786 /var/lib/openvpn using %{_sharedstatedir} --- openvpn.spec | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/openvpn.spec b/openvpn.spec index 93bd138..576346f 100644 --- a/openvpn.spec +++ b/openvpn.spec @@ -7,7 +7,7 @@ Name: openvpn Version: 2.4.2 -Release: 1%{?prerelease:.%{prerelease}}%{?dist} +Release: 2%{?prerelease:.%{prerelease}}%{?dist} Summary: A full-featured SSL VPN solution URL: https://community.openvpn.net/ Source0: https://swupdate.openvpn.org/community/releases/%{name}-%{version}%{?prerelease:_%{prerelease}}.tar.xz @@ -120,6 +120,10 @@ find $RPM_BUILD_ROOT -name '*.la' | xargs rm -f mkdir -p -m 0750 $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/client $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/server cp %{SOURCE2} %{SOURCE3} sample/sample-config-files/ +# Create some directories the OpenVPN package should own +mkdir -m 0710 -p $RPM_BUILD_ROOT%{_rundir}/%{name}-{client,server} +mkdir -m 0770 -p $RPM_BUILD_ROOT%{_sharedstatedir}/%{name} + # Package installs into %%{_pkgdocdir} directly # Add further files cp -a AUTHORS contrib sample %{SOURCE4} $RPM_BUILD_ROOT%{_pkgdocdir} @@ -163,6 +167,9 @@ getent passwd openvpn &>/dev/null || \ %config %dir %{_sysconfdir}/%{name}/ %config %dir %{_sysconfdir}/%{name}/client %config %dir %{_sysconfdir}/%{name}/server +%attr(0710,-,-) %{_rundir}/%{name}-client +%attr(0710,-,-) %{_rundir}/%{name}-server +%attr(0770,openvpn,openvpn) %{_sharedstatedir}/%{name} %files devel %{_pkgdocdir}/sample/sample-plugins @@ -171,6 +178,10 @@ getent passwd openvpn &>/dev/null || \ %changelog +* Fri May 12 2017 David Sommerseth - 2.4.2-2 +- Install and take ownership of /run/openvpn-{client,server} (rhbz#1444601) +- Install and take ownership of /var/lib/openvpn (rhbz#922786) + * Thu May 11 2017 David Sommerseth - 2.4.2-1 - Switching back to OpenSSL, using compat-openssl10 (rhbz#1443749, rhbz#1432125, rhbz#1440468) - Re-enabling --enable-x509-alt-username (rhbz#1443942)