Templates repo

https://github.com/remontti/Zabbix-Templates

HT authentication through zabbix users from DB


chmod go-rxw /etc/zabbix/apache.conf
a2enmod authn_dbd
a2enmod authn_socache
systemctl restart apache2
apt install libaprutil1-dbd-mysql -y

nano /etc/apache2/mods-enabled/authn_dbd.conf

<IfModule mod_dbd.c>
	DBDriver mysql
	DBDParams host=localhost,dbname=zabbix,user=zabbix,pass=appaloosa
	DBDMin 1
	DBDKeep 8
	DBDMax 16
	DBDExptime 300
</IfModule>


<Directory "/zabbix/">
	AuthType Basic
	AuthName "Authentication"
	AuthBasicProvider socache dbd
	AuthnCacheProvideFor dbd
	AuthnCacheContext Authentication
	Require valid-user
	AuthDBDUserPWQuery "SELECT passwd FROM users WHERE username = %s"
</Directory>

<Location "/.well-known">
AuthType None
Require all granted
</Location>