![[Feature Request] Integrate possibility to have multiple PHP Versions for Apache](/nhc-explorer-cover.webp)
[Feature Request] Integrate possibility to have multiple PHP Versions for Apache
GitHub Issue
https://github.com/laravel/homestead/issues/892
In the Vagrant Homestead box, it's possible to have different php versions when using nginx as the web server. They offer also apache web server. But inside apache, it's not possible for now.
Indeed, they have the most dependencies included (PHP-FPM) to get multiple php version also for apache.
The basic handlers could be added to /etc/apache2/sites-enabled/000-default.conf like this:
<IfModule mod_fastcgi.c>
AddHandler php56-fcgi-www .php
Action php56-fcgi-www /php56-fcgi-www
Alias /php56-fcgi-www /usr/lib/cgi-bin/php56-fcgi-www
FastCgiExternalServer /usr/lib/cgi-bin/php56-fcgi-www -socket /run/php/php5.6-fpm.sock -pass-header Authorization
<Directory "/usr/lib/cgi-bin">
Require all granted
</Directory>
</IfModule>
<IfModule mod_fastcgi.c>
AddHandler php70-fcgi-www .php
Action php70-fcgi-www /php70-fcgi-www
Alias /php70-fcgi-www /usr/lib/cgi-bin/php70-fcgi-www
FastCgiExternalServer /usr/lib/cgi-bin/php70-fcgi-www -socket /run/php/php7.0-fpm.sock -pass-header Authorization
<Directory "/usr/lib/cgi-bin">
Require all granted
</Directory>
</IfModule>
<IfModule mod_fastcgi.c>
<FilesMatch ".+\.ph(p[345]?|t|tml)$">
SetHandler php70-fcgi-www
</FilesMatch>
</IfModule>
And the php version / the handler could be set to each vhost by adding this line to the vhost config:
SetHandler php70-fcgi-www
All they need to do is to install fastcgi:
apt-get install libapache2-mod-fastcgi
Source
https://www.thomaschristlieb.de/mehrere-php-versionen-auf-einem-linux-server-mit-php-fpm/
Leave [Feature Request] Integrate possibility to have multiple PHP Versions for Apache to:
Read more #utopian-io posts
Best Posts From derwunner
We have not curated any of derwunner's posts yet. But you can encourage our curation team to review posts by visiting them regularly and by referring other readers. Because we give priority to frequently read content.
More Posts From derwunner
- [Bugfix] Shopware new PayPal Plugin - Only replace necessary PayPal boxes with its content in document templates
- Projektidee - openSource Haushaltsbuch
- Bug / Feature: eSteem: System Notification does not lead to the action
- Bug: eSteem: Duplicated System Notification
- [Feature Request] Integrate possibility to have multiple PHP Versions for Apache
- cheap and solid gaming setup
- close the utopian leak
- Super Ball 8 Club verifaction post
- Added german translation
- Teenager died in an argument because people did nothing (english / deutsch)