wok-6.x view nagios-plugins/receipt @ rev 20998
updated gqview (2.0.4 -> 2.1.5)
author | Hans-G?nter Theisgen |
---|---|
date | Fri Mar 08 13:18:18 2019 +0100 (2019-03-08) |
parents | 970c5ec9a60a |
children | 269143578a96 |
line source
1 # SliTaz package receipt.
3 PACKAGE="nagios-plugins"
4 VERSION="1.4.16"
5 CATEGORY="network"
6 SHORT_DESC="Plugins for host, service and network monitoring program."
7 MAINTAINER="erjo@slitaz.org"
8 LICENSE="GPL3"
9 TARBALL="$PACKAGE-$VERSION.tar.gz"
10 WEB_SITE="https://www.nagios.org/"
11 WGET_URL="$SF_MIRROR/nagiosplug/$TARBALL"
13 DEPENDS="libssl fping"
14 BUILD_DEPENDS="openssl-dev radiusclient-ng-dev radiusclient-ng openldap-dev
15 mysql-dev libmysqlclient"
17 # Rules to configure and make the package.
18 compile_rules()
19 {
20 cd $src
21 ./configure --prefix=/usr \
22 --libexecdir=/usr/lib/nagios/plugins \
23 --with-nagios-user=nobody \
24 --with-nagios-group=nogroup \
25 --with-ping-command="/bin/ping -w %d -c %d %s" \
26 --with-fping-command="/usr/sbin/fping" \
27 --mandir=/usr/share/man $CONFIGURE_ARGS
29 make &&
30 make DESTDIR=$DESTDIR install &&
31 make DESTDIR=$DESTDIR install-root
32 }
34 # Rules to gen a SliTaz package suitable for Tazpkg.
35 genpkg_rules()
36 {
37 mkdir -p $fs/usr/lib $fs/etc/nagios/objects
39 cp -a $install/usr/lib/nagios/ $fs/usr/lib
41 #
42 stuff/convertcfg $src/command.cfg commands > $fs/etc/nagios/objects/command.cfg
44 # Move mySQL plugins in separate package.
45 rm -f $fs/usr/lib/nagios/plugins/*mysql*
47 }
49 post_install()
50 {
51 if ! grep -q nagios "$1/etc/passwd"; then
52 echo
53 echo -n "Adding user/group nagios..."
54 chroot "$1/" addgroup -S nagios
55 chroot "$1/" adduser -S -D -H -G nagios nagios
56 status
57 fi
59 if [ -f "$1/etc/nagios/resource.cfg" ]; then
60 sed -i 's|/usr/lib/nagios|/usr/lib/nagios/plugins|' \
61 "$1/etc/nagios/resource.cfg"
62 fi
63 # Set perms for files and directories
64 chroot "$1/" chown -R nagios.nagios /usr/lib/nagios/plugins
65 chroot "$1/" chown -R nagios.nagios /etc/nagios/objects
66 }