Dockerized environment for PHP web development and Apache web server.
- Ability to set Apache document root through APACHE_DOC_ROOTenvironment variable. Default document root is/var/www/html
- Ability to set an Alias through APACHE_DOC_ROOT_ALIAS(no trailing slash!)
- Enabled Apache modules: rewrite
- Ability to set PHP date.timezonethroughPHP_TIMEZONEenvironment variable. Default timezone isEurope/Rome
- Enabled PHP extensions: gd, mcrypt, intl, mysql, mysqli, pdo_mysql, mbstring, soap, opcache, zip, xls
- Composer installed globally at /usr/local/bin/composer
- Xdebug PHP extension installed but not enabled
- Ability to enable xdebug PHP extension through XDEBUG_ENABLEenvironment variable which has to be set to1
- Ability to enable memprof PHP extension through MEMPROF_ENABLEenvironment variable which has to be set to1
- Ability to set xdebug.remote_enable setting through HOST_IPenvironment variable.
- GIT installed (required by Composer)
- sSMTP installed (as Mail Transfer Agent for PHP mail function)
- Ability to set sSMTP mailhub, AuthUser and AuthPass through SSMTP_MAILHUB,SSMTP_AUTH_USERandSSMTP_AUTH_PASSenvironment variables
- MySQL CLI Client, vim installed
Standalone usage example with host's current working directory as document root:
$ docker run -p 80:80 -v $(pwd):/var/www/html webgriffe/php-apache-base
Before starting the docker container: Set config variable XDEBUG_ENABLE to 1
Enable profiling by adding XDEBUG_PROFILE to the GET/POST Variables or as a cookie.