!109 move files about anchor and pem to separate package
From: @addrexist Reviewed-by: @jiangheng12 Signed-off-by: @jiangheng12
This commit is contained in:
commit
bea4abd0e6
67
unbound.spec
67
unbound.spec
@ -2,7 +2,7 @@
|
||||
|
||||
Name: unbound
|
||||
Version: 1.17.1
|
||||
Release: 5
|
||||
Release: 6
|
||||
Summary: Unbound is a validating, recursive, caching DNS resolver
|
||||
License: BSD-3-Clause
|
||||
Url: https://nlnetlabs.nl/projects/unbound/about/
|
||||
@ -35,6 +35,8 @@ BuildRequires: gcc byacc
|
||||
|
||||
%{?systemd_requires}
|
||||
Requires: %{name}-libs = %{version}-%{release}
|
||||
Requires: %{name}-anchor = %{version}-%{release}
|
||||
Recommends: %{name}-utils = %{version}-%{release}
|
||||
Requires: openssl
|
||||
|
||||
%description
|
||||
@ -73,6 +75,22 @@ Summary: Man pages for unbound
|
||||
%description help
|
||||
Package help includes includes man pages for unbound.
|
||||
|
||||
%package anchor
|
||||
Requires: %{name}-libs = %{version}-%{release}
|
||||
Summary: DNSSEC trust anchor maintaining tool
|
||||
|
||||
%description anchor
|
||||
Contains tool maintaining trust anchor using RFC 5011 key rollover algorithm.
|
||||
|
||||
%package utils
|
||||
Requires: %{name}-libs = %{version}-%{release}
|
||||
Summary: Unbound DNS lookup utilities
|
||||
|
||||
%description utils
|
||||
Contains tools for making DNS queries. Can make queries to DNS servers
|
||||
also over TLS connection or validate DNSSEC signatures. Similar to
|
||||
bind-utils.
|
||||
|
||||
%prep
|
||||
|
||||
%setup -qcn %{name}-%{version}
|
||||
@ -149,10 +167,12 @@ useradd -r -g unbound -d %{_sysconfdir}/unbound -s /sbin/nologin \
|
||||
%systemd_post unbound.service
|
||||
%systemd_post unbound-keygen.service
|
||||
|
||||
%post libs
|
||||
%post anchor
|
||||
%{?ldconfig}
|
||||
%systemd_post unbound-anchor.timer
|
||||
%systemd_post unbound-anchor.service unbound-anchor.timer
|
||||
# start the timer only if installing the package to prevent starting it, if it was stopped on purpose
|
||||
if [ "$1" -eq 1 ]; then
|
||||
# the Unit is in presets, but would be started after reboot
|
||||
/bin/systemctl start unbound-anchor.timer >/dev/null 2>&1 || :
|
||||
fi
|
||||
|
||||
@ -160,16 +180,15 @@ fi
|
||||
%systemd_preun unbound.service
|
||||
%systemd_preun unbound-keygen.service
|
||||
|
||||
%preun libs
|
||||
%systemd_preun unbound-anchor.timer
|
||||
%preun anchor
|
||||
%systemd_preun unbound-anchor.service unbound-anchor.timer
|
||||
|
||||
%postun
|
||||
%systemd_postun_with_restart unbound.service
|
||||
%systemd_postun unbound-keygen.service
|
||||
|
||||
%postun libs
|
||||
%{?ldconfig}
|
||||
%systemd_postun_with_restart unbound-anchor.timer
|
||||
%postun anchor
|
||||
%systemd_postun_with_restart unbound-anchor.service unbound-anchor.timer
|
||||
|
||||
%triggerun -- unbound < 1.4.12-4
|
||||
/usr/bin/systemd-sysv-convert --save unbound >/dev/null 2>&1 ||:
|
||||
@ -202,27 +221,21 @@ popd
|
||||
%ghost %attr(0640,root,unbound) %{_sysconfdir}/%{name}/unbound_control.key
|
||||
%ghost %attr(0640,root,unbound) %{_sysconfdir}/%{name}/unbound_server.pem
|
||||
%ghost %attr(0640,root,unbound) %{_sysconfdir}/%{name}/unbound_server.key
|
||||
%{_sbindir}/*
|
||||
%exclude %{_sbindir}/unbound-anchor
|
||||
%{_sbindir}/unbound
|
||||
%{_sbindir}/unbound-checkconf
|
||||
%{_sbindir}/unbound-control
|
||||
%{_sbindir}/unbound-control-setup
|
||||
|
||||
%files libs
|
||||
%defattr(-,root,root)
|
||||
%dir %attr(0755,root,root) %{_sysconfdir}/%{name}
|
||||
%if %{?openEuler:1}0
|
||||
%attr(0644,root,root) %config %{_sysconfdir}/%{name}/root.key
|
||||
%dir %attr(0755,unbound,unbound) %{_sharedstatedir}/%{name}
|
||||
%attr(0644,unbound,unbound) %config %{_sharedstatedir}/%{name}/root.key
|
||||
%{_sysconfdir}/%{name}/icannbundle.pem
|
||||
%else
|
||||
%attr(0600,root,root) %config %{_sysconfdir}/%{name}/root.key
|
||||
%dir %attr(0755,unbound,unbound) %{_sharedstatedir}/%{name}
|
||||
%attr(0600,unbound,unbound) %config %{_sharedstatedir}/%{name}/root.key
|
||||
%attr(0600,root,root) %{_sysconfdir}/%{name}/icannbundle.pem
|
||||
%endif
|
||||
%{_sbindir}/unbound-anchor
|
||||
%{_libdir}/libunbound.so.*
|
||||
%{_unitdir}/unbound-anchor.timer
|
||||
%{_unitdir}/unbound-anchor.service
|
||||
|
||||
%files -n python3-unbound
|
||||
%defattr(-,root,root)
|
||||
@ -239,7 +252,25 @@ popd
|
||||
%defattr(-,root,root)
|
||||
%{_mandir}/man*
|
||||
|
||||
%files anchor
|
||||
%dir %attr(0755,root,root) %{_sysconfdir}/%{name}
|
||||
%attr(0644,root,root) %config %{_sysconfdir}/%{name}/root.key
|
||||
%attr(0644,root,root) %{_sysconfdir}/%{name}/icannbundle.pem
|
||||
%{_sbindir}/unbound-anchor
|
||||
%{_unitdir}/unbound-anchor.timer
|
||||
%{_unitdir}/unbound-anchor.service
|
||||
|
||||
%files utils
|
||||
%{_sbindir}/unbound-host
|
||||
%{_sbindir}/unbound-streamtcp
|
||||
|
||||
%changelog
|
||||
* Mon Jun 24 2024 wangziliang <wangziliang@kylinos.cn> - 1.17.1-6
|
||||
- Type:bugfix
|
||||
- ID:NA
|
||||
- SUG:NA
|
||||
- DESC:separate unbound-anchor and unbound-utils
|
||||
|
||||
* Fri May 17 2024 gaihuiying <eaglegai@163.com> - 1.17.1-5
|
||||
- Type:cves
|
||||
- CVE:CVE-2024-33655
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user