|
@@ -4,7 +4,7 @@ Summary: Fast and lean authoritative DNS Name Server
|
|
Summary(ja): 高速で最小限のAuthoritative専用DNSネームサーバ
|
|
Summary(ja): 高速で最小限のAuthoritative専用DNSネームサーバ
|
|
Name: nsd
|
|
Name: nsd
|
|
Version: 4.3.8
|
|
Version: 4.3.8
|
|
-Release: 1%{?_dist_release}%{?with_systemd:.systemd}
|
|
|
|
|
|
+Release: 2%{?_dist_release}%{?with_systemd:.systemd}
|
|
Group: servers
|
|
Group: servers
|
|
Vendor: Project Vine
|
|
Vendor: Project Vine
|
|
Distribution: Vine Linux
|
|
Distribution: Vine Linux
|
|
@@ -95,7 +95,7 @@ install -d -m 0700 %{buildroot}%{_localstatedir}/lib/%{name}
|
|
|
|
|
|
%if %{with systemd}
|
|
%if %{with systemd}
|
|
mkdir -p %{buildroot}%{_unitdir}
|
|
mkdir -p %{buildroot}%{_unitdir}
|
|
-install -m 0644 %{SOURCE10} %{SOURCE11} %{buildroot}%{_unitdir}
|
|
|
|
|
|
+install -m 0644 %{SOURCE10} %{buildroot}%{_unitdir}
|
|
mkdir -p %{buildroot}%{_tmpfilesdir}
|
|
mkdir -p %{buildroot}%{_tmpfilesdir}
|
|
install -m 0644 %{SOURCE12} %{buildroot}%{_tmpfilesdir}/nsd.conf
|
|
install -m 0644 %{SOURCE12} %{buildroot}%{_tmpfilesdir}/nsd.conf
|
|
%else
|
|
%else
|
|
@@ -116,6 +116,13 @@ sed -i \
|
|
-e 's|# control-interface: ::1|control-interface: %{piddir}/nsd.ctl|' \
|
|
-e 's|# control-interface: ::1|control-interface: %{piddir}/nsd.ctl|' \
|
|
%{buildroot}%{_sysconfdir}/nsd/nsd.conf
|
|
%{buildroot}%{_sysconfdir}/nsd/nsd.conf
|
|
|
|
|
|
|
|
+# Install ghost files
|
|
|
|
+for name in control server; do
|
|
|
|
+ for extension in key pem; do
|
|
|
|
+ touch %{buildroot}%{_sysconfdir}/nsd/nsd_${name}.${extension}
|
|
|
|
+ done
|
|
|
|
+done
|
|
|
|
+
|
|
|
|
|
|
%clean
|
|
%clean
|
|
rm -rf ${RPM_BUILD_ROOT}
|
|
rm -rf ${RPM_BUILD_ROOT}
|
|
@@ -133,7 +140,6 @@ chown -R nsd.nsd %{_localstatedir}/lib/nsd 2>/dev/null ||:
|
|
chown -R nsd.nsd %{_localstatedir}/run/nsd 2>/dev/null ||:
|
|
chown -R nsd.nsd %{_localstatedir}/run/nsd 2>/dev/null ||:
|
|
%if %{with systemd}
|
|
%if %{with systemd}
|
|
%systemd_post nsd.service
|
|
%systemd_post nsd.service
|
|
-%systemd_post nsd-keygen.service
|
|
|
|
%else
|
|
%else
|
|
/sbin/chkconfig --add %{name}
|
|
/sbin/chkconfig --add %{name}
|
|
if [ ! -f %{_sysconfdir}/nsd/nsd_control.pem ]; then
|
|
if [ ! -f %{_sysconfdir}/nsd/nsd_control.pem ]; then
|
|
@@ -144,7 +150,6 @@ fi
|
|
%preun
|
|
%preun
|
|
%if %{with systemd}
|
|
%if %{with systemd}
|
|
%systemd_preun nsd.service
|
|
%systemd_preun nsd.service
|
|
-%systemd_preun nsd-keygen.service
|
|
|
|
%else
|
|
%else
|
|
if [ $1 -eq 0 -o -x /bin/systemctl ]; then
|
|
if [ $1 -eq 0 -o -x /bin/systemctl ]; then
|
|
/sbin/service %{name} stop
|
|
/sbin/service %{name} stop
|
|
@@ -155,7 +160,6 @@ fi
|
|
%postun
|
|
%postun
|
|
%if %{with systemd}
|
|
%if %{with systemd}
|
|
%systemd_postun_with_restart nsd.service
|
|
%systemd_postun_with_restart nsd.service
|
|
-%systemd_postun nsd-keygen.service
|
|
|
|
%else
|
|
%else
|
|
if [ "$1" -ge "1" -a ! -x /bin/systemctl ]; then
|
|
if [ "$1" -ge "1" -a ! -x /bin/systemctl ]; then
|
|
/sbin/service %{name} condrestart
|
|
/sbin/service %{name} condrestart
|
|
@@ -170,21 +174,27 @@ fi
|
|
%dir %{_sysconfdir}/nsd/
|
|
%dir %{_sysconfdir}/nsd/
|
|
%attr(0644,root,root) %config(noreplace) %{_sysconfdir}/nsd/nsd.conf
|
|
%attr(0644,root,root) %config(noreplace) %{_sysconfdir}/nsd/nsd.conf
|
|
#%attr(0644,root,root) %config(noreplace) %{_sysconfdir}/nsd/nsd.zones
|
|
#%attr(0644,root,root) %config(noreplace) %{_sysconfdir}/nsd/nsd.zones
|
|
|
|
+%attr(0640,root,nsd) %ghost %{_sysconfdir}/nsd/nsd_server.key
|
|
|
|
+%attr(0640,root,nsd) %ghost %{_sysconfdir}/nsd/nsd_server.pem
|
|
|
|
+%attr(0640,root,nsd) %ghost %{_sysconfdir}/nsd/nsd_control.key
|
|
|
|
+%attr(0640,root,nsd) %ghost %{_sysconfdir}/nsd/nsd_control.pem
|
|
%if %{with systemd}
|
|
%if %{with systemd}
|
|
%attr(0644,root,root) %{_unitdir}/nsd.service
|
|
%attr(0644,root,root) %{_unitdir}/nsd.service
|
|
-%attr(0644,root,root) %{_unitdir}/nsd-keygen.service
|
|
|
|
%attr(0644,root,root) %{_tmpfilesdir}/nsd.conf
|
|
%attr(0644,root,root) %{_tmpfilesdir}/nsd.conf
|
|
%else
|
|
%else
|
|
%attr(0644,root,root) %config(noreplace) %{_sysconfdir}/sysconfig/nsd
|
|
%attr(0644,root,root) %config(noreplace) %{_sysconfdir}/sysconfig/nsd
|
|
%attr(0755,root,root) %{_initrddir}/%{name}
|
|
%attr(0755,root,root) %{_initrddir}/%{name}
|
|
-%endif
|
|
|
|
%ghost %attr(0755,%{name},%{name}) %dir %{_localstatedir}/run/%{name}
|
|
%ghost %attr(0755,%{name},%{name}) %dir %{_localstatedir}/run/%{name}
|
|
|
|
+%endif
|
|
%attr(0755,%{name},%{name}) %dir %{_localstatedir}/lib/%{name}
|
|
%attr(0755,%{name},%{name}) %dir %{_localstatedir}/lib/%{name}
|
|
%{_sbindir}/*
|
|
%{_sbindir}/*
|
|
%{_mandir}/*/*
|
|
%{_mandir}/*/*
|
|
|
|
|
|
|
|
|
|
%changelog
|
|
%changelog
|
|
|
|
+* Fri Dec 03 2021 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 4.3.8-2
|
|
|
|
+- fixed systemd-unit.
|
|
|
|
+
|
|
* Tue Oct 12 2021 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 4.3.8-1
|
|
* Tue Oct 12 2021 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 4.3.8-1
|
|
- new upstream release.
|
|
- new upstream release.
|
|
|
|
|