[arch-commits] Commit in nrpe/repos (16 files)

Evangelos Foutras foutrelis at archlinux.org
Wed Mar 2 18:17:10 UTC 2016


    Date: Wednesday, March 2, 2016 @ 19:17:10
  Author: foutrelis
Revision: 164186

archrelease: copy trunk to community-staging-i686, community-staging-x86_64

Added:
  nrpe/repos/community-staging-i686/
  nrpe/repos/community-staging-i686/PKGBUILD
    (from rev 164185, nrpe/trunk/PKGBUILD)
  nrpe/repos/community-staging-i686/nrpe.install
    (from rev 164185, nrpe/trunk/nrpe.install)
  nrpe/repos/community-staging-i686/nrpe.service
    (from rev 164185, nrpe/trunk/nrpe.service)
  nrpe/repos/community-staging-i686/nrpe.socket
    (from rev 164185, nrpe/trunk/nrpe.socket)
  nrpe/repos/community-staging-i686/nrpe.tmpfiles
    (from rev 164185, nrpe/trunk/nrpe.tmpfiles)
  nrpe/repos/community-staging-i686/nrpe at .service
    (from rev 164185, nrpe/trunk/nrpe at .service)
  nrpe/repos/community-staging-i686/syslog.patch
    (from rev 164185, nrpe/trunk/syslog.patch)
  nrpe/repos/community-staging-x86_64/
  nrpe/repos/community-staging-x86_64/PKGBUILD
    (from rev 164185, nrpe/trunk/PKGBUILD)
  nrpe/repos/community-staging-x86_64/nrpe.install
    (from rev 164185, nrpe/trunk/nrpe.install)
  nrpe/repos/community-staging-x86_64/nrpe.service
    (from rev 164185, nrpe/trunk/nrpe.service)
  nrpe/repos/community-staging-x86_64/nrpe.socket
    (from rev 164185, nrpe/trunk/nrpe.socket)
  nrpe/repos/community-staging-x86_64/nrpe.tmpfiles
    (from rev 164185, nrpe/trunk/nrpe.tmpfiles)
  nrpe/repos/community-staging-x86_64/nrpe at .service
    (from rev 164185, nrpe/trunk/nrpe at .service)
  nrpe/repos/community-staging-x86_64/syslog.patch
    (from rev 164185, nrpe/trunk/syslog.patch)

----------------------------------------+
 community-staging-i686/PKGBUILD        |   79 +++++++++++++++++++++++++++++++
 community-staging-i686/nrpe.install    |   23 +++++++++
 community-staging-i686/nrpe.service    |   13 +++++
 community-staging-i686/nrpe.socket     |    9 +++
 community-staging-i686/nrpe.tmpfiles   |    1 
 community-staging-i686/nrpe at .service   |    8 +++
 community-staging-i686/syslog.patch    |   22 ++++++++
 community-staging-x86_64/PKGBUILD      |   79 +++++++++++++++++++++++++++++++
 community-staging-x86_64/nrpe.install  |   23 +++++++++
 community-staging-x86_64/nrpe.service  |   13 +++++
 community-staging-x86_64/nrpe.socket   |    9 +++
 community-staging-x86_64/nrpe.tmpfiles |    1 
 community-staging-x86_64/nrpe at .service |    8 +++
 community-staging-x86_64/syslog.patch  |   22 ++++++++
 14 files changed, 310 insertions(+)

