Xdebug
To enable Xdebug, set DEV_ENABLE_XDEBUG: true in your compose.yaml. You can connect to the Xdebug server on port 9003.
yaml
services:
php:
image: ghcr.io/jonaaix/laravel-aio:1.3-php8.5-fpm
environment:
ENV_DEV: true
DEV_ENABLE_XDEBUG: trueWARNING
Xdebug only activates when ENV_DEV: true. In production mode, Xdebug is forcibly disabled even if DEV_ENABLE_XDEBUG: true is set.
PHPStorm Configuration
- Go to
Settings→PHP→Debug - External Connections: DISABLE
Break at first line in PHP scripts - Xdebug: DISABLE
Force break at first line when no path mapping specified - Xdebug: DISABLE
Force break at first line when a script is outside the project - Go to
Settings→PHP→Servers - Add a new server with name
laravelaccording to the compose configuration:- Name:
laravel - Host:
localhost - Port:
8000 - Debugger:
Xdebug - ENABLE:
Use path mappings:path/to/your/project→/app
- Name:
- Install the browser extension and enable it in the correct tab.
- Activate the telephone icon in PHPStorm to listen for incoming connections.