Topic: PHP Dual Stack Problem

Hello,

I am experiencing a challenge with PHP Dual Stack installations and require assistance. Specifically, my issue pertains to the installation of PHP 8.0 which creates the file 'conf/php.conf,' and legacy PHP 7.4 (or any other version) which creates 'conf.d/php74-php.conf.'

Both files contain the PHP Handler, with the following configurations:

    PHP 8.0: SetHandler "proxy:unix:/run/php-fpm/w w w.sock|fcgi://localhost"
    PHP 7.4: SetHandler "proxy:unix:/var/opt/remi/php74/run/php-fpm/w w w.sock|fcgi://localhost"
(ignore spaces with w w w - board won't let me write it without because of "too many links" ...)

Consequently, the PHP version loaded last becomes the default PHP version for the server, used for all Apache VHosts without a fixed defined "Set Handler." However, I would like to configure the first loaded PHP 8.0 as the default and only use PHP 7.4 where it is defined within Apache VHost.

Do you have any suggestions on how to resolve this issue?

Thank you,
Andy

Re: PHP Dual Stack Problem

> Consequently, the PHP version loaded last becomes the default PHP version for the server

Expected behavior  (in short, single version work out-of-the-box, multiple versions "always" require configuration changes)

> Do you have any suggestions on how to resolve this issue?

Comment out the content of php74-php.conf (but keep the file, else it will be restore on update)

This is exactly what I use on this server (8.0 for everything, 7.4 only for the forum)

Laptop:  Fedora 38 + rpmfusion + remi (SCL only)
x86_64 builder: Fedora 39 + rpmfusion + remi-test
aarch64 builder: RHEL 9 with EPEL
Hosting Server: CentOS 8 Stream with EPEL, rpmfusion, remi

Re: PHP Dual Stack Problem

Hey Remi,
thx for your fast reply! ;-)
Guess my failure was that I removed the conf file ... so I will recreate it empty.
So in future if there would be changes on the .conf file when updating it would be created with .conf.rpmnew, right?
thx, bye from Austria
Andy

Re: PHP Dual Stack Problem

> So in future if there would be changes on the .conf file when updating it would be created with .conf.rpmnew, right?

Yes (designed behavior for all "config" files)



P.S. The .rpmnew is created "only" if there are changes in the packaged config file
which will never occur in a minor update

Laptop:  Fedora 38 + rpmfusion + remi (SCL only)
x86_64 builder: Fedora 39 + rpmfusion + remi-test
aarch64 builder: RHEL 9 with EPEL
Hosting Server: CentOS 8 Stream with EPEL, rpmfusion, remi