Drupal-Dev Tweet

Attachable development environment for Drupal sites with tools included

Composer-based Drupal 8 project scaffolding with code linting, tests and automated builds (CI) integration.

Click here to see template for Drupal 8 project CircleCI Drupal 8

Click here to see template for Drupal 7 project CircleCI Drupal 7


Understanding Drupal-Dev

Drupal-Dev is a set of templates as well as an “attachable” development environment. It can be used as a scaffolding for Drupal projects or as a reference for custom configurations. Drupal-Dev has own automated tests that guarantees stability and easy maintenance.

Despite being a template, Drupal-Dev is “attachable” to new and existing projects: most of templates do not need to be changed and only a handful of files required by Drupal-Dev to exist in your project - the rest of the files will be downloaded each time Drupal-Dev needs to be “attached” to an environment.

Drupal-Dev supports both database-driven development and fresh install for every build. Database-driven development is when the existing production database is used for every build (useful for product development), while fresh install is when the site is installed from the scratch during every build (useful for module or profile development).

What is the problem that Drupal-Dev is trying to solve?

Increase the quality of the produced Drupal websites with minimum setup effort and knowledge.

Why is this problem important?

High quality Drupal websites are stable, secure, faster and safer to change.

But developers do not always have the time or skills to setup the tools required to produce and maintain high-quality Drupal websites.

How does Drupal-Dev solve it?

Quick install of best practices Drupal configuration on Docker stack using a single command lowers entry barrier, while unification of the developer’s experience improves development speed across projects.

Who is it for?

How does it work?

What if I don’t like the defaults this project provides?

Since Drupal-Dev is a template, it can be forked and adjusted to your needs. The installer script will continue to work with your fork, provided that you adjust several environment variables.

In other words - you will have your own development templates for your projects the way you want it!

Why is Drupal-Dev awesome?

Main concepts behind Drupal-Dev

What areas does Drupal-Dev cover?

Area Feature Why it is important
Versions Drupal 7 support Drupal 7 is still widely used
  Drupal 8 support Drupal 8 is current version
  Separate branches for each Drupal version Handling both Drupal versions in the same repository allows to easily re-use some commits across branches.
Composer-based configuration Pure composer configuration Website is assembled using industry-standard tools such as Composer
  Uses drupal-scaffold Industry-standard composer package to scaffold some of Drupal files
  Scripts to create required settings and files with environment variables support Required files and directories created automatically.Environment variables override support allows to provide override values without the need to change scripts. Useful for per-environment overrides.
  Settings file with multi-environment support Per-environment variables allow to easily target specific settings to specific environments without too much mess
  Best-practices development modules Having the same development modules on each website helps to reduce development time.
Custom module scaffolding Mechanism to organise contributed module-related hook implementations into standalone files Helps avoid large files with all hook implementation, which leads to a simple maintenance.
Custom theme scaffolding Based on Bario (Bootstrap 4) Bootstrap 4 is the latest version of the most popular frontend framework and Bario is a Drupal theme that supports Bootstrap 4.
  Grunt + SASS/SCSS + globbing + Livereload Grunt configuration defines multiple build steps to work with frontend in Drupal.
Livereload allows to automatically refresh the page once there are changes to styles or scripts.
Patches management Based on composer-patches Support for custom (per-project) and contributed patches is simply essential for any project.
Local development environment    
Docker Using stable Amazee images Amazee images are stable - they are covered by tests and are used in many production environments.
  Pure Docker configuration Pure Docker configuration allows anyone with Docker knowledge to alter configuration as required.
  Custom application support As a result of using Docker, it is possible to install any application, provided that it can be ran in container
  Multi-application support As a result of using Docker, it is possible to have multiple applications (not only Drupal) in one stack. For example, decoupled Drupal and Frontend VueJS application.
  Using Pygmy Adds support for additional Docker tools as well as Mailhog (to test emails)
