Hi All,
I really would appreciate some help. I have Zabbix 5.4 working well with Apache 2.4 on FreeBSD. I really wanted to switch to OpenBSD's httpd so I installed obhttpd on FreebSD and configured it based on what I saw at this site https://daulton.ca/2020/03/openbsd-zabbix-server/ When I stop Apache and start obhttpd with php-fpm I get the error, " Cannot connect to database" It works with Apache at the moment, but not obhttpd. My obhttpd config is below.
chroot "/usr/local/www"
server "zabbix.domain.net" {
listen on "*" port 80
block return 302 "https://$HTTP_HOST$REQUEST_URI"
# root "/zabbix54"
# directory index index.php
}
server "zabbix.domain.net" {
listen on "*" tls port 443
root "/zabbix54"
tls {
certificate "/usr/local/etc/apache24/ssl/domain.net.crt"
key "/usr/local/etc/apache24/ssl/domain.net.key"
}
# Increase connection limits to extend the lifetime
connection { max requests 500, timeout 3600 }
connection { max request body 8388608 }
directory {
index "index.php"
}
location "/zabbix/conf/*" {
block return 401
}
location "*.php" {
fastcgi socket "/run/php-fpm.sock"
}
}
I really would appreciate some help. I have Zabbix 5.4 working well with Apache 2.4 on FreeBSD. I really wanted to switch to OpenBSD's httpd so I installed obhttpd on FreebSD and configured it based on what I saw at this site https://daulton.ca/2020/03/openbsd-zabbix-server/ When I stop Apache and start obhttpd with php-fpm I get the error, " Cannot connect to database" It works with Apache at the moment, but not obhttpd. My obhttpd config is below.
chroot "/usr/local/www"
server "zabbix.domain.net" {
listen on "*" port 80
block return 302 "https://$HTTP_HOST$REQUEST_URI"
# root "/zabbix54"
# directory index index.php
}
server "zabbix.domain.net" {
listen on "*" tls port 443
root "/zabbix54"
tls {
certificate "/usr/local/etc/apache24/ssl/domain.net.crt"
key "/usr/local/etc/apache24/ssl/domain.net.key"
}
# Increase connection limits to extend the lifetime
connection { max requests 500, timeout 3600 }
connection { max request body 8388608 }
directory {
index "index.php"
}
location "/zabbix/conf/*" {
block return 401
}
location "*.php" {
fastcgi socket "/run/php-fpm.sock"
}
}
Comment