I've been trying to set up xDebug with Vagrant and PhpStorm 8. It is supposed to simplify the process a lot, but for me it was exactly the opposite. In PhpStorm 8 we can set up Interpreters on a Vagrant maching. This is my setup.
The connection is set up - no problem here, the PHP binary is also found and responding. However, you can see the message Debugger: Not installed
.
PhpStorm does not detect xDebug because it is looking at the CLI config file (/etc/php5/cli/php.ini
) instead of /etc/php5/apache2/php.ini
, where debugger is installed.
I find it rather strange that it would look for the Cli config while it is usually a different config file for web servers.
How can I make PhpStorm detect the debugger? Should I copy all configuration from /etc/php5/apache2/php.ini
to /etc/php5/cli/php.ini
(these are substantially different in my remote environment and I want to keep them different). Has anyone encountered the same prblem?
Well, PS is supposed to look at the Cli config, because it executes the PHP binary other SSH. I have a separate ini file for each PHP Module and I use the same in Web Server and Cli configuration. In my php5/cli/conf.d
folder I have symlinks pointing to the modules in my mods-available
folder.
|-- cli
| |-- conf.d
| | |-- 05-opcache.ini -> ../../mods-available/opcache.ini
| | |-- 10-mysqlnd.ini -> ../../mods-available/mysqlnd.ini
| | |-- 10-pdo.ini -> ../../mods-available/pdo.ini
| -- php.ini
|-- mods-available
|-- curl.ini
|-- gearman.ini
|-- imagick.ini
|-- intl.ini
|-- mcrypt.ini
|-- mongo.ini
|-- mysqli.ini
|-- mysql.ini
|-- mysqlnd.ini
|-- opcache.ini
|-- pdo.ini
|-- pdo_mysql.ini
|-- readline.ini