]> git.ipfire.org Git - people/pmueller/ipfire-2.x.git/blobdiff - lfs/zabbix_agentd
suricata: Change midstream policy to "pass-flow"
[people/pmueller/ipfire-2.x.git] / lfs / zabbix_agentd
index b086d9f1a212c4f70273727f990083c005920157..5f274c3098419cf1acb9c1cee018f863cc4dddb7 100644 (file)
@@ -1,7 +1,7 @@
 ###############################################################################
 #                                                                             #
 # IPFire.org - A linux based firewall                                         #
-# Copyright (C) 2007-2019  IPFire Team  <info@ipfire.org>                     #
+# Copyright (C) 2007-2022  IPFire Team  <info@ipfire.org>                     #
 #                                                                             #
 # This program is free software: you can redistribute it and/or modify        #
 # it under the terms of the GNU General Public License as published by        #
@@ -24,7 +24,9 @@
 
 include Config
 
-VER        = 4.0.4
+SUMMARY    = Zabbix Agent
+
+VER        = 6.0.27
 
 THISAPP    = zabbix-$(VER)
 DL_FILE    = $(THISAPP).tar.gz
@@ -32,8 +34,11 @@ DL_FROM    = $(URL_IPFIRE)
 DIR_APP    = $(DIR_SRC)/$(THISAPP)
 TARGET     = $(DIR_INFO)/$(THISAPP)
 PROG       = zabbix_agentd
-PAK_VER    = 1
-DEPS       = ""
+PAK_VER    = 12
+
+DEPS       = fping
+
+SERVICES   = zabbix_agentd
 
 ###############################################################################
 # Top-level Rules
@@ -43,7 +48,7 @@ objects = $(DL_FILE)
 
 $(DL_FILE) = $(DL_FROM)/$(DL_FILE)
 
-$(DL_FILE)_MD5 = 46fdb83d4b24e13127a20a3e874b1d8f
+$(DL_FILE)_BLAKE2 = 793bb887bd8f0d3c2f3d15a4ed9bb5b1fcfb13fcf80ea077672744a1bd8524e213eaf53291e0f9eecb9eb055fee6f1e29e91f890b54698906beac21ca54db4e9
 
 install : $(TARGET)
 
@@ -51,13 +56,13 @@ check : $(patsubst %,$(DIR_CHK)/%,$(objects))
 
 download :$(patsubst %,$(DIR_DL)/%,$(objects))
 
-md5 : $(subst %,%_MD5,$(objects))
+b2 : $(subst %,%_BLAKE2,$(objects))
 
 dist:
        @$(PAK)
 
 ###############################################################################
-# Downloading, checking, md5sum
+# Downloading, checking, b2sum
 ###############################################################################
 
 $(patsubst %,$(DIR_CHK)/%,$(objects)) :
@@ -66,8 +71,8 @@ $(patsubst %,$(DIR_CHK)/%,$(objects)) :
 $(patsubst %,$(DIR_DL)/%,$(objects)) :
        @$(LOAD)
 
-$(subst %,%_MD5,$(objects)) :
-       @$(MD5)
+$(subst %,%_BLAKE2,$(objects)) :
+       @$(B2SUM)
 
 ###############################################################################
 # Installation Details
@@ -80,7 +85,8 @@ $(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
                --prefix=/usr \
                --enable-agent \
                --sysconfdir=/etc/zabbix_agentd \
-               --with-openssl
+               --with-openssl \
+               --with-libcurl
 
        cd $(DIR_APP) && make
        cd $(DIR_APP) && make install
@@ -89,35 +95,48 @@ $(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
        -rmdir /etc/zabbix_agentd/zabbix_agentd.conf.d
        -mkdir -pv /etc/zabbix_agentd/zabbix_agentd.d
        -mkdir -pv /etc/zabbix_agentd/scripts
+       # Move upstream supplied config out of the way for reference
+       # and install our own version of the config.
+       -mv /etc/zabbix_agentd/zabbix_agentd.conf \
+               /etc/zabbix_agentd/zabbix_agentd.conf.example
        install -v -m 644 $(DIR_SRC)/config/zabbix_agentd/zabbix_agentd.conf \
                /etc/zabbix_agentd/zabbix_agentd.conf
 
+       # Install IPFire-specific Zabbix Agent config
+       -mkdir -pv /var/ipfire/zabbix_agentd/userparameters
+       install -v -m 644 $(DIR_SRC)/config/zabbix_agentd/zabbix_agentd_ipfire_mandatory.conf \
+               /var/ipfire/zabbix_agentd/zabbix_agentd_ipfire_mandatory.conf
+       install -v -m 644 $(DIR_SRC)/config/zabbix_agentd/userparameter_pakfire.conf \
+               /var/ipfire/zabbix_agentd/userparameters/userparameter_pakfire.conf
+       install -v -m 644 $(DIR_SRC)/config/zabbix_agentd/userparameter_ipfire.conf \
+               /var/ipfire/zabbix_agentd/userparameters/userparameter_ipfire.conf
+       install -v -m 644 $(DIR_SRC)/config/zabbix_agentd/userparameter_ovpn.conf \
+               /var/ipfire/zabbix_agentd/userparameters/userparameter_ovpn.conf
+
+       # Install IPFire-specific Zabbix Agent scripts
+       -mkdir -pv /var/ipfire/zabbix_agentd/scripts
+       install -v -m 755 $(DIR_SRC)/config/zabbix_agentd/ipfire_certificate_detail.sh \
+               /var/ipfire/zabbix_agentd/scripts/ipfire_certificate_detail.sh
+
        # Create directory for additional agent modules
        -mkdir -pv /usr/lib/zabbix
 
-       # Create directory for logging
-       -mkdir -pv /var/log/zabbix
-       chown zabbix.zabbix /var/log/zabbix
-
        # Create directory for pid.
        -mkdir -pv /var/run/zabbix
        chown zabbix.zabbix /var/run/zabbix
 
        # Install initscripts
-       $(call INSTALL_INITSCRIPT,zabbix_agentd)
+       @$(call INSTALL_INITSCRIPTS,$(SERVICES))
 
        # Install sudoers include file
-       install -v -m 644 $(DIR_SRC)/config/zabbix_agentd/sudoers \
-               /etc/sudoers.d/zabbix.user
+       install -v -m 640 $(DIR_SRC)/config/zabbix_agentd/sudoers \
+               /etc/sudoers.d/zabbix_agentd
+       install -v -m 640 $(DIR_SRC)/config/zabbix_agentd/sudoers_user \
+               /etc/sudoers.d/zabbix_agentd_user
 
        # Install include file for backup
        install -v -m 644 $(DIR_SRC)/config/backup/includes/zabbix_agentd \
                /var/ipfire/backup/addons/includes/zabbix_agentd
 
-       # Install include file for Logrotate
-       -mkdir -pv /etc/logrotate.d
-       install -v -m 644 $(DIR_SRC)/config/zabbix_agentd/logrotate \
-               /etc/logrotate.d/zabbix_agentd
-
        @rm -rf $(DIR_APP)
        @$(POSTBUILD)