How to activate Xdebug in VVV
Running xdebug_on inside Vagrant:
- Copy and paste output from phpinfo() to Xdebug wizard, analyze and check step about editing the php.ini file (step 9 in my case).
- Check if
/usr/lib/php/*/xdebug.sois present in the VM (it should be):
$ ls /usr/lib/php/20170718/xdebug.so
- Update
/etc/php/*/fpm/php.iniinside the Vagrant VM according to instructions from the Xdebug wizard website.
$ sudo tee -a /etc/php/7.2/fpm/php.ini >/dev/null <<'EOF'
[xdebug]
zend_extension = /usr/lib/php/20170718/xdebug.so
EOF
- Restart php service
$ sudo service php7.2-fpm restart
- Check phpinfo()–it should contain a new section for Xdebug