Unified Development Experience (DX) Ahoy commands to abstract complex tasks into set of workflow commands To improve development speed and unify development tasks across projects
  Single command project build Project must be built in the same way on any environment and a single command always guarantees that it will be done in the same predictable way.Improve development speed and easy maintenance.
  Database sanitization support Remove all personal data from the database before working on it.
Configuration Configuration provided through a (file)[.env] with reasonable defaults To cover majority of the project without the need to change any scripts
Code linting    
PHP Drupal PHP coding standards To increase code quality and lower technical debt
  PHP Version compatibility To avoid language constructs that may not be supported by a certain version of the language
JavaScript Drupal JS coding standards To increase code quality and lower technical debt
SASS/SCSS   To increase code quality and lower technical debt
PHPUnit* Configuration + examples Enables unit-testing capability to improve code quality and stability
Behat Configuration + examples Enables integration-testing capability using fast tests to improve code quality and stability
  Browser testing Enables integration-testing capability with JavaScript support to improve code quality and stability
Automated builds    
CI template Build + Test + Deploy Standard workflow for automated builds
  Conditional Deploy Supports conditional deployments based on tags and branches to allow selective deployments
  Parallel builds to speedup pipeline Running jobs in parallel may significantly lower the build time for large projects
  Cached database support Reduce build times by using daily cached database
  Identical environment as local and production While running on a 3rd party provider, CI uses hosting stack identical to the local and production in order to identify any problems at early stages.CI also acts as a 'shadow' developer by running exactly the same commands as what a developer would run locally.
Readme files Generic project information Helps to find relevant project information in one place
  Local environment setup Helps to lower project onboarding time
  List of available commands Helps to lower project onboarding time
  Build badges Shows current build status
  FAQs Helps to lower project onboarding time
  Deployment information Helps to find relevant deployment information in one place
GitHub management Pull request template Helps to improve team collaboration and reduce the time for pull request management
  Pre-defined issue and pull request labels* Helps to improve team collaboration and reduce the time for pull request management
Acquia Production database from Acquia Using production database for development and automated builds (CI) requires database dump from Acquia
  Deploy code to Acquia Deploying to Acquia requires packaging Composer-based project into artefact before pushing
  Deployment hooks Standardised deployment hooks guarantee that every deployment is reproducible
Lagoon Deployment configuration Lagoon configuration is required to perform deployments
  Production database from Lagoon Using production database for development and automated builds (CI) requires database dump from Lagoon
dependencies.io Automated pull request submissions for automated updates. Automated dependencies updates allow to keep the project up to date by automatically creating pull requests with updated dependencies on a daily basis
Diffy (Visual Regression)* Automated visual regression comparison for each deployment Visual regression for each deployment is useful to make sure that only required changes were applied with specific code change and that the rest of the site has not changed
Maintenance (of Drupal-Dev)    
Install and upgrade Follows SemVer model for releases Projects may refer to a specific version of Drupal-Dev, which sets expectations about what tools and configuration is available
  Managed as an agile project New features and defects can be addressed in a shorter development cycle.GitHub issues organised on the Kanban board provide clear visibility for future releases
  One-liner install script with optional wizard Minimises the time to try Drupal-Dev.Provides centralised point for installation into new and existing projects, as well as updates.
Stability Test suite for all provided commands Guarantees that commands will work
  Own CI to run test suite Pull requests and releases are stable
  Daily Drupal and NPM updates Composer (including Drupal) and NPM packages are always using the latest versions.
Documentation Contribution guide* Engages community to contribute back
  Pull request template Helps to improve community collaboration and reduce the time for pull request management.

* Denotes features planned for 1.4 release


Why Ahoy?

Why not Lando, DDEV, Docksal?

Why use amazeeio containers?

Why CircleCI?

Why dependencies.io?


Integrated Experts provides paid support for Drupal-Dev:

Contact us at support@integratedexperts.com

Useful projects