Skip to content

Commit ed9ce4b

Browse files
committed
Allow overriding XDEBUG_MODE through env var and set output dir
1 parent 1e5425e commit ed9ce4b

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

docker-compose.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@ services:
44
container_name: xdebug-php
55
extra_hosts:
66
- "host.docker.internal:host-gateway"
7+
environment:
8+
XDEBUG_MODE: "${XDEBUG_MODE}"
79
build:
810
context: .
911
dockerfile: Dockerfile
@@ -27,3 +29,6 @@ services:
2729
- type: "bind"
2830
source: "${PWD}/data"
2931
target: "/var/www/data"
32+
- type: "bind"
33+
source: "/tmp/docker-xdebug"
34+
target: "/tmp/docker-xdebug"

docker/90-xdebug.ini

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,4 @@ xdebug.mode=develop,debug
33
xdebug.start_with_request=yes
44
xdebug.discover_client_host=0
55
xdebug.client_host=host.docker.internal
6+
xdebug.output_dir=/tmp/docker-xdebug

0 commit comments

Comments
 (0)