For some reason Xdebug is not connecting to the port that I have specified for it.
.ini file contents:
xdebug.mode=debug
xdebug.log=/var/log/xdebug/xdebug.log
xdebug.start_with_request=yes
xdebug.discover_client_host=1
xdebug.client_port=10000
I used to have my PhpStorm set to listen on port 9003, but changed it in an attempt to resolve the issue.
sudo lsof -i :9003
:
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
phpstorm 8680 lodewykduminy 71u IPv6 0x994c1e5e6b18981f 0t0 TCP *:9003 (LISTEN)
sudo lsof -i :10000
does not show anything listening on the port.
When navigating to a page that would cause a breakpoint to be hit, the following is logged:
[122] Log opened at 2022-01-19 00:46:24.792450
[122] [Step Debug] INFO: Checking remote connect back address.
[122] [Step Debug] INFO: Checking header 'HTTP_X_FORWARDED_FOR'.
[122] [Step Debug] INFO: Checking header 'REMOTE_ADDR'.
[122] [Step Debug] INFO: Client host discovered through HTTP header, connecting to 172.18.0.1:10000.
[122] [Step Debug] WARN: Creating socket for '172.18.0.1:10000', poll success, but error: Operation in progress (29).
[122] [Step Debug] WARN: Could not connect to client host discovered through HTTP headers, connecting to configured address/port: localhost:10000. :-|
[122] [Step Debug] WARN: Creating socket for 'localhost:10000', poll success, but error: Operation in progress (29).
[122] [Step Debug] WARN: Creating socket for 'localhost:10000', connect: Address not available.
[122] [Step Debug] ERR: Could not connect to debugging client. Tried: 172.18.0.1:10000 (from REMOTE_ADDR HTTP header), localhost:10000 (fallback through xdebug.client_host/xdebug.client_port) :-(
[122] [Step Debug] INFO: Checking remote connect back address.
[122] [Step Debug] INFO: Checking header 'HTTP_X_FORWARDED_FOR'.
[122] [Step Debug] INFO: Checking header 'REMOTE_ADDR'.
[122] [Step Debug] INFO: Client host discovered through HTTP header, connecting to 172.18.0.1:10000.
[122] [Step Debug] WARN: Creating socket for '172.18.0.1:10000', poll success, but error: Operation in progress (29).
[122] [Step Debug] WARN: Could not connect to client host discovered through HTTP headers, connecting to configured address/port: localhost:10000. :-|
[122] [Step Debug] WARN: Creating socket for 'localhost:10000', poll success, but error: Operation in progress (29).
[122] [Step Debug] WARN: Creating socket for 'localhost:10000', connect: Address not available.
[122] [Step Debug] ERR: Could not connect to debugging client. Tried: 172.18.0.1:10000 (from REMOTE_ADDR HTTP header), localhost:10000 (fallback through xdebug.client_host/xdebug.client_port) :-(
[122] [Step Debug] INFO: Checking remote connect back address.
[122] [Step Debug] INFO: Checking header 'HTTP_X_FORWARDED_FOR'.
[122] [Step Debug] INFO: Checking header 'REMOTE_ADDR'.
[122] [Step Debug] INFO: Client host discovered through HTTP header, connecting to 172.18.0.1:10000.
[122] [Step Debug] WARN: Creating socket for '172.18.0.1:10000', poll success, but error: Operation in progress (29).
[122] [Step Debug] WARN: Could not connect to client host discovered through HTTP headers, connecting to configured address/port: localhost:10000. :-|
[122] [Step Debug] WARN: Creating socket for 'localhost:10000', poll success, but error: Operation in progress (29).
[122] [Step Debug] WARN: Creating socket for 'localhost:10000', connect: Address not available.
[122] [Step Debug] ERR: Could not connect to debugging client. Tried: 172.18.0.1:10000 (from REMOTE_ADDR HTTP header), localhost:10000 (fallback through xdebug.client_host/xdebug.client_port) :-(
[122] Log closed at 2022-01-19 00:46:25.492820
Not sure what my next step should be.
(EDIT)
I've updated my docker setup to hold port 10000 in an attempt to resolve the issue:
Unfortunately the logs remain the same, with the following being show when I run sudo lsof -i :10000
:
Full xdebug_info()
: