Full PHP development environment with Docker



Complete solution

Development tools

Environment composition

This environment provies the following tools to develop in PHP :



  • MongoExpress : Manage Mongo database instances
  • PHPMyAdmin : Manage Mongo database instances
  • MailDev : SMTP Server + Web Interface for viewing and testing emails during development
  • Composer : Dependency Manager for PHP


Two system dependencies are required :

  • Docker
  • Docker Compose


$ git clone git@github.com:vfalies/EnvDev.git


To start the environment, type the following command :

$ docker-compose up


You can modify .env file to manage path and port of the application and tools. The follwing paths and ports can be configured :

Description Variable name Default Possible values
HTTP port WEB_PORT 80 any
MailDev port MAILDEV_PORT 1080 any
PHPMyAdmin or MongoExpress port DBADMIN_PORT 9090 any
Projects Path PROJECTS_PATH ./projects` any
PHP version PHP_VERSION 7.2 any
Database type DB mysql mysql, mongodb
Web server type WEB_SERVER nginx nginx, apache
Cache server type CACHE_SERVER redis redis, memcached
Cache server port CACHE_PORT 6380 any

If you access to the url http://localhost a page summarizes all projets and propose access to PHPMyAdmin, MailDev and PHPInfo.

Open source

EnvDev is licensed under the MIT License and published through GitHub