From ec245814bb820363ab218d11863ce5f110f3a889 Mon Sep 17 00:00:00 2001 From: Daniel Berteaud Date: Mon, 13 Nov 2017 23:35:36 +0100 Subject: [PATCH] Initial import --- tito.props | 5 + zabbix-agent.init | 67 ++++ zabbix-agent.service | 20 + zabbix-logrotate.in | 7 + zabbix-proxy.init | 69 ++++ zabbix-proxy.service | 18 + zabbix-proxy.te | 23 ++ zabbix-server.init | 69 ++++ zabbix-server.service | 17 + zabbix-server.te | 34 ++ zabbix-tmpfile.conf | 1 + zabbix-web.conf | 39 ++ zabbix.spec | 1068 +++++++++++++++++++++++++++++++++++++++++++++++++ zabbix_proxy | 12 + zabbix_server | 12 + 15 files changed, 1461 insertions(+) create mode 100644 tito.props create mode 100644 zabbix-agent.init create mode 100644 zabbix-agent.service create mode 100644 zabbix-logrotate.in create mode 100644 zabbix-proxy.init create mode 100644 zabbix-proxy.service create mode 100644 zabbix-proxy.te create mode 100644 zabbix-server.init create mode 100644 zabbix-server.service create mode 100644 zabbix-server.te create mode 100644 zabbix-tmpfile.conf create mode 100644 zabbix-web.conf create mode 100644 zabbix.spec create mode 100644 zabbix_proxy create mode 100644 zabbix_server diff --git a/tito.props b/tito.props new file mode 100644 index 0000000..cbd912b --- /dev/null +++ b/tito.props @@ -0,0 +1,5 @@ +[buildconfig] +builder = tito.builder.GitAnnexBuilder +tagger = tito.tagger.ReleaseTagger + + diff --git a/zabbix-agent.init b/zabbix-agent.init new file mode 100644 index 0000000..a99e9da --- /dev/null +++ b/zabbix-agent.init @@ -0,0 +1,67 @@ +#! /bin/sh +# +# chkconfig: - 85 15 +# description: zabbix agent daemon +# + +### BEGIN INIT INFO +# Provides: zabbix-agent +# Required-Start: $local_fs $network +# Required-Stop: $local_fs $network +# Default-Start: +# Default-Stop: 0 1 2 3 4 5 6 +# Short-Description: start and stop zabbix agent +# Description: Zabbix Agent +### END INIT INFO + +# zabbix details +ZABBIX_AGENTD=/usr/sbin/zabbix_agentd +CONF=/etc/zabbix/zabbix_agentd.conf +PIDFILE=/var/run/zabbix-agent.pid + +# Source function library. +. /etc/rc.d/init.d/functions + +# Source networking configuration. +. /etc/sysconfig/network + +# Check that networking is up. +[ ${NETWORKING} = "no" ] && exit 0 + +[ -x $ZABBIX_AGENTD ] || exit 5 +[ -e $CONF ] || exit 6 + +RETVAL=0 + +case "$1" in + start) + echo -n "Starting Zabbix Agent: " + daemon $ZABBIX_AGENTD -c $CONF + RETVAL=$? + echo + [ $RETVAL -eq 0 ] && touch /var/lock/subsys/zabbix-agent + ;; + stop) + echo -n "Shutting down Zabbix Agent: " + killproc zabbix_agentd + RETVAL=$? + echo + [ $RETVAL -eq 0 ] && rm -f /var/lock/subsys/zabbix-agent + ;; + restart|reload) + $0 stop + $0 start + RETVAL=$? + ;; + status) + status zabbix_agentd + RETVAL=$? + ;; + *) + echo "Usage: $0 {start|stop|restart|reload|status}" + exit 1 + ;; +esac + +exit $RETVAL + diff --git a/zabbix-agent.service b/zabbix-agent.service new file mode 100644 index 0000000..9744d8d --- /dev/null +++ b/zabbix-agent.service @@ -0,0 +1,20 @@ +[Unit] +Description=Zabbix Monitoring Agent +After=syslog.target network.target + +[Service] +Type=forking +ExecStart=/usr/sbin/zabbix_agentd -c /etc/zabbix/zabbix_agentd.conf +PIDFile=/var/run/zabbix/zabbix_agentd.pid +Restart=always +User=zabbix +Group=zabbix +PrivateTmp=yes +CPUShares=512 +MemoryLimit=150M +BlockIOWeight=500 +InaccessibleDirectories=/home +ReadOnlyDirectories=/etc /usr + +[Install] +WantedBy=multi-user.target diff --git a/zabbix-logrotate.in b/zabbix-logrotate.in new file mode 100644 index 0000000..027da64 --- /dev/null +++ b/zabbix-logrotate.in @@ -0,0 +1,7 @@ +/var/log/zabbix/zabbix_COMPONENT.log { + missingok + monthly + notifempty + compress + create 0664 zabbix zabbix +} diff --git a/zabbix-proxy.init b/zabbix-proxy.init new file mode 100644 index 0000000..7ecee22 --- /dev/null +++ b/zabbix-proxy.init @@ -0,0 +1,69 @@ +#! /bin/sh +# +# chkconfig: - 85 15 +# description: zabbix proxy daemon +# + +### BEGIN INIT INFO +# Provides: zabbix +# Required-Start: $local_fs $network +# Required-Stop: $local_fs $network +# Default-Start: +# Default-Stop: 0 1 2 3 4 5 6 +# Short-Description: start and stop zabbix proxy +# Description: Zabbix Proxy +### END INIT INFO + +# zabbix details +if [ -x /usr/sbin/zabbix_proxy_mysql ]; then + ZABBIX_PROXY=zabbix_proxy_mysql +elif [ -x /usr/sbin/zabbix_proxy_pgsql ]; then + ZABBIX_PROXY=zabbix_proxy_pgsql +elif [ -x /usr/sbin/zabbix_proxy_sqlite3 ]; then + ZABBIX_PROXY=zabbix_proxy_sqlite3 +else + exit 5 +fi + +CONF=/etc/zabbix/zabbix_proxy.conf +PIDFILE=/var/run/zabbix.pid + +# Source function library. +. /etc/rc.d/init.d/functions + +[ -e $CONF ] || exit 6 + +RETVAL=0 + +case "$1" in + start) + echo -n "Starting Zabbix Proxy: " + daemon $ZABBIX_PROXY -c $CONF + RETVAL=$? + echo + [ $RETVAL -eq 0 ] && touch /var/lock/subsys/zabbix-proxy + ;; + stop) + echo -n "Shutting down Zabbix Proxy: " + killproc $ZABBIX_PROXY + RETVAL=$? + echo + [ $RETVAL -eq 0 ] && rm -f /var/lock/subsys/zabbix-proxy + ;; + restart|reload) + $0 stop + $0 start + RETVAL=$? + ;; + status) + status $ZABBIX_PROXY + RETVAL=$? + ;; + *) + echo "Usage: $0 {start|stop|restart|reload|status}" + exit 1 + ;; +esac + +exit $RETVAL + diff --git a/zabbix-proxy.service b/zabbix-proxy.service new file mode 100644 index 0000000..e47c722 --- /dev/null +++ b/zabbix-proxy.service @@ -0,0 +1,18 @@ +[Unit] +Description=Zabbix Proxy +After=syslog.target network.target + +[Service] +Type=forking +ExecStart=/usr/sbin/zabbix_proxy -c /etc/zabbix/zabbix_proxy.conf +ExecReload=/usr/sbin/zabbix_proxy -R config_cache_reload +PIDFile=/var/run/zabbix/zabbix_proxy.pid +PrivateTmp=yes +CPUShares=512 +MemoryLimit=50M +BlockIOWeight=500 +InaccessibleDirectories=/home +ReadOnlyDirectories=/etc /usr + +[Install] +WantedBy=multi-user.target diff --git a/zabbix-proxy.te b/zabbix-proxy.te new file mode 100644 index 0000000..cb25f77 --- /dev/null +++ b/zabbix-proxy.te @@ -0,0 +1,23 @@ +module zabbix-proxy 1.1; + +require { + type var_lib_t; + type ping_t; + type initrc_t; + type unlabeled_t; + type zabbix_t; + class file { read getattr }; + class sem { unix_read unix_write associate destroy }; + class shm { unix_read unix_write associate destroy }; + class tcp_socket { create getattr accept shutdown read }; + class netlink_route_socket { create bind }; + class process setrlimit; +} + +#============= ping_t ============== +allow ping_t var_lib_t:file { read getattr }; +allow initrc_t unlabeled_t:sem { unix_read unix_write associate destroy }; +allow initrc_t unlabeled_t:shm { unix_read unix_write associate destroy }; +allow unlabeled_t self:tcp_socket { create getattr accept shutdown read }; +allow unlabeled_t self:netlink_route_socket { create bind }; +allow zabbix_t self:process setrlimit; diff --git a/zabbix-server.init b/zabbix-server.init new file mode 100644 index 0000000..8f8a095 --- /dev/null +++ b/zabbix-server.init @@ -0,0 +1,69 @@ +#! /bin/sh +# +# chkconfig: - 85 15 +# description: zabbix server daemon +# + +### BEGIN INIT INFO +# Provides: zabbix +# Required-Start: $local_fs $network +# Required-Stop: $local_fs $network +# Default-Start: +# Default-Stop: 0 1 2 3 4 5 6 +# Short-Description: start and stop zabbix server +# Description: Zabbix Server +### END INIT INFO + +# zabbix details +if [ -x /usr/sbin/zabbix_server_mysql ]; then + ZABBIX=zabbix_server_mysql +elif [ -x /usr/sbin/zabbix_server_pgsql ]; then + ZABBIX=zabbix_server_pgsql +elif [ -x /usr/sbin/zabbix_server_sqlite3 ]; then + ZABBIX=zabbix_server_sqlite3 +else + exit 5 +fi + +CONF=/etc/zabbix/zabbix_server.conf +PIDFILE=/var/run/zabbix.pid + +# Source function library. +. /etc/rc.d/init.d/functions + +[ -e $CONF ] || exit 6 + +RETVAL=0 + +case "$1" in + start) + echo -n "Starting Zabbix Server: " + daemon $ZABBIX -c $CONF + RETVAL=$? + echo + [ $RETVAL -eq 0 ] && touch /var/lock/subsys/zabbix + ;; + stop) + echo -n "Shutting down Zabbix Server: " + killproc $ZABBIX + RETVAL=$? + echo + [ $RETVAL -eq 0 ] && rm -f /var/lock/subsys/zabbix + ;; + restart|reload) + $0 stop + $0 start + RETVAL=$? + ;; + status) + status $ZABBIX + RETVAL=$? + ;; + *) + echo "Usage: $0 {start|stop|restart|reload|status}" + exit 1 + ;; +esac + +exit $RETVAL + diff --git a/zabbix-server.service b/zabbix-server.service new file mode 100644 index 0000000..ef817c7 --- /dev/null +++ b/zabbix-server.service @@ -0,0 +1,17 @@ +[Unit] +Description=Zabbix Server +After=syslog.target network.target + +[Service] +Type=forking +ExecStart=/usr/sbin/zabbix_server -c /etc/zabbix/zabbix_server.conf +ExecReload=/usr/sbin/zabbix_server -R config_cache_reload +PIDFile=/var/run/zabbix/zabbix_server.pid +PrivateTmp=yes +MemoryLimit=500M +BlockIOWeight=500 +InaccessibleDirectories=/home +ReadOnlyDirectories=/etc /usr + +[Install] +WantedBy=multi-user.target diff --git a/zabbix-server.te b/zabbix-server.te new file mode 100644 index 0000000..506277e --- /dev/null +++ b/zabbix-server.te @@ -0,0 +1,34 @@ +module zabbix-server 1.3; + +require { + type devlog_t; + type zabbix_t; + type ping_t; + type syslogd_t; + type sudo_exec_t; + type zabbix_var_lib_t; + type zabbix_var_run_t; + class process { setrlimit setpgid }; + class capability { sys_resource audit_write }; + class file { execute read create ioctl execute_no_trans write getattr unlink open }; + class netlink_audit_socket { nlmsg_relay create }; + class sock_file { create write}; + class unix_dgram_socket { create connect sendto }; + class dir { write remove_name add_name }; + class key write; + class unix_stream_socket connectto; +} + +allow ping_t zabbix_var_lib_t:file { read getattr }; +allow zabbix_t devlog_t:sock_file write; +allow zabbix_t self:capability { sys_resource audit_write }; +allow zabbix_t self:netlink_audit_socket { nlmsg_relay create }; +allow zabbix_t self:process { setrlimit setpgid }; +allow zabbix_t self:unix_dgram_socket { create connect }; +allow zabbix_t self:key write; +allow zabbix_t sudo_exec_t:file { read execute open execute_no_trans }; +allow zabbix_t syslogd_t:unix_dgram_socket sendto; +allow zabbix_t zabbix_var_lib_t:dir { write remove_name add_name }; +allow zabbix_t zabbix_var_lib_t:file { execute read create getattr execute_no_trans write ioctl unlink open }; +allow zabbix_t self:unix_stream_socket connectto; +allow zabbix_t zabbix_var_run_t:sock_file create; diff --git a/zabbix-tmpfile.conf b/zabbix-tmpfile.conf new file mode 100644 index 0000000..be2c7b2 --- /dev/null +++ b/zabbix-tmpfile.conf @@ -0,0 +1 @@ +d /run/zabbix 750 zabbix zabbix diff --git a/zabbix-web.conf b/zabbix-web.conf new file mode 100644 index 0000000..30b6f55 --- /dev/null +++ b/zabbix-web.conf @@ -0,0 +1,39 @@ +# +# Zabbix monitoring system php web frontend +# + +Alias /zabbix /usr/share/zabbix + + + Options FollowSymLinks + AllowOverride None + + # Apache 2.4 + Require ip 127.0.0.1 + + + + # Apache 2.2 + Order allow,deny + Allow from 127.0.0.1 + + #php_admin_value post_max_size 16M + #php_admin_value max_execution_time 300 + #php_admin_value max_input_time 300 + #php_admin_value date.timezone "Europe/Paris" + + + + + + # Apache 2.4 + Require all denied + + + + Order deny,allow + Deny from all + + + + diff --git a/zabbix.spec b/zabbix.spec new file mode 100644 index 0000000..d5b99a2 --- /dev/null +++ b/zabbix.spec @@ -0,0 +1,1068 @@ +Name: zabbix +Version: 3.4.4 +Release: 1%{?dist} +Summary: Open-source monitoring solution for your IT infrastructure + +Group: Applications/Internet +License: GPLv2 +URL: http://www.zabbix.com/ +Source0: http://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz +Source1: zabbix-web.conf +Source2: zabbix_server +Source3: zabbix_proxy +Source5: zabbix-logrotate.in + +Source6: zabbix-server.te +Source7: zabbix-proxy.te + +Source100: zabbix-server.init +Source101: zabbix-server.service +Source102: zabbix-agent.init +Source103: zabbix-agent.service +Source104: zabbix-proxy.init +Source105: zabbix-proxy.service + +Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) + +BuildRequires: mysql-devel +BuildRequires: postgresql-devel +BuildRequires: net-snmp-devel +BuildRequires: openldap-devel +BuildRequires: gnutls-devel +BuildRequires: iksemel-devel +BuildRequires: curl-devel +BuildRequires: sqlite-devel +BuildRequires: unixODBC-devel +BuildRequires: OpenIPMI-devel +BuildRequires: libevent-devel +BuildRequires: pcre-devel +%if 0%{?rhel} >= 6 +BuildRequires: libssh2-devel +BuildRequires: selinux-policy-devel +BuildRequires: checkpolicy +BuildRequires: bzip2 +BuildRequires: libxml2-devel +BuildRequires: openssl-devel +%endif +%if 0%{?rhel} >= 7 +BuildRequires: systemd +%{?systemd_requires} +%endif + +Requires: logrotate +Requires(pre): /usr/sbin/useradd + +AutoReqProv: no + +%description +ZABBIX is software that monitors numerous parameters of a +network and the health and integrity of servers. ZABBIX +uses a flexible notification mechanism that allows users +to configure e-mail based alerts for virtually any event. +This allows a fast reaction to server problems. ZABBIX +offers excellent reporting and data visualization features +based on the stored data. This makes ZABBIX ideal for +capacity planning. + +ZABBIX supports both polling and trapping. All ZABBIX +reports and statistics, as well as configuration +parameters are accessed through a web-based front end. A +web-based front end ensures that the status of your network +and the health of your servers can be assessed from any +location. Properly configured, ZABBIX can play an important +role in monitoring IT infrastructure. This is equally true +for small organizations with a few servers and for large +companies with a multitude of servers. + +%package server +Summary: Zabbix server common files +Group: Applications/Internet +Requires: zabbix = %{version}-%{release} +Requires: zabbix-server-implementation = %{version}-%{release} +Requires: fping +Requires: net-snmp +Requires(post): /sbin/chkconfig +Requires(preun): /sbin/chkconfig +Requires(preun): /sbin/service +%if 0%{?rhel} >= 6 +Requires(post): /usr/sbin/semodule +Requires(postun): /usr/sbin/semodule +%endif + +%description server +Zabbix server common files + +%package server-mysql +Summary: Zabbix server compiled to use MySQL +Group: Applications/Internet +Requires: zabbix = %{version}-%{release} +Requires: zabbix-server = %{version}-%{release} +Provides: zabbix-server-implementation = %{version}-%{release} +Obsoletes: zabbix <= 1.5.3-0.1 +Conflicts: zabbix-server-pgsql +Conflicts: zabbix-server-sqlite3 + +%description server-mysql +Zabbix server compiled to use MySQL + +%package server-pgsql +Summary: Zabbix server compiled to use PostgresSQL +Group: Applications/Internet +Requires: zabbix = %{version}-%{release} +Requires: zabbix-server = %{version}-%{release} +Provides: zabbix-server-implementation = %{version}-%{release} +Conflicts: zabbix-server-mysql +Conflicts: zabbix-server-sqlite3 + +%description server-pgsql +Zabbix server compiled to use PostgresSQL + +%package agent +Summary: Zabbix Agent +Group: Applications/Internet +Requires: zabbix = %{version}-%{release} +Requires(post): /sbin/chkconfig +Requires(preun): /sbin/chkconfig +Requires(preun): /sbin/service +%if 0%{?rhel} >= 6 +Requires(post): policycoreutils-python +Requires(postun): policycoreutils-python +%endif + +%description agent +The Zabbix client agent, to be installed on monitored systems. + +%package proxy +Summary: Zabbix Proxy +Group: Applications/Internet +Requires: zabbix = %{version}-%{release} +Requires: zabbix-proxy-implementation = %{version}-%{release} +Requires(post): /sbin/chkconfig +Requires(preun): /sbin/chkconfig +Requires(preun): /sbin/service +Requires: fping +Requires: net-snmp +%if 0%{?rhel} >= 6 +Requires(post): /usr/sbin/semodule +Requires(postun):/usr/sbin/semodule +%endif + +%description proxy +The Zabbix proxy + +%package proxy-mysql +Summary: Zabbix proxy compiled to use MySQL +Group: Applications/Internet +Requires: zabbix-proxy = %{version}-%{release} +Provides: zabbix-proxy-implementation = %{version}-%{release} + +%description proxy-mysql +The Zabbix proxy compiled to use MySQL + +%package proxy-pgsql +Summary: Zabbix proxy compiled to use PostgreSQL +Group: Applications/Internet +Requires: zabbix-proxy = %{version}-%{release} +Provides: zabbix-proxy-implementation = %{version}-%{release} + +%description proxy-pgsql +The Zabbix proxy compiled to use PostgreSQL + +%package proxy-sqlite3 +Summary: Zabbix proxy compiled to use SQLite +Group: Applications/Internet +Requires: zabbix-proxy = %{version}-%{release} +Provides: zabbix-proxy-implementation = %{version}-%{release} + +%description proxy-sqlite3 +The Zabbix proxy compiled to use SQLite + +%if 0%{?rhel} >= 6 +%package web +Summary: Zabbix Web Frontend +Group: Applications/Internet +Requires: php-common +Requires: php-gd +Requires: php-bcmath +Requires: php-mbstring +Requires: php-xml +Requires: zabbix = %{version}-%{release} +Requires: zabbix-web-database = %{version}-%{release} + +%description web +The php frontend to display the zabbix web interface. + +%package web-mysql +Summary: Zabbix web frontend for MySQL +Group: Applications/Internet +Requires: zabbix-web = %{version}-%{release} +Requires: php-mysql +Provides: zabbix-web-database = %{version}-%{release} +Obsoletes: zabbix-web <= 1.5.3-0.1 + +%description web-mysql +Zabbix web frontend for MySQL + +%package web-pgsql +Summary: Zabbix web frontend for PostgreSQL +Group: Applications/Internet +Requires: zabbix-web = %{version}-%{release} +Requires: php-pgsql +Provides: zabbix-web-database = %{version}-%{release} + +%description web-pgsql +Zabbix web frontend for PostgreSQL +%endif + +%prep +%setup -q + +mkdir SELinux +mv %{SOURCE6} %{SOURCE7} SELinux + +chmod -R a+rX . + +# fix up some lib64 issues +sed -i -e 's|_LIBDIR=/usr/lib|_LIBDIR=%{_libdir}|g' \ + -e 's|_LDFLAGS=-L/usr/lib|_LDFLAGS=-L%{_libdir}|g' \ + configure + +%build + +%configure \ + --sysconfdir=%{_sysconfdir}/zabbix \ + --enable-dependency-tracking \ + --enable-agent \ + --enable-proxy \ + --enable-ipv6 \ + --with-sqlite3 \ + --with-net-snmp \ + --with-ldap \ + --with-libcurl \ + --with-jabber \ + --with-openipmi \ + --with-unixodbc \ +%if 0%{?rhel} >= 6 + --with-openssl \ + --with-ssh2 \ + --with-libxml2 +%endif + +make %{?_smp_mflags} + +mv src/zabbix_proxy/zabbix_proxy src/zabbix_proxy/zabbix_proxy_sqlite3 + +%configure \ + --sysconfdir=%{_sysconfdir}/zabbix \ + --enable-dependency-tracking \ + --enable-server \ + --enable-agent \ + --enable-proxy \ + --enable-ipv6 \ + --with-postgresql \ + --with-net-snmp \ + --with-ldap \ + --with-libcurl \ + --with-jabber \ + --with-openipmi \ + --with-unixodbc \ +%if 0%{?rhel} >= 6 + --with-openssl \ + --with-ssh2 \ + --with-libxml2 +%endif + +make %{?_smp_mflags} +mv src/zabbix_server/zabbix_server src/zabbix_server/zabbix_server_pgsql +mv src/zabbix_proxy/zabbix_proxy src/zabbix_proxy/zabbix_proxy_pgsql + +%configure \ + --sysconfdir=%{_sysconfdir}/zabbix \ + --enable-dependency-tracking \ + --enable-server \ + --enable-agent \ + --enable-proxy \ + --enable-ipv6 \ + --with-mysql \ + --with-net-snmp \ + --with-ldap \ + --with-libcurl \ + --with-jabber \ + --with-openipmi \ + --with-unixodbc \ +%if 0%{?rhel} >= 6 + --with-openssl \ + --with-ssh2 \ + --with-libxml2 +%endif + +make %{?_smp_mflags} +mv src/zabbix_server/zabbix_server src/zabbix_server/zabbix_server_mysql +mv src/zabbix_proxy/zabbix_proxy src/zabbix_proxy/zabbix_proxy_mysql + +touch src/zabbix_server/zabbix_server +touch src/zabbix_proxy/zabbix_proxy + +%if 0%{?rhel} >= 6 +cd SELinux +make NAME=targeted -f %{_datadir}/selinux/devel/Makefile +bzip2 zabbix-server.pp +bzip2 zabbix-proxy.pp +cd - +%endif + +%install +rm -rf $RPM_BUILD_ROOT +# set up some required directories +mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/%{name} +mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d +mkdir -p $RPM_BUILD_ROOT%{_datadir} +mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/log/%{name} +mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/run/%{name} +mkdir -p $RPM_BUILD_ROOT%{_libdir}/%{name}/modules +%if 0%{?rhel} >= 6 +mkdir -p $RPM_BUILD_ROOT%{_datadir}/selinux/packages/zabbix +mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/httpd/conf.d +%endif +%if 0%{?rhel} >= 7 +mkdir -p $RPM_BUILD_ROOT%{_unitdir} +mkdir -p $RPM_BUILD_ROOT%{_tmpfilesdir} +%else +mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/init.d +%endif + +%if 0%{?rhel} >= 6 +# php frontend +cp -a frontends/php $RPM_BUILD_ROOT%{_datadir}/%{name} +mv $RPM_BUILD_ROOT%{_datadir}/%{name}/include/db.inc.php \ + $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/ +ln -s ../../../..%{_sysconfdir}/%{name}/db.inc.php \ + $RPM_BUILD_ROOT%{_datadir}/%{name}/include/db.inc.php +cat << '__EOF__' >> $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/zabbix.conf.php + +__EOF__ +ln -s ../../../..%{_sysconfdir}/%{name}/zabbix.conf.php \ + $RPM_BUILD_ROOT%{_datadir}/%{name}/conf/zabbix.conf.php +# kill off .htaccess files, options set in SOURCE1 +rm -f $RPM_BUILD_ROOT%{_datadir}/%{name}/include/.htaccess +rm -f $RPM_BUILD_ROOT%{_datadir}/%{name}/include/classes/.htaccess +install -m 0644 -p %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/httpd/conf.d/%{name}.conf +%endif + +# drop config files in place +cat conf/zabbix_agentd.conf | sed \ + -e 's|# PidFile=.*|PidFile=%{_localstatedir}/run/zabbix/zabbix_agentd.pid|g' \ + -e 's|LogFile=.*|LogFile=%{_localstatedir}/log/zabbix/zabbix_agentd.log|g' \ + -e 's|# LogFileSize=.*|LogFileSize=5|g' \ + -e 's|ServerActive=.*|ServerActive=|g' \ + -e 's|Hostname=Zabbix.*|# Hostname=Zabbix_Agent|g' \ + -e 's|# HostnameItem=.*|HostnameItem=system.hostname|g' \ + -e 's|/usr/local/etc/|%{_sysconfdir}/zabbix/|g' \ + -e 's|# Include=/etc/zabbix/zabbix_agentd.conf.d/\*\.conf|Include=%{_sysconfdir}/zabbix/zabbix_agentd.conf.d/*.conf|g' \ + -e 's|# LoadModulePath=.*|LoadModulePath=%{_libdir}/zabbix/modules|g' \ + > $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/zabbix_agentd.conf +cat conf/zabbix_server.conf | sed \ + -e 's|# PidFile=.*|PidFile=%{_localstatedir}/run/zabbix/zabbix_server.pid|g' \ + -e 's|LogFile=.*|LogFile=%{_localstatedir}/log/zabbix/zabbix_server.log|g' \ + -e 's|# SocketDir=.*|SocketDir=%{_localstatedir}/run/zabbix/|g' \ + -e 's|# LogFileSize=.*|LogFileSize=5|g' \ + -e 's|# ExternalScripts=.*|# ExternalScripts==%{_localstatedir}/lib/zabbix/bin|g' \ + -e 's|DBUser=root|DBUser=zabbix|g' \ + -e 's|# DBSocket=/tmp/mysql.sock|DBSocket=%{_localstatedir}/lib/mysql/mysql.sock|g' \ + -e 's|/usr/local/etc/|%{_sysconfdir}/zabbix/|g' \ + -e 's|# LoadModulePath=.*|LoadModulePath=%{_libdir}/zabbix/modules|g' \ + > $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/zabbix_server.conf +cat conf/zabbix_proxy.conf | sed \ + -e 's|# PidFile=.*|PidFile=%{_localstatedir}/run/zabbix/zabbix_proxy.pid|g' \ + -e 's|LogFile=.*|LogFile=%{_localstatedir}/log/zabbix/zabbix_proxy.log|g' \ + -e 's|# LogFileSize=.*|LogFileSize=5|g' \ + -e 's|# ExternalScripts=.*|# ExternalScripts==%{_localstatedir}/lib/zabbix/bin|g' \ + -e 's|DBUser=root|DBUser=zabbix|g' \ + -e 's|# DBSocket=/tmp/mysql.sock|DBSocket=%{_localstatedir}/lib/mysql/mysql.sock|g' \ + -e 's|/usr/local/etc/|%{_sysconfdir}/zabbix/|g' \ + -e 's|# LoadModulePath=.*|LoadModulePath=%{_libdir}/zabbix/modules|g' \ + > $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/zabbix_proxy.conf +# log rotation +cat %{SOURCE5} | sed -e 's|COMPONENT|server|g' > \ + $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d/zabbix-server +cat %{SOURCE5} | sed -e 's|COMPONENT|agentd|g' > \ + $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d/zabbix-agent +cat %{SOURCE5} | sed -e 's|COMPONENT|proxy|g' > \ + $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d/zabbix-proxy +%if 0%{?rhel} >= 7 +# Using systemd, install the wrapper and the unit files +install -m 0644 -p %{SOURCE101} $RPM_BUILD_ROOT%{_unitdir}/ +install -m 0644 -p %{SOURCE103} $RPM_BUILD_ROOT%{_unitdir}/ +install -m 0644 -p %{SOURCE105} $RPM_BUILD_ROOT%{_unitdir}/ +echo "d /var/run/zabbix 0755 zabbix zabbix" >> $RPM_BUILD_ROOT%{_tmpfilesdir}/%{name}.conf +%else +# Using traditional init, install init scripts +install -m 0755 -p %{SOURCE100} $RPM_BUILD_ROOT%{_sysconfdir}/init.d/zabbix-server +install -m 0755 -p %{SOURCE102} $RPM_BUILD_ROOT%{_sysconfdir}/init.d/zabbix-agent +install -m 0755 -p %{SOURCE104} $RPM_BUILD_ROOT%{_sysconfdir}/init.d/zabbix-proxy +%endif + +# set up config dir + +# install +make DESTDIR=$RPM_BUILD_ROOT install +rm $RPM_BUILD_ROOT%{_sbindir}/zabbix_server +install -m 0755 -p src/zabbix_server/zabbix_server_* $RPM_BUILD_ROOT%{_sbindir}/ +rm $RPM_BUILD_ROOT%{_sbindir}/zabbix_proxy +install -m 0755 -p src/zabbix_proxy/zabbix_proxy_* $RPM_BUILD_ROOT%{_sbindir}/ +%if 0%{?rhel} >= 7 +install -m 0755 -p %{SOURCE2} $RPM_BUILD_ROOT%{_sbindir}/ +install -m 0755 -p %{SOURCE3} $RPM_BUILD_ROOT%{_sbindir}/ +%endif + +# nuke static libs and empty oracle upgrade sql +rm -rf $RPM_BUILD_ROOT%{_libdir}/libzbx*.a +# nuke extraneous sql files +rm -rf $RPM_BUILD_ROOT%{_datadir}/%{name}/create +# nuke database Makefiles +rm -f database/Makefile* + +# Install SELinux policies +%if 0%{?rhel} >= 6 +install -m 644 SELinux/zabbix-server.pp.bz2 $RPM_BUILD_ROOT%{_datadir}/selinux/packages/zabbix/ +install -m 644 SELinux/zabbix-proxy.pp.bz2 $RPM_BUILD_ROOT%{_datadir}/selinux/packages/zabbix/ +%endif + +%clean +rm -rf $RPM_BUILD_ROOT + +%pre +# Add the "zabbix" user +/usr/sbin/useradd -c "Zabbix Monitoring System" \ + -s /sbin/nologin -r -d %{_localstatedir}/lib/%{name} zabbix 2> /dev/null || : + +%post server +%if 0%{?rhel} >= 7 +%triggerun -- zabbix-server < 2.2.7 +if /sbin/chkconfig --level 3 zabbix-server; then + /bin/systemctl --no-reload enable zabbix-server.service >/dev/null 2>&1 || : +fi +%systemd_post zabbix-server.service +%else +/sbin/chkconfig --add zabbix-server +%endif +/usr/sbin/semodule -s targeted -i \ + %{_datadir}/selinux/packages/zabbix/zabbix-server.pp.bz2 &> /dev/null || : + +%preun server +%if 0%{?rhel} >= 7 +%systemd_preun zabbix-server.service +%else +if [ $1 -eq 0 ]; then + /sbin/service zabbix-server stop >/dev/null 2>&1 || : + /sbin/chkconfig --del zabbix-server +fi +%endif + +%postun server +%if 0%{?rhel} >= 7 +%systemd_postun +%endif +if [ $1 -eq 0 ] ; then + /usr/sbin/semodule -s targeted -r zabbix-server &> /dev/null || : +fi + +%post agent +%if 0%{?rhel} >= 7 +%triggerun -- zabbix-agent < 2.2.7 +if /sbin/chkconfig --level 3 zabbix-agent; then + /bin/systemctl --no-reload enable zabbix-agent.service >/dev/null 2>&1 || : +fi +%systemd_post zabbix-agent.service +%else +/sbin/chkconfig --add zabbix-agent +%endif +semanage fcontext -a -t bin_t '%{_sbindir}/zabbix_agentd' 2>/dev/null || : +restorecon -R %{_sbindir}/zabbix_agentd || : + +%preun agent +%if 0%{?rhel} >= 7 +%systemd_preun zabbix-agent.service +%else +if [ $1 -eq 0 ]; then + /sbin/service zabbix-agent stop >/dev/null 2>&1 || : + /sbin/chkconfig --del zabbix-agent +fi +%endif + +%postun agent +%if 0%{?rhel} >= 7 +%systemd_postun +%endif +if [ $1 -eq 0 ] ; then + /usr/sbin/semanage fcontext -d -t bin_t '%{_sbindir}/zabbix_agentd' 2>/dev/null || : +fi + +%post proxy +%if 0%{?rhel} >= 7 +%triggerun -- zabbix-proxy < 2.2.7 +if /sbin/chkconfig --level 3 zabbix-proxy; then + /bin/systemctl --no-reload enable zabbix-proxy.service >/dev/null 2>&1 || : +fi +%systemd_post zabbix-proxy.service +%else +/sbin/chkconfig --add zabbix-proxy +%endif +/usr/sbin/semodule -s targeted -i \ + %{_datadir}/selinux/packages/zabbix/zabbix-proxy.pp.bz +if [ $1 -eq 0 ] ; then + /usr/sbin/semodule -s targeted -r zabbix-proxy &> /dev/null || : +fi + +%preun proxy +%if 0%{?rhel} >= 7 +%systemd_preun zabbix-proxy.service +%else +if [ $1 -eq 0 ]; then + /sbin/service zabbix-proxy stop >/dev/null 2>&1 || : + /sbin/chkconfig --del zabbix-proxy +fi +%endif + +%postun proxy +%if 0%{?rhel} >= 7 +%systemd_postun +%endif + +%files +%defattr(-,root,root,-) +%doc AUTHORS ChangeLog COPYING NEWS README +%dir %{_sysconfdir}/zabbix +%attr(0750,zabbix,zabbix) %dir %{_localstatedir}/log/zabbix +%attr(0755,zabbix,zabbix) %dir %{_localstatedir}/run/zabbix +%dir %{_libdir}/%{name}/modules +%if 0%{?rhel} >= 7 +%{_tmpfilesdir}/%{name}.conf +%endif + +%files server +%defattr(-,root,root,-) +%doc AUTHORS ChangeLog COPYING NEWS README +%doc upgrades/dbpatches database +%config(noreplace) %attr(0640,root,zabbix) %{_sysconfdir}/zabbix/zabbix_server.conf +%dir %attr(0750,root,zabbix) %{_sysconfdir}/zabbix/zabbix_server.conf.d +%config(noreplace) %{_sysconfdir}/logrotate.d/zabbix-server +%{_mandir}/man8/zabbix_server.8.gz +%if 0%{?rhel} >= 6 +%{_datadir}/selinux/packages/zabbix/zabbix-server.pp.bz2 +%endif +%if 0%{?rhel} >= 7 +%{_sbindir}/zabbix_server +%{_unitdir}/zabbix-server.service +%else +%{_sysconfdir}/init.d/zabbix-server +%endif + +%files server-mysql +%defattr(-,root,root,-) +%{_sbindir}/zabbix_server_mysql + +%files server-pgsql +%defattr(-,root,root,-) +%{_sbindir}/zabbix_server_pgsql + +%files agent +%defattr(-,root,root,-) +%config(noreplace) %attr(0640,root,zabbix) %{_sysconfdir}/zabbix/zabbix_agentd.conf +%config(noreplace) %{_sysconfdir}/logrotate.d/zabbix-agent +%dir %{_sysconfdir}/zabbix/zabbix_agentd.conf.d +%{_sbindir}/zabbix_agentd +%{_bindir}/zabbix_sender +%{_bindir}/zabbix_get +%{_mandir}/man1/zabbix_get.1.gz +%{_mandir}/man1/zabbix_sender.1.gz +%{_mandir}/man8/zabbix_agentd.8.gz +%if 0%{?rhel} >= 7 +%{_unitdir}/zabbix-agent.service +%else +%{_sysconfdir}/init.d/zabbix-agent +%endif + +%files proxy +%defattr(-,root,root,-) +%config(noreplace) %attr(0640,root,zabbix) %{_sysconfdir}/zabbix/zabbix_proxy.conf +%dir %attr(0750,root,zabbix) %{_sysconfdir}/zabbix/zabbix_proxy.conf.d +%config(noreplace) %{_sysconfdir}/logrotate.d/zabbix-proxy +%{_mandir}/man8/zabbix_proxy.8.gz +%if 0%{?rhel} >= 6 +%{_datadir}/selinux/packages/zabbix/zabbix-proxy.pp.bz2 +%endif +%if 0%{?rhel} >= 7 +%{_sbindir}/zabbix_proxy +%{_unitdir}/zabbix-proxy.service +%else +%{_sysconfdir}/init.d/zabbix-proxy +%endif + +%files proxy-mysql +%defattr(-,root,root,-) +%{_sbindir}/zabbix_proxy_mysql + +%files proxy-pgsql +%defattr(-,root,root,-) +%{_sbindir}/zabbix_proxy_pgsql + +%files proxy-sqlite3 +%defattr(-,root,root,-) +%{_sbindir}/zabbix_proxy_sqlite3 + +%if 0%{?rhel} >= 6 +%files web +%defattr(-,root,root,-) +%config(noreplace) %attr(0640,root,apache) %{_sysconfdir}/zabbix/zabbix.conf.php +%config(noreplace) %attr(0640,root,apache) %{_sysconfdir}/zabbix/db.inc.php +%config(noreplace) %attr(0640,root,apache) %{_sysconfdir}/httpd/conf.d/zabbix.conf +%{_datadir}/zabbix + +%files web-mysql +%defattr(-,root,root,-) + +%files web-pgsql +%defattr(-,root,root,-) +%endif + +%changelog +* Mon Nov 13 2017 Daniel Berteaud 3.4.4-1 +- Remove fastcgi auth patch (daniel@firewall-services.com) + +* Sun Nov 12 2017 Daniel Berteaud 3.4.4-0.beta1 +- new package built with tito +- upgrade to 3.4.4 +* Sun Nov 12 2017 Daniel Berteaud 3.4.4-1.beta1 +- new package built with tito + +* Wed Oct 18 2017 Daniel Berteaud 3.4.3-1 +- Upgrade to 3.4.3 + +* Tue Sep 26 2017 Daniel Berteaud 3.4.2-1 +- Upgrade to 3.4.2 + +* Mon Aug 28 2017 Daniel Berteaud 3.4.1-1 +- Upgrade to 3.4.1 +- Stop building server and web components with SQLite3 as it's not + supported anymore + +* Thu Jul 20 2017 Daniel Berteaud 3.2.7-1 +- Upgrade to 3.2.7 + +* Tue Jun 27 2017 Daniel Berteaud 3.2.6-2 +- Put SELinux policies in /usr/share/selinux/packages/zabbix + +* Wed May 10 2017 Daniel Berteaud 3.2.6-1 +- Upgrade to 3.2.6 + +* Mon Apr 24 2017 Daniel Berteaud 3.2.5-1 +- Upgrade to 3.2.5 + +* Mon Feb 27 2017 Daniel Berteaud 3.2.4-1 +- Upgrade to 3.2.4 + +* Thu Dec 29 2016 Daniel Berteaud 3.2.3-1 +- Upgrade to 3.2.3 +- Adjust SELinux policy for proxy to work on EL 7.3 + +* Wed Dec 7 2016 Daniel Berteaud 3.2.2-1 +- Upgrade to 3.2.2 + +* Mon Oct 3 2016 Daniel Berteaud 3.2.1-1 +- Upgrade to 3.2.1 + +* Wed Sep 14 2016 Daniel Berteaud 3.2.0-1 +- Upgrade to 3.2.0 + +* Mon Jul 25 2016 Daniel Berteaud 3.0.4-1 +- Update to 3.0.4 + +* Mon May 23 2016 Daniel Berteaud 3.0.3-1 +- Update to 3.0.3 + +* Thu Apr 21 2016 Daniel Berteaud 3.0.2-1 +- Update to 3.0.2 + +* Thu Mar 24 2016 Daniel Berteaud 3.0.1-2 +- Drop config_path patch and use --sysconfdir option to configure instead + +* Wed Mar 23 2016 Daniel Berteaud 3.0.1-1 +- Upstream upgrade to 3.0.1 +- Stop building the web packages for el5 + +* Wed Mar 16 2016 Daniel Berteaud 2.4.7-2 +- Make auth working with FastCGI by also checking REDIRECT_PHP_AUTH_USER + +* Thu Nov 12 2015 Daniel Berteaud 2.4.7-1 +- Update to 2.4.7 + +* Tue Sep 1 2015 Daniel Berteaud 2.4.6-1 +- Update to 2.4.6 + +* Fri Jul 24 2015 Daniel Berteaud 2.4.5-2 +- Rise mem limit to 150M for the agent + +* Wed Apr 22 2015 Daniel Berteaud 2.4.5-1 +- Update to 2.4.5 + +* Tue Mar 3 2015 Daniel Berteaud 2.4.4-1 +- Update to 2.4.4 +- Create zabbix_agent.conf.d +- Fix dupplicated Include directives + +* Tue Feb 10 2015 Daniel Berteaud 2.4.3-2 +- Don't include conf.d fragments two times + +* Mon Feb 9 2015 Daniel Berteaud 2.4.3-1 +- Update to 2.4.3 + +* Fri Dec 12 2014 Daniel Berteaud 2.4.2-1 +- Update to 2.4.2 + +* Wed Dec 3 2014 Daniel Berteaud 2.2.7-4 +- Rise mem limit for the agent as some external scripts + require more than 10M + +* Tue Nov 4 2014 Daniel Berteaud 2.2.7-3 +- Fix server postun scriplet +- Fix SELinux policy for the server component on EL6.6 + +* Wed Oct 29 2014 Daniel Berteaud 2.2.7-2 +- Fix agent restart under systemd +- Restart the agent if it exits (under systemd) +- Add resources limits (CPU, memory and IO) +- Make /etc and /usr read only (systemd only) +- Prevent access to /home (systemd only) + +* Tue Oct 28 2014 Daniel Berteaud 2.2.7-1 +- Update to 2.2.7 +- Provide systemd unit for RHEL >= 7 +- Include a tmpfiles.d fragment to create rundir for RHEL >= 7 +- Various cleanups + +* Tue Sep 9 2014 Daniel Berteaud 2.2.6-3 +- Adapt httpd conf to work with apache 2.4 +- Stop using /etc/sysconfig/network + +* Tue Sep 9 2014 Daniel Berteaud 2.2.6-2 +- Build with libxml2 + +* Mon Sep 1 2014 Daniel Berteaud 2.2.6-1 +- Update to 2.2.6 + +* Tue Jul 22 2014 Daniel Berteaud 2.2.5-1 +- Update to 2.2.5 + +* Tue Jun 24 2014 Daniel Berteaud 2.2.4-1 +- Update to 2.2.4 + +* Thu Jun 12 2014 Daniel Berteaud 2.2.3-2 +- Fix some SELinux AVC on server side + +* Mon Apr 14 2014 Daniel Berteaud 2.2.3-1 +- Upgrade to 2.2.3 + +* Thu Feb 13 2014 Daniel Berteaud 2.2.2-1 +- Upgrade to 2.2.2 + +* Fri Jan 17 2014 Daniel Berteaud 2.2.1-2 +- Add missing dependency on net-snmp for proxy packages + +* Thu Dec 12 2013 Daniel Berteaud 2.2.1-1 +- update to 2.2.1 + +* Sun Dec 8 2013 Daniel Berteaud 2.2.0-4 +- Fix SELinux related dependencies for EL5 + +* Fri Dec 6 2013 Daniel Berteaud 2.2.0-3 +- Set bin_t context for zabbix_agentd +- Provide a SELinux policy for server and proxy (for EL6 and above) + +* Thu Nov 28 2013 Daniel Berteaud 2.2.0-2 +- Fix permissions on db.inc.ph and zabbix.conf.php + +* Wed Nov 27 2013 Daniel Berteaud 2.2.0-1 +- upgrade to 2.2.0 +- Improve default config +- Restrict access to config files +- Build with OpenIPMI support +- Build with libssh2 support on EL6 +- Cleanup the spec file (rpmlint) + +* Wed Oct 9 2013 Daniel Berteaud 2.0.9-1 +- upgrade to 2.0.9 + +* Wed Aug 21 2013 Daniel Berteaud 2.0.8-1 +- upgrade to 2.0.8 + +* Tue Aug 20 2013 Daniel Berteaud 2.0.7-1 +- upgrade to 2.0.7 + +* Mon May 13 2013 Daniel Berteaud 2.0.6-1 +- upgrade to 2.0.6 + +* Fri Feb 22 2013 Daniel Berteaud 2.0.5-1 +- upgrade to 2.0.5 + +* Tue Dec 11 2012 Daniel Berteaud 2.0.4-1 +- upgrade to 2.0.4 + +* Thu Oct 4 2012 Daniel Berteaud 2.0.3-1 +- upgrade to 2.0.3 + +* Thu Aug 16 2012 Daniel Berteaud 2.0.2-1 +- upgrade to 2.0.2 + +* Sat Jun 30 2012 Daniel Berteaud 2.0.1-9 +- upgrade to 2.0.1 + +* Wed May 23 2012 Daniel Berteaud 2.0.0-9 +- upgrade to 2.0.0 + +* Mon May 14 2012 Daniel Berteaud 1.8.13-9 +- upstream upgrade to 1.8.13 + +* Thu Apr 26 2012 Daniel B. 1.8.12-9 +- upstream upgrade to 1.8.12 + +* Fri Mar 30 2012 Daniel B. 1.8.11-9 +- upstream upgrade to 1.8.11 +- drop patches and support for EL4 + +* Tue Feb 07 2012 Daniel B. 1.8.10-8 +- upstream upgrade to 1.8.10 + +* Tue Nov 22 2011 Daniel B. 1.8.9-8 +- upstream upgrade to 1.8.9 + +* Fri Oct 28 2011 Daniel B. 1.8.8-7 +- Rebuild against correct sqlite-devel package + +* Wed Sep 28 2011 Daniel B. 1.8.8-6 +- upstream upgrade to 1.8.8 + +* Thu Sep 01 2011 Daniel B. 1.8.7-6 +- upstream upgrade to 1.8.7 + +* Wed May 11 2011 Daniel B. 1.8.5-5 +- upstream upgrade to 1.8.5 + +* Thu Jan 06 2011 Daniel B. 1.8.4-4 +- Fix include path for schema.inc.php + +* Tue Jan 04 2011 Daniel B. 1.8.4-3 +- upstream upgrade to 1.8.4 + +* Tue Aug 24 2010 Daniel B. 1.8.3-3 +- upstream upgrade to 1.8.3 + +* Sun Jun 6 2010 Daniel B. 1.8.2-3 +- just a release bump + +* Thu Apr 29 2010 Daniel B. 1.8.2-2 +- fixe regression for mysql users (ZBX-1126) +- re-add php-bcmath dependency + +* Thu Apr 15 2010 Daniel B. 1.8.2-1 +- no change + +* Tue Feb 16 2010 Daniel B. 1.8.2-0.beta0 +- upstream upgrade to 1.8.2 + +* Tue Feb 16 2010 Daniel B. 1.8.1-0.beta0 +- upstream upgrade to 1.8.1 + +* Tue Dec 1 2009 Daniel B. 1.7.3-0.beta0 +- upstream upgrade to 1.7.3 + +* Fri Nov 13 2009 Daniel B. 1.6.7-1 +- Upstream upgrade to 1.6.7 + +* Mon Sep 21 2009 Daniel B. 1.6.6-1 +- Upstream upgrade to 1.6.6 +- remove compatibility patch for el4 + +* Tue Jun 16 2009 Daniel B. 1.6.5-1 +- Upstream upgrade to 1.6.5 + +* Mon Apr 06 2009 Daniel B. 1.6.4-1 +- Upstream upgrade to 1.6.4 + +* Fri Mar 27 2009 Daniel B. 1.6.3-0 +- Upstream upgrade to 1.6.3 +- Remove CPUstat patch +- Remove snmp fixes (not needed anymore) + +* Tue Mar 03 2009 Daniel B. 1.6.2-4 +- Comment hard-coded php-bcmath dependencie as php4 includes this module + +* Fri Jan 30 2009 Daniel B. 1.6.2-3 +- Added patch so it can compile on CentOS 4 (curl 7.12.1) + +* Fri Jan 23 2009 Jeffrey C. Ollie - 1.6.2-2 +- Rebuild for MySQL 5.1.X + +* Fri Jan 16 2009 Jeffrey C. Ollie - 1.6.2-1 +- Update to 1.6.2: http://www.zabbix.com/rn1.6.2.php + +* Thu Dec 4 2008 Jeffrey C. Ollie - 1.6.1-1 +- Fix BZ#474593 by adding a requires. + +* Wed Nov 5 2008 Jeffrey C. Ollie - 1.6.1-1 +- Update to 1.6.1 + +* Tue Sep 30 2008 Jeffrey C. Ollie - 1.6-1.1 +- Bump release because forgot to add some new files. + +* Tue Sep 30 2008 Jeffrey C. Ollie - 1.6-1 +- Update to final 1.6 + +* Mon Aug 11 2008 Jason L Tibbitts III - 1.4.6-2 +- Fix license tag. + +* Fri Jul 25 2008 Jeffrey C. Ollie - 1.4.6-1 +- Update to 1.4.6 + +* Mon Jul 07 2008 Dan Horak - 1.4.5-4 +- add LSB headers into init scripts +- disable internal log rotation + +* Fri May 02 2008 Jarod Wilson - 1.4.5-3 +- Seems the zabbix folks replaced the original 1.4.5 tarball with + an updated tarball or something -- it actually does contain a + tiny bit of additional code... So update to newer 1.4.5. + +* Tue Apr 08 2008 Jarod Wilson - 1.4.5-2 +- Fix building w/postgresql (#441456) + +* Tue Mar 25 2008 Jeffrey C. Ollie - 1.4.5-1 +- Update to 1.4.5 + +* Thu Feb 14 2008 Jarod Wilson - 1.4.4-2 +- Bump and rebuild with gcc 4.3 + +* Mon Dec 17 2007 Jarod Wilson - 1.4.4-1 +- New upstream release +- Fixes two crasher bugs in 1.4.3 release + +* Wed Dec 12 2007 Jarod Wilson - 1.4.3-1 +- New upstream release + +* Thu Dec 06 2007 Release Engineering - 1.4.2-5 +- Rebuild for deps + +* Sat Dec 01 2007 Dan Horak 1.4.2-4 +- add security fix (#407181) + +* Thu Sep 20 2007 Dan Horak 1.4.2-3 +- Add a patch to clean a warning during compile +- Add a patch to fix cpu load computations + +* Tue Aug 21 2007 Jarod Wilson 1.4.2-2 +- Account for binaries moving from %%_bindir to %%_sbindir + +* Tue Aug 21 2007 Jarod Wilson 1.4.2-1 +- New upstream release + +* Mon Jul 02 2007 Jarod Wilson 1.4.1-1 +- New upstream release + +* Fri Jun 29 2007 Jarod Wilson 1.4-3 +- Install correct sql init files (#244991) +- Add Requires: php-bcmath to zabbix-web (#245767) + +* Wed May 30 2007 Jarod Wilson 1.4-2 +- Add placeholder zabbix.conf.php + +* Tue May 29 2007 Jarod Wilson 1.4-1 +- New upstream release + +* Fri Mar 30 2007 Jarod Wilson 1.1.7-1 +- New upstream release + +* Wed Feb 07 2007 Jarod Wilson 1.1.6-1 +- New upstream release + +* Thu Feb 01 2007 Jarod Wilson 1.1.5-1 +- New upstream release + +* Tue Jan 02 2007 Jarod Wilson 1.1.4-5 +- Add explicit R:php to zabbix-web (#220676) + +* Wed Dec 13 2006 Jarod Wilson 1.1.4-4 +- Fix snmp polling buffer overflow (#218065) + +* Wed Nov 29 2006 Jarod Wilson 1.1.4-3 +- Rebuild for updated libnetsnmp + +* Thu Nov 16 2006 Jarod Wilson 1.1.4-2 +- Fix up pt_br +- Add Req-pre on useradd + +* Wed Nov 15 2006 Jarod Wilson 1.1.4-1 +- Update to 1.1.4 + +* Tue Nov 14 2006 Jarod Wilson 1.1.3-3 +- Add BR: gnutls-devel, R: net-snmp-libs + +* Tue Nov 14 2006 Jarod Wilson 1.1.3-2 +- Fix php-pgsql Requires + +* Tue Nov 14 2006 Jarod Wilson 1.1.3-1 +- Update to 1.1.3 + +* Mon Oct 02 2006 Jarod Wilson 1.1.2-1 +- Update to 1.1.2 +- Enable alternate building with postgresql support + +* Thu Aug 17 2006 Jarod Wilson 1.1.1-2 +- Yank out Requires: mysql-server +- Add Requires: for php-gd and fping + +* Tue Aug 15 2006 Jarod Wilson 1.1.1-1 +- Update to 1.1.1 +- More macroification +- Fix up zabbix-web Requires: +- Prep for enabling postgres support + +* Thu Jul 27 2006 Jarod Wilson 1.1-2 +- Add Requires: on chkconfig and service +- Remove openssl-devel from BR, mysql-devel pulls it in +- Alter scriptlets to match Fedora conventions + +* Tue Jul 11 2006 Jarod Wilson 1.1-1 +- Initial build for Fedora Extras diff --git a/zabbix_proxy b/zabbix_proxy new file mode 100644 index 0000000..0e9b4c0 --- /dev/null +++ b/zabbix_proxy @@ -0,0 +1,12 @@ +#!/bin/sh +exec 2>&1 +if [ -x /usr/sbin/zabbix_proxy_mysql ]; then + ZABBIX=/usr/sbin/zabbix_proxy_mysql +elif [ -x /usr/sbin/zabbix_proxy_pgsql ]; then + ZABBIX=/usr/sbin/zabbix_proxy_pgsql +elif [ -x /usr/sbin/zabbix_proxy_sqlite3 ]; then + ZABBIX=/usr/sbin/zabbix_proxy_sqlite3 +else + exit 1 +fi +$ZABBIX "$@" diff --git a/zabbix_server b/zabbix_server new file mode 100644 index 0000000..c04b862 --- /dev/null +++ b/zabbix_server @@ -0,0 +1,12 @@ +#!/bin/sh +exec 2>&1 +if [ -x /usr/sbin/zabbix_server_mysql ]; then + ZABBIX=/usr/sbin/zabbix_server_mysql +elif [ -x /usr/sbin/zabbix_server_pgsql ]; then + ZABBIX=/usr/sbin/zabbix_server_pgsql +elif [ -x /usr/sbin/zabbix_server_sqlite3 ]; then + ZABBIX=/usr/sbin/zabbix_server_sqlite3 +else + exit 1 +fi +$ZABBIX "$@"