代码拉取完成,页面将自动刷新
同步操作将从 OpenCloudOS Stream/nrpe 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
%define nsport 5666
%global commit 4f7dd1199f1f3f72f9197e8565da339a4a2490b7
%global shortcommit %(c=%{commit}; echo ${c:0:7})
%global commdate 20200423
%global fromgit 0
Name: nrpe
Version: 4.1.0
Release: 2%{?dist}
Summary: Host/service/network monitoring agent for Nagios
License: GPLv2
URL: http://www.nagios.org
%if 0%{?fromgit}
Source0: https://github.com/NagiosEnterprises/nrpe/archive/%{commit}/%{name}-%{shortcommit}.tar.gz
%else
Source0: https://github.com/NagiosEnterprises/nrpe/archive/%{name}-%{version}.tar.gz
%endif
Source1: nrpe.sysconfig
Source2: nrpe-tmpfiles.conf
Patch3: nrpe-0003-Include-etc-npre.d-config-directory.patch
Patch5: nrpe-0005-systemd-service.patch
Patch6: nrpe-configure-c99.patch
BuildRequires: make
BuildRequires: autoconf, automake, libtool
BuildRequires: gcc
BuildRequires: openssl, openssl-devel
BuildRequires: checkpolicy, selinux-policy-devel
BuildRequires: systemd-units
Requires(pre): %{_sbindir}/useradd, %{_sbindir}/usermod
Requires(post): systemd
Requires(preun): systemd
Requires(postun): systemd
Requires: nagios-common
Provides: nagios-nrpe = %{version}-%{release}
%description
Nrpe is a system daemon that will execute various Nagios plugins
locally on behalf of a remote (monitoring) host that uses the
check_nrpe plugin. Various plugins that can be executed by the
daemon are available at:
http://sourceforge.net/projects/nagiosplug
This package provides the core agent.
%package -n nagios-plugins-nrpe
Summary: Provides nrpe plugin for Nagios
Requires: nagios-plugins
Provides: check_nrpe = %{version}-%{release}
%description -n nagios-plugins-nrpe
Nrpe is a system daemon that will execute various Nagios plugins
locally on behalf of a remote (monitoring) host that uses the
check_nrpe plugin. Various plugins that can be executed by the
daemon are available at:
http://sourceforge.net/projects/nagiosplug
This package provides the nrpe plugin for Nagios-related applications.
%prep
%if 0%{fromgit}
%autosetup -p1 -n %{name}-%{commit}
%else
%autosetup -p1 -n %{name}-%{name}-%{version}
%endif
%build
CFLAGS="$RPM_OPT_FLAGS" CXXFLAGS="$RPM_OPT_FLAGS" LDFLAGS="%{?__global_ldflags}" \
%configure \
--with-nrpe-port=%{nsport} \
--with-nrpe-user=nrpe \
--with-nrpe-group=nrpe \
--with-piddir=/run/nrpe \
--bindir=%{_sbindir} \
--libdir=/doesnt/matter/ \
--libexecdir=%{_libdir}/nagios/plugins \
--datadir=%{_datadir}/nagios \
--sysconfdir=%{_sysconfdir}/nagios \
--localstatedir=%{_localstatedir}/run/ \
--enable-command-args
make %{?_smp_mflags} all
%install
install -D -m 0644 -p startup/default-service %{buildroot}%{_unitdir}/%{name}.service
install -D -p -m 0644 sample-config/nrpe.cfg %{buildroot}/%{_sysconfdir}/nagios/%{name}.cfg
install -D -p -m 0755 src/nrpe %{buildroot}/%{_sbindir}/nrpe
install -D -p -m 0755 src/check_nrpe %{buildroot}/%{_libdir}/nagios/plugins/check_nrpe
install -D -p -m 0644 %{SOURCE1} %{buildroot}/%{_sysconfdir}/sysconfig/%{name}
install -d %{buildroot}%{_sysconfdir}/nrpe.d
install -d %{buildroot}%{_localstatedir}/run/%{name}
install -D -p -m 0644 %{SOURCE2} %{buildroot}%{_tmpfilesdir}/%{name}.conf
%pre
getent group %{name} >/dev/null || groupadd -r %{name}
getent passwd %{name} >/dev/null || \
%{_sbindir}/useradd -c "NRPE user for the NRPE service" -d %{_localstatedir}/run/%{name} -r -g %{name} -s /sbin/nologin %{name} 2> /dev/null || :
getent group nagios >/dev/null && %{_sbindir}/usermod -a -G nagios %{name} || :
%preun
%systemd_preun nrpe.service
%post
%systemd_post nrpe.service
%postun
%systemd_postun_with_restart nrpe.service
%files
%{_unitdir}/%{name}.service
%{_sbindir}/nrpe
%dir %{_sysconfdir}/nrpe.d
%config(noreplace) %{_sysconfdir}/nagios/nrpe.cfg
%config(noreplace) %{_sysconfdir}/sysconfig/%{name}
%config(noreplace) %{_tmpfilesdir}/%{name}.conf
%license LICENSE.md
%doc CHANGELOG.md LEGAL README.md README.SSL.md SECURITY.md docs/NRPE.pdf
%dir %attr(775, %{name}, %{name}) %{_localstatedir}/run/%{name}
%files -n nagios-plugins-nrpe
%{_libdir}/nagios/plugins/check_nrpe
%license LICENSE.md
%doc CHANGELOG.md LEGAL README.md
%changelog
* Tue Sep 3 2024 Ze Zhang <bbrucezhang@tencent.com> - 4.1.0-2
- [Type] other
- [DESC] Remove not used macors
* Mon Jul 01 2024 OpenCloudOS Release Engineering <releng@opencloudos.tech> - 4.1.0-1
- initial build
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。