eclipse pdtdebugging器configuration与docker容器为apache2,php7和xdebug托pipe在Ubuntu 16.04

我有一个安装使用apache2,php7,和xdebugdocker容器安装。 主机系统运行Ubuntu 16.04。 我已经在主机上安装了eclipse霓虹灯最新的下载,并尝试了许多不同的configuration,以获得xdebug工作。 我已经configuration容器来公开端口80和9000,并已configurationxdebug远程启动和端口9000的使用。 当我尝试configurationeclipsedebugging时,它告诉我,端口9000正在使用,不会连接。 我已经在网上search了任何有用的信息,但没有提供任何信息。

以下是Docker容器的Web服务器configuration代码:

FROM php:7.0.19-apache COPY config/php.ini /usr/local/etc/php/ RUN apt-get update && apt-get install -y \ libfreetype6-dev \ libjpeg62-turbo-dev \ libmcrypt-dev \ libpng12-dev \ git \ && docker-php-ext-install -j$(nproc) iconv mcrypt \ && docker-php-ext-configure gd --with-freetype-dir=/usr/include/ --with-jpeg-dir=/usr/include/ \ && docker-php-ext-install -j$(nproc) gd\ && docker-php-ext-install -j$(nproc) mysqli\ && pecl install xdebug-2.5.0 \ && docker-php-ext-enable xdebug # Installation of Composer RUN cd /usr/src && curl -sS http://getcomposer.org/installer | php RUN cd /usr/src && mv composer.phar /usr/bin/composer # Installation of tools with composer RUN composer global require --no-plugins --no-scripts phpdocumentor/phpdocumentor RUN composer global require --no-plugins --no-scripts squizlabs/php_codesniffer RUN composer global require --no-plugins --no-scripts phpunit/phpunit RUN composer global require --no-plugins --no-scripts phpunit/dbunit RUN composer global require --no-plugins --no-scripts phploc/phploc RUN composer global require --no-plugins --no-scripts phpmd/phpmd RUN composer global require --no-plugins --no-scripts simpletest/simpletest ENV PATH /root/.composer/vendor/bin:$PATH 

这里是xdebug的php.ini设置:

 zend_extension=/usr/local/lib/php/extensions/no-debug-non-zts-20151012/xdebug.so xdebug.profiler_enable_trigger = 1 xdebug.trace_enable_trigger = 1 xdebug.remote_enable=1 xdebug.remote_host=172.18.0.1 xdebug.remote_port=9000 xdebug.remote_handler="dbgp" 

这里是docker-compose代码,它公开了数据库容器中的端口和链接:

 version: '2' services: webserver: build: ./docker/webserver ports: - "80:80" - "443:443" - "9000:9000" volumes: - /home/www:/var/www links: - db db: image: mysql:5.5 ports: - "3306:3306" volumes: - ./db:/var/lib/mysql environment: - MYSQL_ROOT_PASSWORD=mypassword myadmin: image: phpmyadmin/phpmyadmin:4.6 ports: - "8080:80" links: - db environment: MYSQL_ROOT_PASSWORD: mypassword 

我会很感激得到debugging器的任何帮助,以便我可以使用它来设置断点。 我已经安装了firefox的eeasiestxdebug扩展,并打算使用它作为debugging的控件,当我得到一切工作。

提前致谢。