Forge: Multiple PHP Installations

James Brooks
James Brooks

Today we're pleased to announce that Laravel Forge now supports managing multiple versions of PHP on a single server! This new feature is available to all Forge subscription plans.

Once installed, you may assign a specific PHP version to any site on your server. You may even run different sites on different PHP versions - all within the same server! In addition, you may choose your preferred PHP version when creating new queue workers.

In addition, you may determine which PHP version is the "default" version on the CLI. The default CLI PHP version is the version of PHP that will be executed when running the "php" command on the command line. Other versions may be accessed using their version numbers:

php7.3 script.php

You can also use the new FORGE_PHP and FORGE_PHP_FPM environment variables within your deployment scripts to automatically use the selected default binary and FPM process names:

We have updated the Forge API to reflect the new PHP changes.

For more information, please consult the Forge documentation.

James Brooks
James Brooks

Latest Stories

Here’s what we've been up to recently.

Request a code sample

Certified Quality. Great Prices

We use cookies to improve your experience and to help us understand how you use our site. By using this site, you accept our use of cookies. Cookie Infox