Supported PHP versions: 7.x and 5.6.x.
1. Install docker for Linux, Mac OS X or Windows. For Mac and Windows make sure you're installing native docker app version 1.12, not docker toolbox.
For Linux install docker compose
2. Copy .env.default to .env
2.1. Set COMPOSE_PROJECT_NAME, PROFILE_NAME, THEME_NAME variables with values you need
2.2. Change IMAGE_PHP in case you need another one
3. Copy docker-compose.override.yml.default to docker-compose.override.yml
This file is used to overwrite container settings and/or add your own. See https://docs.docker.com/compose/extends/#/understanding-multiple-compose-files for details.
4. Prepare your new Drupal site
4.1. Check composer.json contents
4.1.1. Use make exec
& composer require
to add required extensions & libraries
4.2. Optionally add custom theme to web/themes/
4.2.1. Uncomment make -s front
line to allow build of the theme
4.3. Optionally add you custom modules to web/modules/custom
5. Run make
make
- Install project.make clean
- totally remove project build folder, docker containers and network.make reinstall
- rebuild & reinstall site.make si
- reinstall site.make info
- Show project services IP addresses.make chown
- Change permissions inside container. Use it in case you can not access files in build. folder from your machine.make exec
- docker exec into php container.make exec0
- docker exec into php container as root.make devel
- Devel + kint setup, and config for Twig debug mode.make phpcs
- check codebase withphpcs
sniffers to make sure it conforms https://www.drupal.org/docs/develop/standards.make phpcbf
- fix codebase according to Drupal standards https://www.drupal.org/docs/develop/standards.make cex
- executes config export toconfig/sync
directory.make cim
- executes config import fromconfig/sync
directory.make front
- builds frontend tasksmake lint
- runs frontend linters