PHP versions and settings
Coduva runs multiple PHP versions side by side. A client site can stay on PHP 8.3 while a new Laravel project runs on PHP 8.5, at the same time and without interfering with each other.
Everything related to PHP is on the PHP & Node screen (in the Development group of the left menu). Clicking the PHP version in the status bar at the bottom also opens this screen.
Supported versions
| Version | Status |
|---|---|
| PHP 8.4 | Default; included in the first installation |
| PHP 8.3 | Optional |
| PHP 8.5 | Optional |
Coduva supports PHP 8.0 and later. If an older version is found in the component folder, it is marked as Not supported. For exact version numbers, see the Components page.
Installing and removing versions
In the PHP versions table on the PHP & Node screen, each version shows its Status (Default, Installed, Not installed or Not supported) and Used by. The download size is shown next to versions that are not installed.
- To install: click Install on the version's row. The download percentage appears on the row. The file is downloaded from its official source and verified with SHA-256.
- To make it the default: click Make default. All projects that have not selected their own version use this version.
- To remove: click Remove and confirm "Remove PHP 8.3? Its files will be deleted."
Versions that cannot be removed
The default version cannot be removed; first make another version the default. The Remove button is disabled for a version used by a project: first move the projects listed in the Used by column to another version. If the version's FastCGI pool is running, you are asked to stop the web server first.
PHP version per project
- On the project screen, open the General tab.
- Choose a version from the PHP version list. The Default (8.4) option links the project to the default version; if the default changes, the project changes with it.
The change takes effect immediately. Coduva reloads Nginx without interruption; you do not need to stop any services. The project's terminal, Composer, WP-CLI and Artisan commands also run with this version.
You can also choose a PHP version when you create a new project or add a folder.
How it works
Each PHP version has its own FastCGI pool: 4 php-cgi.exe processes, in a port block specific to that version. For example, PHP 8.4 uses ports 9840–9843 by default. Nginx forwards each project's requests to the pool of that project's version.
- If a PHP process crashes, Coduva's watchdog restarts it within a few seconds.
- If the pool's ports are occupied, Coduva selects an empty block in the 9800–9999 range and records it.
- The Nginx card on the Control center shows the status of each pool:
PHP 8.4 · 4/4 FastCGI processes.
For the port layout, see the Ports page.
php.ini settings
The PHP settings card shows the most frequently changed settings as a form:
| Field | php.ini equivalent | Example |
|---|---|---|
| Memory limit | memory_limit | 512M, 1G |
| Upload size | upload_max_filesize | 64M |
| Execution time, seconds | max_execution_time | 120 (1–3600) |
| Time zone | date.timezone | Europe/Istanbul |
| Show errors on the page | display_errors | On / Off |
When you click Save, Coduva regenerates the php.ini files and restarts the running PHP processes with the new settings. Sizes must be written in the form 512M, 1G, or -1 for unlimited; an invalid time zone is not accepted.
Settings apply to all versions
The values in this form apply to all installed PHP versions. Per-version php.ini values cannot currently be set from the interface.
Extensions
The Extensions section below the PHP settings card lists the extensions available for the PHP version shown on the screen (the default version). Checked extensions are loaded. After you turn an extension on or off, click the card's Save button; the selection applies to all PHP versions that include that extension.
Coduva only writes extensions that actually exist in that PHP version's folder, which prevents PHP from failing to start because of a missing DLL.
If you do not know which extension you need, the error in the log will tell you:
| Error | Extension |
|---|---|
Call to undefined function imagecreate() | gd |
Call to undefined function mb_strlen() | mbstring |
PHP Startup: Unable to load dynamic library | A dependency of the extension is missing; usually the Visual C++ runtime |
Coduva recognizes these patterns in the logs itself and explains them on the Diagnostics screen. See the Diagnostics rules page.
PHP on the command line
In the project terminal, the php command runs the project's version and uses the php.ini file generated by Coduva (via the PHPRC environment variable):
php -v
php --ini
php -mSee Terminal, Composer and Node.js.
Xdebug
Turning Xdebug on and off per project, and an editor configuration helper, are planned for v1.x.
Next step: Local HTTPS.