Copied: nrpe/repos/community-staging-i686/PKGBUILD (from rev 164185, nrpe/trunk/PKGBUILD)
===================================================================
--- community-staging-i686/PKGBUILD	                        (rev 0)
+++ community-staging-i686/PKGBUILD	2016-03-02 18:17:10 UTC (rev 164186)
@@ -0,0 +1,79 @@
+# Maintainer: Jonathan Steel <jsteel at archlinux.org>
+# Contributor: Phillip Smith <fukawi2 at NO-SPAM.gmail.com>
+# Contributor: Dale Blount <dale at archlinux.org>
+
+pkgname=nrpe
+pkgver=2.15
+pkgrel=5
+pkgdesc="Nagios Remote Plugin Executor"
+arch=('i686' 'x86_64')
+license=('GPL')
+depends=('openssl')
+optdepends=("monitoring-plugins: common tools for monitoring using $pkgname")
+replaces=('nagios-nrpe')
+install=$pkgname.install
+backup=('etc/nrpe/nrpe.cfg' 'etc/xinetd.d/nrpe')
+url="http://exchange.nagios.org/directory/Addons/Monitoring-Agents/NRPE--2D-Nagios-Remote-Plugin-Executor/details"
+source=(http://downloads.sourceforge.net/nagios/$pkgname-$pkgver.tar.gz
+        $pkgname.service $pkgname.socket $pkgname at .service $pkgname.tmpfiles
+        syslog.patch)
+md5sums=('3921ddc598312983f604541784b35a50'
+         '265512fbfc65f89eab1ca23d11ec749d'
+         'f239bb4e7b885449d1f4067b209d89fd'
+         '143278e9495821bd887cf84ce0f97af6'
+         'd4b89b7ff8ffb187d44fedf294e7f5de'
+         'e68e6460f5a2999635254dac64056679')
+
+prepare() {
+  cd $pkgname-$pkgver
+
+  # fix directory permissions
+  sed -i 's/775/755/' Makefile.in src/Makefile.in
+
+  # fix run directory
+  sed -i 's/nrpe.pid/nrpe\/nrpe.pid/' sample-config/nrpe.cfg.in
+
+  # set the nrpe user and group
+  sed -i 's/@nrpe_user@/31/' sample-config/nrpe.cfg.in
+  sed -i 's/@nrpe_group@/31/' sample-config/nrpe.cfg.in
+
+  # fix logging binary data to journal/syslog when ipv4 disconnects with debug=1
+  patch -Np1 -i "$srcdir"/syslog.patch
+}
+
+build() {
+  cd $pkgname-$pkgver
+
+  ./configure \
+    --prefix=/usr \
+    --sysconfdir=/etc/nrpe \
+    --libexecdir=/usr/lib/monitoring-plugins \
+    --enable-command-args \
+    --with-nrpe-user=0 --with-nrpe-group=0 \
+    --with-nagios-user=0 --with-nagios-group=0
+  
+  make
+}
+
+package() {
+  cd $pkgname-$pkgver
+
+  make DESTDIR="$pkgdir" install
+  make DESTDIR="$pkgdir"/ install-daemon-config
+
+  install -Dm644 sample-config/nrpe.xinetd "$pkgdir"/etc/xinetd.d/nrpe
+
+  install -D -m644 "$srcdir"/nrpe.service \
+    "$pkgdir"/usr/lib/systemd/system/nrpe.service
+  install -D -m644 "$srcdir"/nrpe.socket \
+    "$pkgdir"/usr/lib/systemd/system/nrpe.socket
+  install -D -m644 "$srcdir"/nrpe at .service \
+    "$pkgdir"/usr/lib/systemd/system/nrpe at .service
+  install -D -m644 "$srcdir"/nrpe.tmpfiles \
+    "$pkgdir"/usr/lib/tmpfiles.d/nrpe.conf
+
+  install -Dm644 README "$pkgdir"/usr/share/doc/$pkgname/README
+  install -Dm644 README.SSL "$pkgdir"/usr/share/doc/$pkgname/README.SSL
+  install -Dm644 SECURITY "$pkgdir"/usr/share/doc/$pkgname/SECURITY
+  install -Dm644 LEGAL "$pkgdir"/usr/share/licenses/$pkgname/LEGAL
+}

Copied: nrpe/repos/community-staging-i686/nrpe.install (from rev 164185, nrpe/trunk/nrpe.install)
===================================================================
--- community-staging-i686/nrpe.install	                        (rev 0)
+++ community-staging-i686/nrpe.install	2016-03-02 18:17:10 UTC (rev 164186)
@@ -0,0 +1,23 @@
+post_install() {
+  if [ -z "$(getent group nrpe)" ]; then
+    groupadd -g 31 nrpe
+  fi
+  if [ -z "$(getent passwd nrpe)" ]; then
+    useradd -u 31 -g nrpe -c "NRPE" -d /dev/null -s /usr/bin/nologin nrpe
+  fi
+
+  grep -Pq '^nrpe\s+' /etc/services || \
+    echo "nrpe             5666/tcp" >> /etc/services
+
+  systemd-tmpfiles --create /usr/lib/tmpfiles.d/nrpe.conf
+}
+
+post_upgrade() {
+  post_install $1
+}
+
+post_remove() {
+  # remove the line added to /etc/services
+  sed -e '/nrpe             5666\/tcp/d' \
+      -i /etc/services || true
+}

