The Devilbox is a modern and highly customisable dockerized PHP stack supporting full LAMP and MEAN and running on all major platforms. The main goal is to easily switch and combine any version required for local development. It supports an unlimited number of projects for which vhosts, SSL certificates and DNS records are created automatically. Email catch-all and popular development tools will be at your service as well. Configuration is not necessary, as everything is already pre-setup.
Furthermore, the Devilbox provides an identical and reproducable development environment for different host operating systems.
The Devilbox ships the following pre-configured Docker container in any available version.
|Web server||SQL||NoSQL||Queue & Search||Misc|
Documentation: Available Container
Find documentation and help here
|Linux and MacOS||Windows|
# Get the Devilbox $ git clone https://github.com/cytopia/devilbox
# Create docker-compose environment file $ cd devilbox $ cp env-example .env
# Edit your configuration $ vim .env
# Start all container $ docker-compose up
4. Open a terminal on Windows and type:
# Start all container C:\devilbox> docker-compose up
The above will start all containers, you can however also just start the containers you actually need. This is achieved by simply specifying them in the docker-compose command.
$ docker-compose up httpd php mysql redis
Documentation: Start only some container
Run different versions
Every single attachable container comes with many different versions. In order to select the desired version for a container, simply edit the
.env file and uncomment the version of choice. Any combination is possible.
 PHP 5.2 is available to use, but it is not officially supported. The Devilbox intranet does not work with this version as PHP 5.2 does not support namespaces. Furthermore PHP 5.2 does only work with Apache 2.4, Nginx stable and Nginx mainline. It does not work with Apache 2.2. Use at your own risk.
Documentation: Change container versions
Additionally to the default stack, there are a variety of other services that can be easily enabled and started.
Documentation: Enable custom container
Enter the container
You can also work directly inside the php container. Simply use the bundled scripts
shell.bat for Windows).
PS1 will automatically be populated with current chosen php version.
Navigate the the Devilbox directory and type the below listed command:
|Linux and MacOS||Windows|
host> ./shell.sh firstname.lastname@example.org in /shared/httpd $
C:\devilbox> shell.bat email@example.com in /shared/httpd $
Your projects can be found in
/shared/httpd. DNS records are automatically available inside the php container. Also every other service will be available on
127.0.0.1 inside the php container (tricky socat port-forwarding).
Quick Video intro
The Devilbox has everything setup for you. The only thing you will have to install is Docker and Docker Compose. Virtual hosts and DNS entries will be created automatically, just by adding new project folders.
Documentation: Devilbox Prerequisites
|New virtual hosts are created automatically and instantly whenever you add a project directory. This is done internally via vhost-gen and watcherd.|
|Valid SSL certificates for HTTPS are automatically created for each vhost and signed by the Devilbox CA.|
|Run as many projects as you need with a single instance of the Devilbox.|
|You can overwrite and customise the default applied vhost configuration for every single vhost.|
|Choose whatever development domain you desire:
|An integraded BIND server is able to create DNS entries automatically for your chosen domains.|
|Overwrite any setting for PHP.|
|Load custom PHP modules on the fly.|
|All outgoing emails are catched and will be presented in the included intranet.|
|Projects and configuration options are validated and marked in the intranet.|
|Xdebug and a full blown PHP-FPM server is ready to serve.|
|See Documentation for all available features.|
The following batteries are available in the Devilbox intranet by default:
|Adminer||phpMyAdmin||phpRedMin||OpCache GUI||Mail viewer|
Documentation: Devilbox Intranet
The following tools will assist you on creating new projects easily as well as helping you check your code against guidelines.
|A set of tools for static code analysis:
Well-known and popular tools will be at your service as well:
Documentation: Available Tools
Available PHP Modules
The Devilbox is a development stack, so it is made sure that a lot of PHP modules are available out of the box in order to work with many different frameworks.
amqp, apcu, bcmath, bz2, calendar, Core, ctype, curl, date, dba, dom, enchant, exif, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, igbinary, imagick, imap, interbase, intl, json, ldap, libxml, mbstring, mcrypt, memcache, memcached, mongodb, msgpack, mysqli, mysqlnd, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, pdo_pgsql, pdo_sqlite, pgsql, phalcon, Phar, posix, pspell, rdkafka, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, sodium, SPL, sqlite3, standard, swoole, sysvmsg, sysvsem, sysvshm, tidy, tokenizer, uploadprogress, wddx, xdebug, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib
PHP modules can be enabled or disabled on demand to reflect the state of your target environment.
Documentation: Enable/disable PHP modules
Custom PHP Modules
You can also copy any custom modules into
mod/(php-fpm)-<VERSION> and add a custom
*.ini file to load them.
As far as tested there are no limitations and you can use any Framework or CMS just as you would on your live environment. Below are a few examples of extensively tested Frameworks and CMS:
Setup CakePHP | Setup CodeIgniter | Setup CraftCMS | Setup Drupal | Setup Joomla | Setup Laravel | Setup Magento | Setup PhalconPHP | Setup PhotonCMS | Setup PrestaShop | Setup Shopware | Setup Symfony | Setup Typo3 | Setup Wordpress | Setup Yii | Setup Zend
The Devilbox comes with a pre-configured intranet on
https://localhost. This can be explicitly disabled or password-protected. The intranet will not only show you, the chosen configuration, but also validate the status of the current configuration, such as if DNS records exists (on host and container), are directories properly set-up. Additionally it provides external tools to let you interact with databases and emails.
- Virtual Host overview (validates directories and DNS)
- Database overview (MySQL, PgSQL, Redis, Memcache, ...)
- Email overview
- Info pages (Httpd, MySQL, PgSQL, Redis, Memcache, ...)
Documentation: Devilbox Intranet
A few examples of how the built-in intranet looks like.
The Devilbox is still a young project with a long roadmap of features to come. Features are decided by you - the community, so any kind of contribution is welcome.
To increase visibility and bug-free operation:
- Star this project
- Open up issues for bugs and feature requests
- Clone this project and submit fixes or features
Logos and banners can be found at devilbox/artwork. Feel free to use or modify them by the terms of their license.
Copyright (c) 2016 cytopia