enable xdebug on integration test imagae
This commit is contained in:
parent
04b0e69af6
commit
515f79fd9c
2 changed files with 14 additions and 1 deletions
11
Dockerfile
11
Dockerfile
|
@ -11,6 +11,17 @@ RUN apk update \
|
||||||
|
|
||||||
RUN docker-php-ext-install mysqli
|
RUN docker-php-ext-install mysqli
|
||||||
|
|
||||||
|
# Install Xdebug
|
||||||
|
RUN apk add --no-cache $PHPIZE_DEPS \
|
||||||
|
&& apk add --update linux-headers \
|
||||||
|
&& pecl install xdebug \
|
||||||
|
&& docker-php-ext-enable xdebug \
|
||||||
|
&& apk del --purge $PHPIZE_DEPS \
|
||||||
|
&& echo "xdebug.start_with_request=yes" >> /usr/local/etc/php/conf.d/docker-php-ext-xdebug.ini \
|
||||||
|
&& echo "xdebug.client_host=host.docker.internal" >> /usr/local/etc/php/conf.d/docker-php-ext-xdebug.ini \
|
||||||
|
&& echo "xdebug.mode=debug" >> /usr/local/etc/php/conf.d/docker-php-ext-xdebug.ini \
|
||||||
|
&& echo "xdebug.idekey=VSCODE" >> /usr/local/etc/php/conf.d/docker-php-ext-xdebug.ini
|
||||||
|
|
||||||
# Install Composer
|
# Install Composer
|
||||||
RUN EXPECTED_CHECKSUM=$(curl -s https://composer.github.io/installer.sig) \
|
RUN EXPECTED_CHECKSUM=$(curl -s https://composer.github.io/installer.sig) \
|
||||||
&& curl https://getcomposer.org/installer -o composer-setup.php \
|
&& curl https://getcomposer.org/installer -o composer-setup.php \
|
||||||
|
|
|
@ -29,3 +29,5 @@ services:
|
||||||
volumes:
|
volumes:
|
||||||
- .:/app
|
- .:/app
|
||||||
command: ["composer", "run-script", "test"]
|
command: ["composer", "run-script", "test"]
|
||||||
|
extra_hosts:
|
||||||
|
- "host.docker.internal:host-gateway"
|
||||||
|
|
Loading…
Reference in a new issue