systemd service fixed [release 6.12-2mamba;Sat May 01 2021]

This commit is contained in:
Silvan Calarco 2024-01-05 17:26:33 +01:00
parent c96e8fc837
commit 3e6b114f01
3 changed files with 18 additions and 12 deletions

View File

@ -1,6 +1,6 @@
Name: rng-tools Name: rng-tools
Version: 6.12 Version: 6.12
Release: 1mamba Release: 2mamba
Summary: A random number generator daemon Summary: A random number generator daemon
Group: System/Kernel and Hardware Group: System/Kernel and Hardware
Vendor: openmamba Vendor: openmamba
@ -10,17 +10,14 @@ URL: https://github.com/nhorman/rng-tools.git
Source: https://github.com/nhorman/rng-tools.git/v%{version}/rng-tools-%{version}.tar.bz2 Source: https://github.com/nhorman/rng-tools.git/v%{version}/rng-tools-%{version}.tar.bz2
Patch0: rng-tools-6.10-pkcs11-path.patch Patch0: rng-tools-6.10-pkcs11-path.patch
Source1: rngd.service Source1: rngd.service
Source2: rngd-sysconfig
License: GPL License: GPL
## AUTOBUILDREQ-BEGIN ## AUTOBUILDREQ-BEGIN
BuildRequires: glibc-devel BuildRequires: glibc-devel
BuildRequires: ldconfig
BuildRequires: libcurl-devel BuildRequires: libcurl-devel
BuildRequires: libjansson-devel BuildRequires: libjansson-devel
BuildRequires: libopenssl-devel BuildRequires: libopenssl-devel
BuildRequires: libp11-devel BuildRequires: libp11-devel
BuildRequires: librtlsdr-devel
BuildRequires: libsysfs-devel
BuildRequires: libusb-devel
BuildRequires: libxml2-devel BuildRequires: libxml2-devel
## AUTOBUILDREQ-END ## AUTOBUILDREQ-END
Requires: libopensc Requires: libopensc
@ -33,10 +30,6 @@ It monitors a set of entropy sources, and supplies entropy from them to the syst
%prep %prep
%setup -q %setup -q
#%ifarch x86_64 aarch64
#% patch0 -p1
#%endif
./autogen.sh ./autogen.sh
%build %build
@ -48,6 +41,7 @@ It monitors a set of entropy sources, and supplies entropy from them to the syst
%makeinstall %makeinstall
install -D -m0644 %{SOURCE1} %{buildroot}%{_unitdir}/rngd.service install -D -m0644 %{SOURCE1} %{buildroot}%{_unitdir}/rngd.service
install -D -m0644 %{SOURCE2} %{buildroot}%{_sysconfdir}/sysconfig/rngd
%clean %clean
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}" [ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
@ -66,6 +60,7 @@ install -D -m0644 %{SOURCE1} %{buildroot}%{_unitdir}/rngd.service
%files %files
%defattr(-,root,root) %defattr(-,root,root)
%config(noreplace) %{_sysconfdir}/sysconfig/rngd
%{_bindir}/rngtest %{_bindir}/rngtest
%{_sbindir}/rngd %{_sbindir}/rngd
%{_unitdir}/rngd.service %{_unitdir}/rngd.service
@ -74,6 +69,9 @@ install -D -m0644 %{SOURCE1} %{buildroot}%{_unitdir}/rngd.service
%doc AUTHORS COPYING %doc AUTHORS COPYING
%changelog %changelog
* Sat May 01 2021 Silvan Calarco <silvan.calarco@mambasoft.it> 6.12-2mamba
- systemd service fixed
* Sat Mar 13 2021 Automatic Build System <autodist@mambasoft.it> 6.12-1mamba * Sat Mar 13 2021 Automatic Build System <autodist@mambasoft.it> 6.12-1mamba
- automatic version update by autodist - automatic version update by autodist

1
rngd-sysconfig Normal file
View File

@ -0,0 +1 @@
RNGD_OPTS=""

View File

@ -1,9 +1,16 @@
[Unit] [Unit]
Description=Hardware RNG Entropy Gatherer Daemon Description=Hardware RNG Entropy Gatherer Daemon
ConditionVirtualization=!container DefaultDependencies=no
Before=sysinit.target shutdown.target
[Service] [Service]
ExecStart=/usr/sbin/rngd -f EnvironmentFile=/etc/sysconfig/rngd
ExecStart=/usr/bin/rngd -f $RNGD_OPTS
NoNewPrivileges=on
PrivateNetwork=on
PrivateTmp=on
ProtectSystem=full
ProtectHome=on
[Install] [Install]
WantedBy=multi-user.target WantedBy=sysinit.target