BUG : Confusion between "fpm-fcgi" and htaccess

Hello,
Many people are annoyed by the following upon installation:
It seems that Matomo considers that if it is served by “fpm-fcgi”, the .htaccess are not taken into account by Apache and therefore they are not generated ; and instead, Matomo asks us for a manual configuration of the ProxyPass. Is this correct?
If yes, this method may be wrong and misleads us: if the configuration of Apache is correctly done, Apache will interpret the .htaccess, whether we use fpm or something else… This is the case with Plesk ; here is an example of Apache configuration:

<Directory /var/www/...>
  <IfModule mod_proxy_fcgi.c>
    <Files ~ (\.php$)>
      SetHandler proxy:unix:/var/www/.../php-fpm.sock|fcgi://...

And .htaccess are interpreted.

You should rather generate .htaccess when Matomo is served by Apache and not prevent this generation when “php_sapi_name” returns “fpm-fcgi”.

Now I don’t know what to do :
Create .htaccess in Matomo that may disappear if it decide they’re not useful because I use php-fpm.
Or change the Apache vhost configuration manually and thus relocate the response to Matomo’s needs to the Apache level.

I reinstalled Matomo and it works ; there was an update to 4.14.1, dunno if it fix my issues but .htaccess are installed. Meanwhile, you may rework the error message at install to avoid confusion.

1 Like