Copied: nrpe/repos/community-staging-i686/nrpe.service (from rev 164185, nrpe/trunk/nrpe.service)
===================================================================
--- community-staging-i686/nrpe.service	                        (rev 0)
+++ community-staging-i686/nrpe.service	2016-03-02 18:17:10 UTC (rev 164186)
@@ -0,0 +1,13 @@
+[Unit]
+Description=Daemon to answer plugin requests from Nagios on remote hosts
+After=network.target
+Requires=network.target
+
+[Service]
+Type=forking
+User=nrpe
+Group=nrpe
+ExecStart=/usr/bin/nrpe -c /etc/nrpe/nrpe.cfg -d
+
+[Install]
+WantedBy=multi-user.target

Copied: nrpe/repos/community-staging-i686/nrpe.socket (from rev 164185, nrpe/trunk/nrpe.socket)
===================================================================
--- community-staging-i686/nrpe.socket	                        (rev 0)
+++ community-staging-i686/nrpe.socket	2016-03-02 18:17:10 UTC (rev 164186)
@@ -0,0 +1,9 @@
+[Unit]
+Description=NRPE Socket for Per-Connection Servers
+
+[Socket]
+ListenStream=5666
+Accept=yes
+
+[Install]
+WantedBy=sockets.target

Copied: nrpe/repos/community-staging-i686/nrpe.tmpfiles (from rev 164185, nrpe/trunk/nrpe.tmpfiles)
===================================================================
--- community-staging-i686/nrpe.tmpfiles	                        (rev 0)
+++ community-staging-i686/nrpe.tmpfiles	2016-03-02 18:17:10 UTC (rev 164186)
@@ -0,0 +1 @@
+d /run/nrpe 0755 nrpe nrpe -

Copied: nrpe/repos/community-staging-i686/nrpe at .service (from rev 164185, nrpe/trunk/nrpe at .service)
===================================================================
--- community-staging-i686/nrpe at .service	                        (rev 0)
+++ community-staging-i686/nrpe at .service	2016-03-02 18:17:10 UTC (rev 164186)
@@ -0,0 +1,8 @@
+[Unit]
+Description=NRPE Per-Connection Server
+
+[Service]
+ExecStart=-/usr/bin/nrpe -c /etc/nrpe/nrpe.cfg --inetd
+User=nrpe
+Group=nrpe
+StandardInput=socket

