Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docker xdebug directory is not configurable #129

Open
johnrom opened this issue Jun 18, 2020 · 0 comments
Open

Docker xdebug directory is not configurable #129

johnrom opened this issue Jun 18, 2020 · 0 comments

Comments

@johnrom
Copy link

johnrom commented Jun 18, 2020

I might be missing something, but it seems using this via docker doesn't allow me to set xdebug.profiler_out_dir because xdebug is not installed in jokkedk/webgrind. php.ini then never picks up the setting, which is never passed to webgrind, which means I cannot search a subdirectory like /tmp/cachegrind.

I have a WordPress site in Docker which has a mount to from /host/project/cachegrind/ to /tmp/cachegrind/ and I want this same directory mounted from /host/project/cachegrind/ to /tmp/cachegrind in webgrind. This is because otherwise, webgrinds own temporary files will be pushed back to the wordpress' /tmp/cachegrind/ folder. By using the subdirectory, the only files communicated will be the cachegrind files themselves.

I added the configuration by mounting /host/project/conf/webgrind.ini to /usr/local/etc/php/conf.d/webgrind.ini and can confirm that the ini is scanned via docker exec project_webgrind sh -c "php --ini", but docker exec project_webgrind sh -c "php -i | grep xdebug" returns no entries.

This variant I had no problem with used /tmp/xdebug by default which makes more sense to me, and also allowed modifications via environment variables. https://github.com/devgeniem/docker-webgrind

# This is the location where webgrind looks for the xdebug cachegrind files
XDEBUG_OUTPUT_DIR="/tmp/xdebug"

# Here webgrind then stores the temp files after analyzing the results
WEBGRIND_STORAGE_DIR="/tmp/webgrind"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant