Listen 8080

<VirtualHost *:8080>
    RemoteIPInternalProxy ${WEB_REAL_IP_FROM}
    RemoteIPHeader ${WEB_REAL_IP_HEADER}

    <LocationMatch "/(ping|status)">
        Require all granted

        SetHandler "proxy:unix:/tmp/php-fpm.sock|fcgi://localhost"
    </LocationMatch>

    <Directory "/usr/share/zabbix">
        Options FollowSymLinks
        AllowOverride None
        Require all granted

        <FilesMatch \.php$>
            SetHandler "proxy:unix:/tmp/php-fpm.sock|fcgi://localhost"
        </FilesMatch>

        <filesMatch "\.(ico)$">
            ExpiresActive On
            ExpiresDefault "access plus 1 year"
            Header append Cache-Control "public"
        </filesMatch>

        <filesMatch "\.(js|css|png|jpg|jpeg|gif|xml|txt)$">
            ExpiresActive On
            ExpiresDefault "access plus 14 day"
            Header append Cache-Control "public"
        </filesMatch>
    </Directory>

    <Directory "/usr/share/zabbix/conf">
        Require all denied
        <files *.php>
            Require all denied
        </files>
    </Directory>

    <Directory "/usr/share/zabbix/app">
        Require all denied
        <files *.php>
            Require all denied
        </files>
    </Directory>

    <Directory "/usr/share/zabbix/include">
        Require all denied
        <files *.php>
            Require all denied
        </files>
    </Directory>

    <Directory "/usr/share/zabbix/local">
        Require all denied
        <files *.php>
            Require all denied
        </files>
    </Directory>

    <Directory "/usr/share/zabbix/locale">
        Require all denied
        <files *.php>
            Require all denied
        </files>
    </Directory>

    <Directory "/usr/share/zabbix/vendor">
        Require all denied
        <files *.php>
            Require all denied
        </files>
    </Directory>
</VirtualHost>
