Start unbound-anchor.timer only on new installations
Signed-off-by: Tomas Hozza <thozza@redhat.com>
This commit is contained in:
parent
fdd77f9ee3
commit
7aa01f9152
10
unbound.spec
10
unbound.spec
@ -21,7 +21,7 @@
|
|||||||
Summary: Validating, recursive, and caching DNS(SEC) resolver
|
Summary: Validating, recursive, and caching DNS(SEC) resolver
|
||||||
Name: unbound
|
Name: unbound
|
||||||
Version: 1.5.4
|
Version: 1.5.4
|
||||||
Release: 1%{?extra_version:.%{extra_version}}%{?dist}
|
Release: 2%{?extra_version:.%{extra_version}}%{?dist}
|
||||||
License: BSD
|
License: BSD
|
||||||
Url: http://www.nlnetlabs.nl/unbound/
|
Url: http://www.nlnetlabs.nl/unbound/
|
||||||
Source: http://www.unbound.net/downloads/%{name}-%{version}%{?extra_version}.tar.gz
|
Source: http://www.unbound.net/downloads/%{name}-%{version}%{?extra_version}.tar.gz
|
||||||
@ -301,8 +301,11 @@ useradd -r -g unbound -d %{_sysconfdir}/unbound -s /sbin/nologin \
|
|||||||
/sbin/ldconfig
|
/sbin/ldconfig
|
||||||
%{_sbindir}/runuser --command="%{_sbindir}/unbound-anchor -a %{_sharedstatedir}/unbound/root.anchor -c %{_sysconfdir}/unbound/icannbundle.pem" --shell /bin/sh unbound ||:
|
%{_sbindir}/runuser --command="%{_sbindir}/unbound-anchor -a %{_sharedstatedir}/unbound/root.anchor -c %{_sysconfdir}/unbound/icannbundle.pem" --shell /bin/sh unbound ||:
|
||||||
%systemd_post unbound-anchor.timer
|
%systemd_post unbound-anchor.timer
|
||||||
# the Unit is in presets, but would be started afte reboot
|
# 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 || :
|
/bin/systemctl start unbound-anchor.timer >/dev/null 2>&1 || :
|
||||||
|
fi
|
||||||
|
|
||||||
%preun
|
%preun
|
||||||
%systemd_preun unbound.service
|
%systemd_preun unbound.service
|
||||||
@ -427,6 +430,9 @@ popd
|
|||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Thu Jul 16 2015 Tomas Hozza <thozza@redhat.com> - 1.5.4-2
|
||||||
|
- Start unbound-anchor.timer only on new installations
|
||||||
|
|
||||||
* Tue Jul 14 2015 Paul Wouters <pwouters@redhat.com> - 1.5.4-1
|
* Tue Jul 14 2015 Paul Wouters <pwouters@redhat.com> - 1.5.4-1
|
||||||
- Update to 1.5.4
|
- Update to 1.5.4
|
||||||
- Removed patches merged into upstream
|
- Removed patches merged into upstream
|
||||||
|
Loading…
Reference in New Issue
Block a user