]> git.pld-linux.org Git - packages/nagios-nrpe.git/blobdiff - nagios-nrpe.spec
- release 13
[packages/nagios-nrpe.git] / nagios-nrpe.spec
index d7729230582459deb35d29299fe8e88501e79132..0cc521f1fc66aad2a23a5e59059a61f498a89446 100644 (file)
@@ -1,22 +1,23 @@
 Summary:       Nagios remote plugin execution service/plugin
-Summary(pl):   Demon i wtyczka zdalnego wywo³ywania wtyczek Nagios
+Summary(pl.UTF-8):     Demon i wtyczka zdalnego wywoływania wtyczek Nagios
 Name:          nagios-nrpe
-Version:       2.5.2
-Release:       1
+Version:       2.12
+Release:       13
 License:       GPL v2
 Group:         Networking
 Source0:       http://dl.sourceforge.net/nagios/nrpe-%{version}.tar.gz
-# Source0-md5: 22afa197db8e4e5b13fac48636917b6d
+# Source0-md5: b2d75e2962f1e3151ef58794d60c9e97
 Source1:       nrpe.init
+Source2:       nrpe-command.cfg
 Patch0:                %{name}-config.patch
 URL:           http://www.nagios.org/
 BuildRequires: autoconf
 BuildRequires: automake
+BuildRequires: openssl-devel
 BuildRequires: openssl-tools
 BuildRequires: rpmbuild(macros) >= 1.268
 Requires(post,preun):  /sbin/chkconfig
 Requires:      nagios-common
-Requires:      nagios-plugins
 Requires:      rc-scripts
 Provides:      nagios-core
 Obsoletes:     netsaint-nrpe
@@ -38,23 +39,30 @@ daemon or as a service under inetd). Supports passing command
 arguments to server, as well as native SSL/TLS encryption (anonymous
 DH mode).
 
-%description -l pl
-Nagios npre pozwala zdalnie uruchamiaæ wtyczki na innych hostach, a
-wynik ich dzia³ania zwracaæ z powrotem do hosta monitoruj±cego.
+%description -l pl.UTF-8
+NRPE to dodatek do Nagiosa pozwalający na wywoływanie "lokalnych"
+wtyczek (takich jak check_disk, check_procs itp.) na zdalnych
+maszynach. Wtyczka check_nrpe jest wywoływana z poziomu Nagiosa i
+wysyła żądania uruchomienia wtyczek do demona NRPE działającego na
+zdalnej maszynie (jako samodzielny demon lub usługa inetd). Obsługuje
+przekazywanie argumentów poleceń do serwera, a także natywne
+szyfrowanie SSL/TLS (w trybie anonimowego DH).
 
-%package plugin
+%package -n nagios-plugin-check_nrpe
 Summary:       check_nrpe plugin for Nagios
-Summary(pl):   Wtyczka check_nrpe dla Nagiosa
+Summary(pl.UTF-8):     Wtyczka check_nrpe dla Nagiosa
 Group:         Networking
-Requires:      nagios-core
+Requires:      nagios-common
+Provides:      %{name}-plugin = %{version}-%{release}
+Obsoletes:     %{name}-plugin < 2.12-6
 
-%description plugin
+%description -n nagios-plugin-check_nrpe
 check_nrpe plugin for Nagios. This plugin allows running plugins on
 remote machines using nrpe service.
 
-%description plugin -l pl
+%description -n nagios-plugin-check_nrpe -l pl.UTF-8
 Wtyczka check_nrpe dla Nagiosa. Pozwala na zdalne uruchamianie wtyczek
-na innych komputerach za pomoc± demona nrpe.
+na innych komputerach za pomocą demona nrpe.
 
 %prep
 %setup -q -n nrpe-%{version}
@@ -76,10 +84,11 @@ na innych komputerach za pomoc
 
 %install
 rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT{/etc/rc.d/init.d,%{_sysconfdir},%{_libdir}/nagios/plugins,%{_sbindir}} \
-       $RPM_BUILD_ROOT%{_localstatedir}
+install -d $RPM_BUILD_ROOT{/etc/rc.d/init.d,%{_sysconfdir}/plugins,%{_libdir}/nagios/plugins,%{_sbindir}} \
+       $RPM_BUILD_ROOT{%{_localstatedir},/var/run/nrpe}
 
 install sample-config/nrpe.cfg $RPM_BUILD_ROOT%{_sysconfdir}/nrpe.cfg
+sed -e 's,@plugindir@,%{_plugindir},' %{SOURCE2} > $RPM_BUILD_ROOT%{_sysconfdir}/plugins/check_nrpe.cfg
 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/nrpe
 install src/nrpe $RPM_BUILD_ROOT%{_sbindir}
 install src/check_nrpe $RPM_BUILD_ROOT%{_plugindir}
@@ -97,13 +106,25 @@ if [ "$1" = "0" ] ; then
        /sbin/chkconfig --del nrpe
 fi
 
+%triggerpostun -- %{name} < 2.6-1.1
+%{__sed} -i -e 's,/var/run/nrpe.pid,/var/run/nrpe/nrpe.pid,' %{_sysconfdir}/nrpe.cfg
+
+%triggerpostun -n nagios-plugin-check_nrpe -- nagios-plugin-check_nrpe < 2.12-7.1
+if [ -f %{_sysconfdir}/plugins/nrpe.cfg.rpmsave ]; then
+       cp -f %{_sysconfdir}/plugins/check_nrpe.cfg{,.rpmnew}
+       mv -f %{_sysconfdir}/plugins/{nrpe.cfg.rpmsave,check_nrpe.cfg}
+       sed -i -e 's,-c \$ARG1\$,$ARG1$,' %{_sysconfdir}/plugins/check_nrpe.cfg
+fi
+
 %files
 %defattr(644,root,root,755)
 %doc Changelog LEGAL README* SECURITY
-%attr(754,root,root) /etc/rc.d/init.d/nrpe
 %attr(640,root,nagios) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/nrpe.cfg
 %attr(755,root,root) %{_sbindir}/nrpe
+%attr(754,root,root) /etc/rc.d/init.d/nrpe
+%dir %attr(775,root,nagios) /var/run/nrpe
 
-%files plugin
+%files -n nagios-plugin-check_nrpe
 %defattr(644,root,root,755)
-%attr(755,root,root) %{_plugindir}/*
+%attr(640,root,nagios) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/plugins/check_nrpe.cfg
+%attr(755,root,root) %{_plugindir}/check_nrpe
This page took 0.042506 seconds and 4 git commands to generate.