sajad torkamani

List config files used by the PHP CLI

Run from the command-line:

php --ini

Example output:

Configuration File (php.ini) Path: /etc/php/8.0/cli
Loaded Configuration File:         /etc/php/8.0/cli/php.ini
Scan for additional .ini files in: /etc/php/8.0/cli/conf.d
Additional .ini files parsed:      /etc/php/8.0/cli/conf.d/10-mysqlnd.ini,

List config files used by the web server process (e.g., PHP-FPM)

Call phpinfo() in a .php file that’s served on a web page and look for the following values:

List configuration files loaded by the PHP web server process.