aboutsummaryrefslogtreecommitdiffstats
path: root/databases
diff options
context:
space:
mode:
authordbaio <dbaio@FreeBSD.org>2017-08-27 02:39:50 +0800
committerdbaio <dbaio@FreeBSD.org>2017-08-27 02:39:50 +0800
commiteaaffed8ce07d4455eca06974200ad3a9bc07086 (patch)
treea1d9780f45c5d5bfa562331ed88de1797b7cc2eb /databases
parent1ce32278904e8abac137857647b6aa54f04e6cff (diff)
downloadfreebsd-ports-gnome-eaaffed8ce07d4455eca06974200ad3a9bc07086.tar.gz
freebsd-ports-gnome-eaaffed8ce07d4455eca06974200ad3a9bc07086.tar.zst
freebsd-ports-gnome-eaaffed8ce07d4455eca06974200ad3a9bc07086.zip
New port databases/zabbix22-libzbxpgsql: PostgreSQL monitoring module for zabbix22-agent
This project provides comprehensive monitoring of PostgreSQL servers using a natively compiled Zabbix agent module, written in C. The module enables discovery and monitoring of tablespaces, databases, namespaces, tables, indexes, etc. WWW: http://cavaliercoder.com/libzbxpgsql/ databases/zabbix3-libzbxpgsql -> databases/zabbix22-libzbxpgsql PR: 221830 Submitted by: Martin Waschbüsch <martin@waschbuesch.de>
Diffstat (limited to 'databases')
-rw-r--r--databases/Makefile1
-rw-r--r--databases/zabbix22-libzbxpgsql/Makefile42
-rw-r--r--databases/zabbix22-libzbxpgsql/distinfo3
-rw-r--r--databases/zabbix22-libzbxpgsql/files/patch-src_libzbxpgsql.c12
-rw-r--r--databases/zabbix22-libzbxpgsql/pkg-descr7
-rw-r--r--databases/zabbix22-libzbxpgsql/pkg-message3
-rw-r--r--databases/zabbix22-libzbxpgsql/pkg-plist4
7 files changed, 72 insertions, 0 deletions
diff --git a/databases/Makefile b/databases/Makefile
index 6ec65af144be..091eeb13598d 100644
--- a/databases/Makefile
+++ b/databases/Makefile
@@ -1042,6 +1042,7 @@
SUBDIR += xapian-core10
SUBDIR += xapian-core12
SUBDIR += xtrabackup
+ SUBDIR += zabbix22-libzbxpgsql
SUBDIR += zabbix3-libzbxpgsql
SUBDIR += zodb3
diff --git a/databases/zabbix22-libzbxpgsql/Makefile b/databases/zabbix22-libzbxpgsql/Makefile
new file mode 100644
index 000000000000..65db8889bbe0
--- /dev/null
+++ b/databases/zabbix22-libzbxpgsql/Makefile
@@ -0,0 +1,42 @@
+# Created by: Martin Waschbuesch <martin@waschbuesch.de>
+# $FreeBSD$
+
+PORTNAME= libzbxpgsql
+PORTVERSION= 1.1.0
+DISTVERSIONPREFIX= v
+CATEGORIES= databases
+PKGNAMEPREFIX= zabbix22-
+
+MAINTAINER= martin@waschbuesch.de
+COMMENT= Zabbix agent module for comprehensive monitoring of PostgreSQL servers
+
+LICENSE= GPLv2+
+LICENSE_FILE= ${WRKSRC}/COPYING
+
+BUILD_DEPENDS= ${NONEXISTENT}:net-mgmt/${PKGNAMEPREFIX}agent:patch
+RUN_DEPENDS= zabbix_agentd:net-mgmt/${PKGNAMEPREFIX}agent
+LIB_DEPENDS= libconfig.so:devel/libconfig
+
+CONFLICTS= zabbix[0-13-9][0-13-9]-libzbxpgsql zabbix[0-9]-libzbxpgsql
+
+USES= autoreconf gmake libtool pgsql
+
+USE_GITHUB= yes
+GH_ACCOUNT= cavaliercoder
+
+GNU_CONFIGURE= yes
+GET_ZBX_WRKSRC= cd ${.CURDIR:H:H}/net-mgmt/${PKGNAMEPREFIX}agent && make -V WRKSRC
+CONFIGURE_ARGS= --with-zabbix=$$(${GET_ZBX_WRKSRC})
+
+USE_LDCONFIG= yes
+
+OPTIONS_DEFINE= EXAMPLES
+
+do-install:
+ ${INSTALL_LIB} ${WRKSRC}/src/.libs/libzbxpgsql.so ${STAGEDIR}${PREFIX}/lib/libzbxpgsql.so
+
+do-install-EXAMPLES-on:
+ ${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
+ ${INSTALL_DATA} ${WRKSRC}/templates/*.xml ${STAGEDIR}${EXAMPLESDIR}
+
+.include <bsd.port.mk>
diff --git a/databases/zabbix22-libzbxpgsql/distinfo b/databases/zabbix22-libzbxpgsql/distinfo
new file mode 100644
index 000000000000..269563ce15d3
--- /dev/null
+++ b/databases/zabbix22-libzbxpgsql/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1503755196
+SHA256 (cavaliercoder-libzbxpgsql-v1.1.0_GH0.tar.gz) = 50acc4364241253a013058daf76c4184cc522104f78005d3c4d5e7e09d77571a
+SIZE (cavaliercoder-libzbxpgsql-v1.1.0_GH0.tar.gz) = 61106
diff --git a/databases/zabbix22-libzbxpgsql/files/patch-src_libzbxpgsql.c b/databases/zabbix22-libzbxpgsql/files/patch-src_libzbxpgsql.c
new file mode 100644
index 000000000000..e1ae90077e39
--- /dev/null
+++ b/databases/zabbix22-libzbxpgsql/files/patch-src_libzbxpgsql.c
@@ -0,0 +1,12 @@
+--- src/libzbxpgsql.c.orig 2016-06-25 14:18:03 UTC
++++ src/libzbxpgsql.c
+@@ -24,6 +24,9 @@
+ */
+
+ #include "libzbxpgsql.h"
++#include <sys/types.h>
++#include <sys/socket.h>
++#include <netinet/in.h>
+
+ // Define custom keys
+ static ZBX_METRIC keys[] =
diff --git a/databases/zabbix22-libzbxpgsql/pkg-descr b/databases/zabbix22-libzbxpgsql/pkg-descr
new file mode 100644
index 000000000000..0b6a261aae10
--- /dev/null
+++ b/databases/zabbix22-libzbxpgsql/pkg-descr
@@ -0,0 +1,7 @@
+This project provides comprehensive monitoring of PostgreSQL servers using a
+natively compiled Zabbix agent module, written in C.
+
+The module enables discovery and monitoring of tablespaces, databases,
+namespaces, tables, indexes, etc.
+
+WWW: http://cavaliercoder.com/libzbxpgsql/
diff --git a/databases/zabbix22-libzbxpgsql/pkg-message b/databases/zabbix22-libzbxpgsql/pkg-message
new file mode 100644
index 000000000000..23d85feb7007
--- /dev/null
+++ b/databases/zabbix22-libzbxpgsql/pkg-message
@@ -0,0 +1,3 @@
+In order to enable the module, add libzbxpgsql.so to the LoadModule=
+line in zabbix_agentd.conf and restart the agent with
+service zabbix_agentd restart
diff --git a/databases/zabbix22-libzbxpgsql/pkg-plist b/databases/zabbix22-libzbxpgsql/pkg-plist
new file mode 100644
index 000000000000..765ec35e2459
--- /dev/null
+++ b/databases/zabbix22-libzbxpgsql/pkg-plist
@@ -0,0 +1,4 @@
+lib/libzbxpgsql.so
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/Template_PostgreSQL_Server_2.0.xml
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/Template_PostgreSQL_Server_2.4.xml
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/Template_PostgreSQL_Server_3.0.xml