seregatte / drupal-composer-boilerplate
Composer template for Drupal 8 projects with docksal
Installs: 65
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 2
Forks: 0
Open Issues: 0
Type:project
Requires
- composer/installers: ^1.2
- cweagans/composer-patches: ^1.6
- drupal-composer/drupal-scaffold: ^2.2
- drupal/console: ^1.0.2
- drupal/core: ~8.4
- seregatte/drupal-docker-boilerplate: 8.0.6
- webflo/drupal-finder: ^1.0.0
- webmozart/path-util: ^2.3
Requires (Dev)
- behat/mink: ~1.7
- behat/mink-goutte-driver: ~1.2
- jcalderonzumba/gastonjs: ~1.0.2
- jcalderonzumba/mink-phantomjs-driver: ~0.3.1
- mikey179/vfsstream: ~1.2
- phpunit/phpunit: >=4.8.28 <5
- symfony/css-selector: ~2.8|~3.0
Conflicts
This package is not auto-updated.
Last update: 2025-01-28 06:55:00 UTC
README
This project template should provide a kickstart for managing your site dependencies with Composer and infrastructure with Docker via Docksal.
Requirements
Usage
You can create the project via composer or via composer inside a docker.
If you have a php cli stack and composer, try this:
composer create-project seregatte/drupal-composer-boilerplate some-dir --stability dev --no-interaction
or if you prefer run via docker:
docker run --rm -v $(pwd):/app composer/composer create-project seregatte/drupal-composer-boilerplate some-dir --stability dev --no-interaction
With composer require ...
or running the same command on docker, you can download new dependencies to your installation.
cd some-dir
composer require drupal/ctools:8.*
or
cd some-dir
docker run --rm -v $(pwd):/app composer/composer require drupal/ctools:8.*
What does the template do?
When installing the given composer.json
some tasks are taken care of:
- Drupal will be installed in the
web
-directory. - Modules (packages of type
drupal-module
) will be placed inweb/sites/all/modules/contrib/
- Theme (packages of type
drupal-module
) will be placed inweb/sites/all/themes/contrib/
- Profiles (packages of type
drupal-profile
) will be placed inweb/profiles/
- Docker stack will be placed in
infrastructure/environment/development/docker
- Makefile will be placed in project's root folder
FAQ
Should I commit the contrib modules I download
Composer recommends no. They provide argumentation against but also workrounds if a project decides to do it anyway.
How can I apply patches to downloaded modules?
If you need to apply patches (depending on the project being modified, a pull request is often a better solution), you can do so with the composer-patches plugin.
To add a patch to drupal module foobar insert the patches section in the extra section of composer.json:
"extra": { "patches": { "drupal/foobar": { "Patch description": "URL to patch" } } }