Copied: nrpe/repos/community-staging-i686/syslog.patch (from rev 164185, nrpe/trunk/syslog.patch)
===================================================================
--- community-staging-i686/syslog.patch	                        (rev 0)
+++ community-staging-i686/syslog.patch	2016-03-02 18:17:10 UTC (rev 164186)
@@ -0,0 +1,22 @@
+diff --git a/src/nrpe.c b/src/nrpe.c
+index 381f0ac..bc6b227 100644
+--- a/src/nrpe.c
++++ b/src/nrpe.c
+@@ -1131,7 +1131,16 @@ void wait_for_connections(void){
+ 
+ 					/* log info to syslog facility */
+ 					if(debug==TRUE) {
+-						syslog(LOG_DEBUG,"Connection from %s closed.",ipstr);
++						switch(addr.ss_family) {
++							case AF_INET:
++								syslog(LOG_DEBUG,"Connection from %s closed.",
++									inet_ntoa(nptr->sin_addr));
++								break;
++							case AF_INET6:
++								syslog(LOG_DEBUG,"Connection from %s closed.",
++									ipstr);
++								break;
++							}
+ 						}
+ 
+ 					/* close socket prior to exiting */

Copied: nrpe/repos/community-staging-x86_64/PKGBUILD (from rev 164185, nrpe/trunk/PKGBUILD)
===================================================================
--- community-staging-x86_64/PKGBUILD	                        (rev 0)
+++ community-staging-x86_64/PKGBUILD	2016-03-02 18:17:10 UTC (rev 164186)
@@ -0,0 +1,79 @@
+# Maintainer: Jonathan Steel <jsteel at archlinux.org>
+# Contributor: Phillip Smith <fukawi2 at NO-SPAM.gmail.com>
+# Contributor: Dale Blount <dale at archlinux.org>
+
+pkgname=nrpe
+pkgver=2.15
+pkgrel=5
+pkgdesc="Nagios Remote Plugin Executor"
+arch=('i686' 'x86_64')
+license=('GPL')
+depends=('openssl')
+optdepends=("monitoring-plugins: common tools for monitoring using $pkgname")
+replaces=('nagios-nrpe')
+install=$pkgname.install
+backup=('etc/nrpe/nrpe.cfg' 'etc/xinetd.d/nrpe')
+url="http://exchange.nagios.org/directory/Addons/Monitoring-Agents/NRPE--2D-Nagios-Remote-Plugin-Executor/details"
+source=(http://downloads.sourceforge.net/nagios/$pkgname-$pkgver.tar.gz
+        $pkgname.service $pkgname.socket $pkgname at .service $pkgname.tmpfiles
+        syslog.patch)
+md5sums=('3921ddc598312983f604541784b35a50'
+         '265512fbfc65f89eab1ca23d11ec749d'
+         'f239bb4e7b885449d1f4067b209d89fd'
+         '143278e9495821bd887cf84ce0f97af6'
+         'd4b89b7ff8ffb187d44fedf294e7f5de'
+         'e68e6460f5a2999635254dac64056679')
+
+prepare() {
+  cd $pkgname-$pkgver
+
+  # fix directory permissions
+  sed -i 's/775/755/' Makefile.in src/Makefile.in
+
+  # fix run directory
+  sed -i 's/nrpe.pid/nrpe\/nrpe.pid/' sample-config/nrpe.cfg.in
+
+  # set the nrpe user and group
+  sed -i 's/@nrpe_user@/31/' sample-config/nrpe.cfg.in
+  sed -i 's/@nrpe_group@/31/' sample-config/nrpe.cfg.in
+
+  # fix logging binary data to journal/syslog when ipv4 disconnects with debug=1
+  patch -Np1 -i "$srcdir"/syslog.patch
+}
+
+build() {
+  cd $pkgname-$pkgver
+
+  ./configure \
+    --prefix=/usr \
+    --sysconfdir=/etc/nrpe \
+    --libexecdir=/usr/lib/monitoring-plugins \
+    --enable-command-args \
+    --with-nrpe-user=0 --with-nrpe-group=0 \
+    --with-nagios-user=0 --with-nagios-group=0
+  
+  make
+}
+
+package() {
+  cd $pkgname-$pkgver
+
+  make DESTDIR="$pkgdir" install
+  make DESTDIR="$pkgdir"/ install-daemon-config
+
+  install -Dm644 sample-config/nrpe.xinetd "$pkgdir"/etc/xinetd.d/nrpe
+
+  install -D -m644 "$srcdir"/nrpe.service \
+    "$pkgdir"/usr/lib/systemd/system/nrpe.service
+  install -D -m644 "$srcdir"/nrpe.socket \
+    "$pkgdir"/usr/lib/systemd/system/nrpe.socket
+  install -D -m644 "$srcdir"/nrpe at .service \
+    "$pkgdir"/usr/lib/systemd/system/nrpe at .service
+  install -D -m644 "$srcdir"/nrpe.tmpfiles \
+    "$pkgdir"/usr/lib/tmpfiles.d/nrpe.conf
+
+  install -Dm644 README "$pkgdir"/usr/share/doc/$pkgname/README
+  install -Dm644 README.SSL "$pkgdir"/usr/share/doc/$pkgname/README.SSL
+  install -Dm644 SECURITY "$pkgdir"/usr/share/doc/$pkgname/SECURITY
+  install -Dm644 LEGAL "$pkgdir"/usr/share/licenses/$pkgname/LEGAL
+}

Copied: nrpe/repos/community-staging-x86_64/nrpe.install (from rev 164185, nrpe/trunk/nrpe.install)
===================================================================
--- community-staging-x86_64/nrpe.install	                        (rev 0)
+++ community-staging-x86_64/nrpe.install	2016-03-02 18:17:10 UTC (rev 164186)
@@ -0,0 +1,23 @@
+post_install() {
+  if [ -z "$(getent group nrpe)" ]; then
+    groupadd -g 31 nrpe
+  fi
+  if [ -z "$(getent passwd nrpe)" ]; then
+    useradd -u 31 -g nrpe -c "NRPE" -d /dev/null -s /usr/bin/nologin nrpe
+  fi
+
+  grep -Pq '^nrpe\s+' /etc/services || \
+    echo "nrpe             5666/tcp" >> /etc/services
+
+  systemd-tmpfiles --create /usr/lib/tmpfiles.d/nrpe.conf
+}
+
+post_upgrade() {
+  post_install $1
+}
+
+post_remove() {
+  # remove the line added to /etc/services
+  sed -e '/nrpe             5666\/tcp/d' \
+      -i /etc/services || true
+}

Copied: nrpe/repos/community-staging-x86_64/nrpe.service (from rev 164185, nrpe/trunk/nrpe.service)
===================================================================
--- community-staging-x86_64/nrpe.service	                        (rev 0)
+++ community-staging-x86_64/nrpe.service	2016-03-02 18:17:10 UTC (rev 164186)
@@ -0,0 +1,13 @@
+[Unit]
+Description=Daemon to answer plugin requests from Nagios on remote hosts
+After=network.target
+Requires=network.target
+
+[Service]
+Type=forking
+User=nrpe
+Group=nrpe
+ExecStart=/usr/bin/nrpe -c /etc/nrpe/nrpe.cfg -d
+
+[Install]
+WantedBy=multi-user.target

Copied: nrpe/repos/community-staging-x86_64/nrpe.socket (from rev 164185, nrpe/trunk/nrpe.socket)
===================================================================
--- community-staging-x86_64/nrpe.socket	                        (rev 0)
+++ community-staging-x86_64/nrpe.socket	2016-03-02 18:17:10 UTC (rev 164186)
@@ -0,0 +1,9 @@
+[Unit]
+Description=NRPE Socket for Per-Connection Servers
+
+[Socket]
+ListenStream=5666
+Accept=yes
+
+[Install]
+WantedBy=sockets.target

Copied: nrpe/repos/community-staging-x86_64/nrpe.tmpfiles (from rev 164185, nrpe/trunk/nrpe.tmpfiles)
===================================================================
--- community-staging-x86_64/nrpe.tmpfiles	                        (rev 0)
+++ community-staging-x86_64/nrpe.tmpfiles	2016-03-02 18:17:10 UTC (rev 164186)
@@ -0,0 +1 @@
+d /run/nrpe 0755 nrpe nrpe -

Copied: nrpe/repos/community-staging-x86_64/nrpe at .service (from rev 164185, nrpe/trunk/nrpe at .service)
===================================================================
--- community-staging-x86_64/nrpe at .service	                        (rev 0)
+++ community-staging-x86_64/nrpe at .service	2016-03-02 18:17:10 UTC (rev 164186)
@@ -0,0 +1,8 @@
+[Unit]
+Description=NRPE Per-Connection Server
+
+[Service]
+ExecStart=-/usr/bin/nrpe -c /etc/nrpe/nrpe.cfg --inetd
+User=nrpe
+Group=nrpe
+StandardInput=socket

Copied: nrpe/repos/community-staging-x86_64/syslog.patch (from rev 164185, nrpe/trunk/syslog.patch)
===================================================================
--- community-staging-x86_64/syslog.patch	                        (rev 0)
+++ community-staging-x86_64/syslog.patch	2016-03-02 18:17:10 UTC (rev 164186)
@@ -0,0 +1,22 @@
+diff --git a/src/nrpe.c b/src/nrpe.c
+index 381f0ac..bc6b227 100644
+--- a/src/nrpe.c
++++ b/src/nrpe.c
+@@ -1131,7 +1131,16 @@ void wait_for_connections(void){
+ 
+ 					/* log info to syslog facility */
+ 					if(debug==TRUE) {
+-						syslog(LOG_DEBUG,"Connection from %s closed.",ipstr);
++						switch(addr.ss_family) {
++							case AF_INET:
++								syslog(LOG_DEBUG,"Connection from %s closed.",
++									inet_ntoa(nptr->sin_addr));
++								break;
++							case AF_INET6:
++								syslog(LOG_DEBUG,"Connection from %s closed.",
++									ipstr);
++								break;
++							}
+ 						}
+ 
+ 					/* close socket prior to exiting */



More information about the arch-commits mailing list