Use systemd-sysusers
Resolves: RHEL-4901 Signed-off-by: Rafael Guterres Jeffman <rjeffman@redhat.com>
This commit is contained in:
parent
b28c050483
commit
dd5ed19c75
1
softhsm-sysusers.conf
Normal file
1
softhsm-sysusers.conf
Normal file
@ -0,0 +1 @@
|
|||||||
|
u ods - "opendnssec daemon account"
|
19
softhsm.spec
19
softhsm.spec
@ -4,11 +4,12 @@
|
|||||||
Summary: Software version of a PKCS#11 Hardware Security Module
|
Summary: Software version of a PKCS#11 Hardware Security Module
|
||||||
Name: softhsm
|
Name: softhsm
|
||||||
Version: 2.6.1
|
Version: 2.6.1
|
||||||
Release: %{?prever:0.}14%{?prever:.%{prever}}%{?dist}.1
|
Release: %{?prever:0.}15%{?prever:.%{prever}}%{?dist}
|
||||||
License: BSD
|
License: BSD
|
||||||
Url: http://www.opendnssec.org/
|
Url: http://www.opendnssec.org/
|
||||||
Source: http://dist.opendnssec.org/source/%{?prever:testing/}%{name}-%{version}.tar.gz
|
Source: http://dist.opendnssec.org/source/%{?prever:testing/}%{name}-%{version}.tar.gz
|
||||||
Source1: http://dist.opendnssec.org/source/%{?prever:testing/}%{name}-%{version}.tar.gz.sig
|
Source1: http://dist.opendnssec.org/source/%{?prever:testing/}%{name}-%{version}.tar.gz.sig
|
||||||
|
Source2: softhsm-sysusers.conf
|
||||||
|
|
||||||
Patch1: softhsm-2.6.1-rh1831086-exit.patch
|
Patch1: softhsm-2.6.1-rh1831086-exit.patch
|
||||||
Patch2: softhsm-openssl3-tests.patch
|
Patch2: softhsm-openssl3-tests.patch
|
||||||
@ -75,6 +76,8 @@ autoreconf -fiv
|
|||||||
rm -rf %{buildroot}
|
rm -rf %{buildroot}
|
||||||
%make_install
|
%make_install
|
||||||
|
|
||||||
|
install -D %{SOURCE2} %{buildroot}%{_sysusersdir}/%{name}.conf
|
||||||
|
|
||||||
rm %{buildroot}/%{_sysconfdir}/softhsm2.conf.sample
|
rm %{buildroot}/%{_sysconfdir}/softhsm2.conf.sample
|
||||||
rm -f %{buildroot}/%{_libdir}/pkcs11/*a
|
rm -f %{buildroot}/%{_libdir}/pkcs11/*a
|
||||||
mkdir -p %{buildroot}%{_includedir}/softhsm
|
mkdir -p %{buildroot}%{_includedir}/softhsm
|
||||||
@ -100,17 +103,15 @@ ln -s ../pkcs11/libsofthsm2.so %{buildroot}/%{_libdir}/softhsm/libsofthsm.so
|
|||||||
%attr(1770,ods,ods) %dir %{_sharedstatedir}/softhsm/tokens
|
%attr(1770,ods,ods) %dir %{_sharedstatedir}/softhsm/tokens
|
||||||
%doc LICENSE README.md NEWS
|
%doc LICENSE README.md NEWS
|
||||||
%{_mandir}/*/*
|
%{_mandir}/*/*
|
||||||
|
%{_sysusersdir}/%{name}.conf
|
||||||
|
|
||||||
%files devel
|
%files devel
|
||||||
%attr(0755,root,root) %dir %{_includedir}/softhsm
|
%attr(0755,root,root) %dir %{_includedir}/softhsm
|
||||||
%{_includedir}/softhsm/*.h
|
%{_includedir}/softhsm/*.h
|
||||||
|
|
||||||
%pre
|
%pre
|
||||||
getent group ods >/dev/null || groupadd -r ods
|
|
||||||
getent passwd ods >/dev/null || \
|
%sysusers_create_package %{name} %{SOURCE2}
|
||||||
useradd -r -g ods -d %{_sharedstatedir}/softhsm -s /sbin/nologin \
|
|
||||||
-c "softhsm private keys owner" ods
|
|
||||||
exit 0
|
|
||||||
|
|
||||||
%post
|
%post
|
||||||
|
|
||||||
@ -120,6 +121,10 @@ if [ -f /var/softhsm/slot0.db ]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Thu Jan 23 2025 Rafael Jeffman <rjeffman@redhat.com> - 2.6.1-15
|
||||||
|
- Use systemd-sysusers
|
||||||
|
Resolves: RHEL-4901
|
||||||
|
|
||||||
* Tue Oct 29 2024 Troy Dawson <tdawson@redhat.com> - 2.6.1-14.1
|
* Tue Oct 29 2024 Troy Dawson <tdawson@redhat.com> - 2.6.1-14.1
|
||||||
- Bump release for October 2024 mass rebuild:
|
- Bump release for October 2024 mass rebuild:
|
||||||
Resolves: RHEL-64018
|
Resolves: RHEL-64018
|
||||||
@ -377,4 +382,4 @@ fi
|
|||||||
- Upgraded to 1.3.0
|
- Upgraded to 1.3.0
|
||||||
|
|
||||||
* Thu Mar 3 2011 Paul Wouters <paul@xelerance.com> - 1.2.0-1
|
* Thu Mar 3 2011 Paul Wouters <paul@xelerance.com> - 1.2.0-1
|
||||||
- Initial package for Fedora
|
- Initial package for Fedora
|
||||||
|
Loading…
Reference in New Issue
Block a user