Skip to content

Commit

Permalink
Add Xdebug/Docker support
Browse files Browse the repository at this point in the history
  • Loading branch information
barryo committed Jan 29, 2018
1 parent ef2db45 commit 073ca1b
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
3 changes: 3 additions & 0 deletions .env.docker
Original file line number Diff line number Diff line change
Expand Up @@ -136,3 +136,6 @@ IXP_FE_FRONTEND_DISABLED_LOOKING_GLASS=false

IXP_FE_BETA_CORE_BUNDLES=true

# For PHP xdebug, put in the IP address of your host
# DOCKER_XDEBUG_CONFIG_REMOTE_HOST=192.0.2.67

2 changes: 2 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,8 @@ services:
www:
build:
context: tools/docker/containers/www
environment:
XDEBUG_CONFIG: remote_host=${DOCKER_XDEBUG_CONFIG_REMOTE_HOST}
image: ixpmanager/www:dev
ports:
- 8880:80
Expand Down
7 changes: 3 additions & 4 deletions tools/docker/containers/www/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,15 @@ RUN apt-get -y update && \
libyaml-dev git mysql-client npm nodejs-legacy joe wget \
iputils-ping dnsutils && \
apt-get -y autoremove --purge && \
apt-get -y autoremove --purge && \
apt-get -y clean && \
rm -rf /var/lib/apt/lists/* && \
rm -rf /tmp/*
RUN docker-php-source extract && \
docker-php-ext-install -j$(nproc) mcrypt snmp intl bcmath gd gettext zip pdo_mysql && \
pecl install ds rrd && \
pecl install ds rrd xdebug && \
printf "\n" | pecl install yaml && \
echo "extension=ds.so\nextension=rrd.so\nextension=yaml.so\n" >/usr/local/etc/php/conf.d/local-ixpmanager.ini && \
echo "[xdebug]\nzend_extension=$(find /usr/local/lib/php/extensions/ -name xdebug.so)\n" >/usr/local/etc/php/conf.d/local-ixpmanager-xdebug.ini && \
echo "xdebug.remote_enable=1\nxdebug.remote_port=9001\nxdebug.remote_autostart=0\nxdebug.idekey=PHPSTORM\n" >>/usr/local/etc/php/conf.d/local-ixpmanager-xdebug.ini && \
docker-php-source delete && \
curl -so /usr/local/bin/composer.phar https://getcomposer.org/download/1.6.2/composer.phar && \
chmod a+x /usr/local/bin/composer.phar
Expand Down

0 comments on commit 073ca1b

Please sign in to comment.