【发布时间】:2020-02-06 22:28:44
【问题描述】:
我正在与其他人共享本地服务器上进行开发。这个服务器有一个 Apache/PHP 实例,但它有多个“可用站点”(VirtualHost)供不同的人使用。
我想让 XDebug 正常工作,这样我们每个人都可以独立使用它。问题是如果我们启用 XDebug,例如,我的 IDE 连接到服务器并且我设置了一个断点,那么如果其他人正在浏览该页面,它就会停止,即使它在他/她自己的 VirtualHost 中。
关于如何正确设置的任何提示?
编辑:
忘了提到网络服务器是在 Docker 中运行的。 这是 XDebug 的当前配置:
# automatically start debugger on every request
xdebug.remote_enable=1
xdebug.remote_autostart=1
xdebug.remote_port=9000
# send all debug requests to 127.0.0.1
xdebug.remote_connect_back=0
xdebug.remote_host=host.docker.internal
#log all xdebug requests to see is it working correctly
xdebug.remote_log=/var/log/debug.log
谢谢。
【问题讨论】: