Ad Widget

Collapse

[Problem] : Container Zabbix-Frontend-Apache Mysql | PHP_CONFIG_FILE

Collapse
This topic has been answered.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Samxtnz
    Junior Member
    • Apr 2026
    • 2

    #1

    [Problem] : Container Zabbix-Frontend-Apache Mysql | PHP_CONFIG_FILE

    Hello everyone,
    today i have updated my containers to the latest zabbix :
    zabbix-server-mysql and Zabbix-Frontend-Apache , and my MYSQL container v: 10.11

    the 2 containers MySQL and Server are running Health and everything okay,
    but with the frontend, and for the first time Im having this problem :
    /usr/lib/docker-entrypoint/php.sh: line 9: PHP_CONFIG_FILE: unbound variable

    full log :
    Code:
    2026-04-16T15:04:58Z [info]: ** Preparing Zabbix web-interface (Apache) with MySQL database
    2026-04-16T15:04:58Z [info]: ** Using MYSQL_USER variable from ENV
    2026-04-16T15:04:58Z [info]: ** Using MYSQL_PASSWORD variable from ENV
    2026-04-16T15:04:58Z [info]: ********************
    2026-04-16T15:04:58Z [info]: * DB_SERVER_HOST: 10.0.0.3
    2026-04-16T15:04:58Z [info]: * DB_SERVER_PORT: 3306
    2026-04-16T15:04:58Z [info]: * DB_SERVER_DBNAME: zabbix
    2026-04-16T15:04:58Z [info]: ********************
    2026-04-16T15:04:58Z [info]: ** Preparing PHP configuration
    /usr/lib/docker-entrypoint/php.sh: line 9: PHP_CONFIG_FILE: unbound variable
  • Answer selected by Samxtnz at Today, 11:18.
    Samxtnz
    Junior Member
    • Apr 2026
    • 2

    Hi everyone,

    I managed to solve this issue, so I'm posting the fix here in case anyone else runs into it.

    Root cause:
    This is a breaking change introduced in Zabbix 7.4.9. The entrypoint script `/usr/lib/docker-entrypoint/php.sh` was updated to reference a new environment variable called `PHP_CONFIG_FILE`, which was not required in previous versions. The old variable `PHP_ZBX_CONFIG_FILE` is still present in the image ENV but is no longer read by the script.

    This only affects users running `latest` tag who got auto-updated to 7.4.9.

    Fix:
    Add the `PHP_CONFIG_FILE` environment variable to your `zabbix-frontend` service in `docker-compose.yml`:

    yaml
    Code:
    environment:
    - PHP_CONFIG_FILE=/etc/php85/php-fpm.d/zabbix.conf

    The path should match what you have in `PHP_ZBX_CONFIG_FILE` (for the Alpine/Apache image with PHP 8.5 it is `/etc/php85/php-fpm.d/zabbix.conf`).

    Then recreate the container:


    Code:
    docker compose up -d --force-recreate zabbix-frontend

    The frontend came back up immediately after that.

    Hope this helps!

    Comment

    • johnson.fontenele
      Junior Member
      • Apr 2026
      • 1

      #2
      I'm having the same problem with the tag alpine-7.0-latest. As a workaround, I deployed my environment using the tag alpine-7.0.25.

      Comment

      • Samxtnz
        Junior Member
        • Apr 2026
        • 2

        #3
        Hi everyone,

        I managed to solve this issue, so I'm posting the fix here in case anyone else runs into it.

        Root cause:
        This is a breaking change introduced in Zabbix 7.4.9. The entrypoint script `/usr/lib/docker-entrypoint/php.sh` was updated to reference a new environment variable called `PHP_CONFIG_FILE`, which was not required in previous versions. The old variable `PHP_ZBX_CONFIG_FILE` is still present in the image ENV but is no longer read by the script.

        This only affects users running `latest` tag who got auto-updated to 7.4.9.

        Fix:
        Add the `PHP_CONFIG_FILE` environment variable to your `zabbix-frontend` service in `docker-compose.yml`:

        yaml
        Code:
        environment:
        - PHP_CONFIG_FILE=/etc/php85/php-fpm.d/zabbix.conf

        The path should match what you have in `PHP_ZBX_CONFIG_FILE` (for the Alpine/Apache image with PHP 8.5 it is `/etc/php85/php-fpm.d/zabbix.conf`).

        Then recreate the container:


        Code:
        docker compose up -d --force-recreate zabbix-frontend

        The frontend came back up immediately after that.

        Hope this helps!

        Comment

        Working...