drupal-vm icon indicating copy to clipboard operation
drupal-vm copied to clipboard

Does DrupalVM work with Xdebug v3 installed on host?

Open emb03 opened this issue 3 years ago • 3 comments
trafficstars

Issue Type

  • Bug Report / Support Request

Your Environment

Vagrant 2.2.19
VirtualBox 2.1.26

Your OS

  • macOS (Big Sur)

Full console output

Summary

Xdebug does not work at all. Is there a way to make DrupalVM upgrade to Xdebug v3 or do I have to downgrade my version of xdebug on my host machine?

emb03 avatar Jan 10 '22 17:01 emb03

Yes, have a way to upgrade but you will need to create a patch for that.

in drupal-vm/provisioning/roles/geerlingguy.php-xdebug/templates/xdebug.ini.j2 you will need to update the fields that you will use according to the xdebug upgrading documentation (https://xdebug.org/docs/upgrade_guide). After that in your box config file you will fill with the variables that you updated in xdebug.ini.j2

D41137171 avatar Feb 03 '22 22:02 D41137171

I managed to get xdebug 3.1.0 working with Drupal-vm & Phpstorm by adding these lines to the xdebug.ini.j2 file, as Guilherme Barbosa suggests:

xdebug.mode={{ php_xdebug_mode }}
xdebug.client_host={{ php_xdebug_client_host }}
xdebug.client_port={{ php_xdebug_client_port }}

Then in config.yml of drupal-vm, append these lines to your other xdebug settings:

php_xdebug_version: 3.1.0
php_xdebug_mode: debug
php_xdebug_client_host: 192.168.99.1
php_xdebug_client_port: 9003

mnovbaalen avatar Apr 12 '22 13:04 mnovbaalen

This issue has been marked 'stale' due to lack of recent activity. If there is no further activity, the issue will be closed in another 30 days. Thank you for your contribution!

Please read this blog post to see the reasons why I mark issues as stale.

stale[bot] avatar Jul 12 '22 03:07 stale[bot]

This issue has been closed due to inactivity. If you feel this is in error, please reopen the issue or file a new issue with the relevant details.

stale[bot] avatar Aug 12 '22 01:08 stale[bot]