2008-02-23 01:02:28 +02:00
|
|
|
# Description: zabbix agent daemon
|
2006-10-28 23:29:12 +03:00
|
|
|
# URL: http://www.zabbix.com
|
2006-10-29 13:57:46 +02:00
|
|
|
# Maintainer: Mikhail Kolesnik, mike at openbunker dot org
|
2006-10-28 23:29:12 +03:00
|
|
|
# Depends on:
|
|
|
|
|
|
|
|
name=zabbix_agentd
|
2011-08-19 15:36:51 +03:00
|
|
|
version=1.8.6
|
2008-03-31 11:00:23 +03:00
|
|
|
release=1
|
2010-11-12 12:03:50 +01:00
|
|
|
source=(http://download.sourceforge.net/zabbix/ZABBIX%20Latest%20Stable/$version/zabbix-$version.tar.gz \
|
2010-01-07 18:55:27 +02:00
|
|
|
$name.conf $name)
|
2006-10-28 23:29:12 +03:00
|
|
|
|
|
|
|
build() {
|
|
|
|
cd zabbix-$version
|
|
|
|
./configure --prefix=/usr \
|
|
|
|
--enable-agent
|
|
|
|
make
|
2010-01-07 18:55:27 +02:00
|
|
|
mkdir -p $PKG/{var/log/$name,var/run/$name,usr/bin}
|
2008-02-23 01:02:28 +02:00
|
|
|
|
2010-01-07 18:55:27 +02:00
|
|
|
touch $PKG/var/log/$name/{zabbix_agentd.log,zabbix_agentd.log.old}
|
|
|
|
chown -R daemon:daemon $PKG/var/log/$name
|
|
|
|
find $PKG/var/log/$name -type f | xargs chmod 600
|
|
|
|
find $PKG/var/log/$name -type d | xargs chmod 700
|
2008-02-23 01:02:28 +02:00
|
|
|
|
2010-01-07 18:55:27 +02:00
|
|
|
touch $PKG/var/run/$name/$name.pid
|
|
|
|
chown -R daemon:daemon $PKG/var/run/$name
|
|
|
|
find $PKG/var/run/$name -type f | xargs chmod 600
|
|
|
|
find $PKG/var/run/$name -type d | xargs chmod 700
|
|
|
|
|
|
|
|
install -m 755 src/zabbix_agent/$name $PKG/usr/bin
|
|
|
|
install -D -m 640 -o daemon -g daemon $SRC/$name.conf $PKG/etc/zabbix/$name.conf
|
|
|
|
install -D -m 755 $SRC/$name $PKG/etc/rc.d/$name
|
2006-10-28 23:29:12 +03:00
|
|
|
}
|