SlideShare uma empresa Scribd logo
1 de 113
Automating Drupal Development:
 Makefiles, Features and Beyond

     Antonio De Marco      Andrea Pescetti

               http://nuvole.org
                 @nuvoleweb
Nuvole: Our Team




 BELGIUM     ITALY
  Brussels   Parma
Clients in Europe and USA
Working with Drupal Distributions
Serving International
Serving International
Trainings on Code Driven
Automating Drupal
        Development
1. Automating code retrieval
2. Automating installation
3. Automating site configuration
4. Automating tests
1
Automating code retrieval
Drupal site building blocks
Core

      Modules
Contributed, Custom,




       Themes


       External
      Libraries

  Installation
       Profile

           Drupal site building blocks
drupal.org                 github.com




             example.com
The best way to download
      Introducing Drush Make
Drush Make

Drush make is a Drush command that
can create a ready-to-use Drupal site,
pulling sources from various
locations. In practical terms, this
means that it is possible to distribute
a complicated Drupal distribution as a
single text file.
Drush Make

‣   A single .info file to describe
    modules, dependencies and
    patches
‣   A one-line command to download
    contributed and custom code:
    libraries, modules, themes, etc...
Drush Make can download
Minimal makefile: core only

; distro.make
; Usage:
; $ drush make distro.make [directory]
;

api = 2
core = 7.x

projects[drupal][type] = core
projects[drupal][version] = "7.7"
Minimal makefile: core only
$ drush make distro.make myproject

drupal-7.7 downloaded.

$ ls -al myproject

-rw-r--r--    1   ademarco   staff     174   May   16   20:04   .gitignore
drwxr-xr-x   49   ademarco   staff    1666   May   16   20:04   includes/
-rw-r--r--    1   ademarco   staff     529   May   16   20:04   index.php
-rw-r--r--    1   ademarco   staff     688   May   16   20:04   install.php
drwxr-xr-x   70   ademarco   staff    2380   May   16   20:04   misc/
drwxr-xr-x   43   ademarco   staff    1462   May   16   20:04   modules/
drwxr-xr-x    6   ademarco   staff     204   May   28   13:28   profiles/
-rw-r--r--    1   ademarco   staff    1561   May   16   20:04   robots.txt
drwxr-xr-x   13   ademarco   staff     442   May   16   20:04   scripts/
drwxr-xr-x    5   ademarco   staff     170   May   16   20:04   sites/
drwxr-xr-x    8   ademarco   staff     272   May   16   20:04   themes/
-rw-r--r--    1   ademarco   staff   19338   May   16   20:04   update.php
-rw-r--r--    1   ademarco   staff    2051   May   16   20:04   web.config
-rw-r--r--    1   ademarco   staff     417   May   16   20:04   xmlrpc.php
Downloading a module

; views.make
; Usage:
; $ drush make views.make --no-core .
;

api = 2
core = 7.x

projects[views][subdir] = contrib
projects[views][version] = 3.1
Downloading a module


$ drush make views.make --no-core .

views-7.x-3.1 downloaded.

$ ls -al sites/all/modules/contrib/views/

total 64
...
-rw-r--r--   1 ademarco     staff   16067 May 28 13:28 views.info
-rw-r--r--   1 ademarco     staff   20358 May 28 13:28 views.install
-rw-r--r--   1 ademarco     staff   78204 May 28 13:28 views.module
...
Drush Make can apply
Applying patches
; distro.make
; Usage:
; $ drush make distro.make [directory]
;

api = 2
core = 7.x

projects[drupal][type] = core
projects[drupal][version] = "7.7"

; Make system directories configurable to allow tests in profiles/[name]/modules
; http://drupal.org/node/911354
projects[drupal][patch][911354] = http://drupal.org/files/issues/911354.43.patch

; Missing drupal_alter() for text formats and filters
; http://drupal.org/node/903730
projects[drupal][patch][903730] = http://drupal.org/files/issues/drupal.filter-al

...
Applying patches



$ drush make distro.make myproject

drupal-7.7 downloaded.
drupal patched with 911354.43.patch.
drupal patched with drupal.filter-alter.82.patch.
drupal patched with 995156-5_portable_taxonomy_permissions.patch.
Generated PATCHES.txt file for drupal
Drush Make supports
flexslider / flexslider.make


; Flex Slider

api = 2
core = 7.x

libraries[flexslider][download][type] = "get"
libraries[flexslider][download][url] = "https://github.com/.../zipball/master"
libraries[flexslider][directory_name] = "flexslider"
libraries[flexslider][type] = "library"
Downloading flexslider


; flexslider-module.make
; Usage:
; $ drush make flexslider-module.make --no-core .
;

api = 2
core = 7.x

projects[flexslider][subdir] = contrib
Recursive makefile parsing

$ drush make flexslider-module.make --no-core .

Project flexslider contains 4 modules: flexslider_views_slideshow,
flexslider_views, flexslider_fields, flexslider.
flexslider-7.x-1.0-rc3 downloaded.
Found makefile: flexslider.make
flexslider downloaded from https://github.com/.../zipball/master.

$ tree -l sites/all/

sites/all/
!"" libraries
#   %"" flexslider
...
%"" modules
    %"" contrib
        %"" flexslider
...
Drush Make supports
Including an external makefile

; distro.make
;
; $ drush make buildkit.make [directory]
;

api = 2
core = 7.x

; Include Build Kit distro makefile via URL
includes[] = http://drupalcode.org/project/buildkit.git/../7.x-2.x:/distro.make
Build Kit
Extendable distribution, reusable .make file
Including Build Kit module set

;
; myproject.make
;

api = 2
core = 7.x

; Include Build Kit install profile makefile via URL
includes[] = http://drupalcode.org/project/buildkit.git/../drupal-org.make

; Modules ====================================================================

projects[views_bulk_operations][subdir] = contrib

projects[coffee][subdir] = contrib
Build Kit: A closer look
Demonstrating makefile inclusion and recursion.
Build Kit provides 2 make

‣   distro.make: Drupal core with possible core
    patches and a link to download drupal-org.make
‣   drupal-org.make: a selection of common modules
    from drupal.org
Build Kit: full content

$ git clone --branch 7.x-2.x http://git.drupal.org/project/buildkit.git

...

$ ls -al buildkit/

total 48
drwxr-xr-x   9 ademarco   staff    306   Jun   14   15:45   .
drwxrwxr-x@ 20 ademarco   staff    680   Jun   14   15:45   ..
drwxr-xr-x 13 ademarco    staff    442   Jun   14   15:45   .git
-rw-r--r--   1 ademarco   staff   3868   Jun   14   15:45   README.txt
-rw-r--r--   1 ademarco   staff    583   Jun   14   15:45   buildkit.info
-rw-r--r--   1 ademarco   staff    151   Jun   14   15:45   buildkit.install
-rw-r--r--   1 ademarco   staff      6   Jun   14   15:45   buildkit.profile
-rw-r--r--   1 ademarco   staff    849   Jun   14   15:45   distro.make
-rw-r--r--   1 ademarco   staff    902   Jun   14   15:45   drupal-org.make
buildkit / distro.make

api = 2
core = 7.x

projects[drupal][type] = core
projects[drupal][version] = "7.14"

; Use vocabulary machine name for permissions
; http://drupal.org/node/995156
projects[drupal][patch][995156] = http://drupal.org/files/issues/995156-5_portab

projects[buildkit][type] = profile
projects[buildkit][download][type] = git
projects[buildkit][download][url] = http://git.drupal.org/project/buildkit.git
projects[buildkit][download][branch] = 7.x-2.x
Your project: 2 make files

‣   distro.make: Drupal core with possible core
    patches and a link to download myproject.make
‣   myproject.make: includes BuildKit’s
    drupal-org.make plus project-specific modules and
    themes
drush make distro.make
Found myproject.make




drush make distro.make
Found myproject.make




drush make distro.make
Run myproject.make




Found myproject.make




drush make distro.make
Run myproject.make




Found myproject.make




drush make distro.make
2
Automating installation
Installation Profile
Installation profile components

$ tree myproject-profile

myproject-profile
!"" README.txt
!"" distro.make
!"" drushrc.php
!"" myproject.info
!"" myproject.install
!"" myproject.make
%"" myproject.profile
Profiles: just like
modules
 ‣   An .info file to specify installation
     dependencies
 ‣   An .install file to perform
     installation tasks and upgrades
 ‣   Fully customizable via .profile files
 ‣   Can include makefiles and other
     stuff
myproject.info
name = Myproject
core = 7.x
description = Myproject installation profile.

; Core
dependencies[] = book
dependencies[] = field_ui
dependencies[] = file
...

; Contrib
dependencies[] = admin
dependencies[] = colorbox
dependencies[] = ds
...

; Features
dependencies[] = myproject_core
dependencies[] = myproject_blog
myproject.profile


/**
  * Implements hook_install()
  */
function myproject_install() {
   // Enable custom theme
   theme_enable(array('custom_theme'));
   variable_set('theme_default', 'custom_theme');
}
myproject.profile
/**
 * Implements hook_form_FORM_ID_alter().
 */
function myproject_form_install_configure_form_alter(&$form, $form_state) {

    $form['site_information']['site_name']
         ['#default_value'] = 'Drupalissimo';
    $form['site_information']
         ['site_mail']['#default_value'] = 'info@drupalissimo.com';

    $form['admin_account']['account']
         ['name']['#default_value'] = 'admin';
    $form['admin_account']['account']
         ['mail']['#default_value'] = 'dev@nuvole.org';

    $form['update_notifications']
         ['update_status_module']['#default_value'] = array(1 => FALSE, 2 => FALSE
}
myproject.install

/**
  * Implements hook_install_tasks()
  */
function myproject_install_tasks() {
   return array(
      'myproject_create_terms' => array(
         'display_name' => st('Create taxonomy terms'),
      ),
      ...
   );
}
myproject.install
/**
 * Implements hook_install_tasks() callback
 */
function myproject_create_terms() {
  $terms = array();
  $vocabulary = taxonomy_vocabulary_machine_name_load('category');

    $terms[] = 'Solution';
    $terms[] = 'Client';
    $terms[] = 'Use case';

    foreach ($terms as $name) {
      $term = new stdClass();
      $term->vid = $vocabulary->vid;
      $term->name = $name;
      taxonomy_term_save($term);
    }
}
Introducing Drush Bake
          A Drush command by Nuvole
to create installation profiles based on templates
Installation profile template
$ git clone git.nuvole.org:/var/git/starter-profile.git

...

$ tree starter-profile

starter-profile/
!"" README.txt
!"" distro.make
!"" drushrc.php
!"" starter.info
!"" starter.install
!"" starter.make
%"" starter.profile
Template distro.make

$ cat starter-profile/distro.make

api = 2
core = 7.x

; Include Build Kit distro makefile via URL
includes[] = http://drupalcode.org/project/buildkit.git/blob_plain/refs/heads/7.x



projects[starter][type] = profile
projects[starter][download][type] = git
projects[starter][download][url] = git.nuvole.org:/var/git/starter-profile.git
Template starter.make (aka
                 myproject.make)
$ cat starter-profile/starter.make

api = 2
core = 7.x

; Build Kit ===================================================================

includes[] = http://drupalcode.org/project/buildkit.git/.../drupal-org.make

; Modules =====================================================================

projects[coffee][subdir] = contrib
...

projects[twist][type] = theme
projects[twist][download][type] = git
projects[twist][download][url] = git.nuvole.org:/var/git/twist.git
Template starter.install (aka
             myproject.install)


$ cat starter-profile/starter.install

<?php

/**
  * Implements hook_install().
  */
function starter_install() {
   theme_enable(array('twist'));
   variable_set('theme_default', 'twist');
}
Generating a new installation profile




 $ drush bake starter-profile/distro.make myproject
Generating a new installation profile

$ # Create new installation profile starting from starter-profile template
$ drush bake starter-profile/distro.make myproject

...

$ tree myproject-profile

myproject-profile
!"" README.txt
!"" distro.make
!"" drushrc.php
!"" myproject.info
!"" myproject.install
!"" myproject.make
%"" myproject.profile
Generated distro.make

$ cat myproject-profile/distro.make

api = 2
core = 7.x

projects[drupal][type] = core
projects[drupal][version] = "7.12"

; Make system directories configurable to allow tests in profiles/[name]/modules
; http://drupal.org/node/911354
projects[drupal][patch][911354] = http://drupal.org/files/issues/911354.43.patch

...

projects[myproject][type] = profile
projects[myproject][download][type] = git
projects[myproject][download][url] = git.nuvole.org:/var/git/myproject-profile.gi
Full bootstrap
$ # Push profile folder to Nuvole server following internal conventions
$ git nuvole myproject-profile

$ # Build the project
$ drush make myproject-profile/distro.make myproject

drupal-7.12 downloaded.                                             [ok]
drupal patched with 911354.43.patch.                                [ok]
drupal patched with drupal.filter-alter.82.patch.                   [ok]
drupal patched with 995156-5_portable_taxonomy_permissions.patch.   [ok]
Generated PATCHES.txt file for drupal                               [ok]
myproject cloned from git.nuvole.org:/var/git/myproject-profile.git.[ok]
Found makefile: myproject.make                                      [ok]
libraries-7.x-1.0 downloaded.                                       [ok]
rubik-7.x-4.0-beta7 downloaded.                                     [ok]
twist cloned from git.nuvole.org:/var/git/twist.git.                [ok]
feature_core cloned from git.nuvole.org:/var/git/feature_core.git. [ok]
Found makefile: feature_core.make                                   [ok]
...
Bootstrap your project in 3 steps



$ drush bake starter-profile/distro.make myproject

$ git nuvole myproject-profile

$ drush make myproject-profile/distro.make myproject
3
Automating site
 configuration
Features
The best way to package configuration
What is a feature?
‣   A collection of Drupal elements
    which taken together satisfy a
    certain use-case.
‣   A modular piece of functionality for
    a Drupal site.
‣   A way to export configuration into
    PHP code, in the form of a module.
‣   http://drupal.org/project/features
Configuration in Database
Configuration in Database
Packaged as Features
Packaged as Features
Creating a Feature
It’s all in the feature’s .info
         Features are Modules
core = "7.x"
description = "Core feature, stuff we need all the time."
dependencies[] = "colorbox"
dependencies[] = "ds"
dependencies[] = "features"
dependencies[] = "insert"
dependencies[] = "markdown"
dependencies[] = "menu"
dependencies[] = "pathauto"
dependencies[] = "strongarm"
dependencies[] = "token"
features[ctools][] = "ds:ds:1"
features[ctools][] = "strongarm:strongarm:1"
features[ds_view_modes][] = "core_small_teaser"
features[filter][] = "core_rich_text"
features[menu_custom][] = "main-menu"
features[menu_links][] = "main-menu:<front>"
features[user_permission][] = "access content"
features[user_permission][] = "use text format core_rich_text"
features[variable][] = "admin_toolbar"
features[variable][] = "date_format_long"
...
A feature can have a .make
     Drush Make operates recursively
api = 2
core = 7.x

; Modules =====================================================================

projects[colorbox][subdir] = contrib
projects[colorbox][version] = 1.0-beta4

projects[insert][subdir] = contrib
projects[insert][version] = 1.1



; Libraries ===================================================================

libraries[colorbox_library][download][type] = "get"
libraries[colorbox_library][download][url] = "http://colorpowered.com/colorbox/
libraries[colorbox_library][directory_name] = "colorbox"
libraries[colorbox_library][destination] = "libraries"




                      feature_core.mak
             A feature can specify where to find its own
                            dependencies
How to download your
projects from any custom
$ cat starter-profile/starter.make

api = 2
core = 7.x

; Build Kit ===================================================================

includes[] = http://drupalcode.org/project/buildkit.git/blob_plain/refs/heads/7.x

; Modules =====================================================================

projects[libraries][subdir] = contrib
projects[libraries][version] = 1.0

; Features ====================================================================

projects[feature_core][type] = module
projects[feature_core][subdir] = features
projects[feature_core][download][type] = "git"
projects[feature_core][download][url] = git.nuvole.org:/var/git/feature_core.git

; Themes ======================================================================

projects[twist][type] = theme
projects[twist][download][type] = git
projects[twist][download][url] = git.nuvole.org:/var/git/twist.git
Introducing Feature
Keep features, themes, makefiles, etc... organized.
$ cat starter-profile/starter.make

api = 2
core = 7.x

; Build Kit ===================================================================

includes[] = http://drupalcode.org/project/buildkit.git/blob_plain/refs/heads/7.x-

; Modules =====================================================================

projects[libraries][subdir] = contrib
projects[libraries][version] = 1.0

; Features ====================================================================

projects[feature_core][subdir] = features
projects[feature_core][location] = http://fserver.nuvole.org/fserver

; Themes ======================================================================

projects[twist][type] = theme
projects[twist][location] = http://fserver.nuvole.org/fserver
Feature Server and Drush
$ # Drush goodies
$ drush | grep fserver

 fserver-distro          Update packaging for a distribution.
 fserver-package         Update packaging for a project.
 fserver-status          Determine the packaging status of a project.

$ # Build releases for feature_news based on GIT tags and branches
$ drush fserver-package feature_news

$ # Check releases status
$ drush fserver-status

Method   Project       New tags
git      Feature News 7.x-1.0
git      Feature Pages 7.x-1.0
...
4
Automating tests
Don't depend on trust
  Automatically test every component
Meet Continuous

Use Hudson/Jenkins to automatically test:
 1. Makefile
 2. Installation
 3. Configuration
Building a CI Job

‣   Create a job for testing your site
‣   Triggered:
    ‣   Manually
    ‣   Scheduled
    ‣   By events (git push or other jobs)
‣   A job can consist of ant scripts or simple shell
    commands (including drush)
Test #1: Makefile

‣   Clone your code from git
‣   Run drush make
‣   Test that the profile is downloaded
‣   Test that modules are placed in the expected
    folders
Test #1: Shell commands

‣   drush -y --pipe make distro.make
‣   test -d profiles/myproject
‣   test -d profiles/myproject/modules/contrib
‣   test -d profiles/myproject/modules/custom
‣   test -d profiles/myproject/modules/features
Test #2: Installation

‣   Triggered by successful completion of Test #1
‣   Run drush site-install:

    drush -y site-install ... myproject
‣   Expect successful completion
Test #3: Configuration

‣   Triggered by successful completion of Test #2
‣   Relies on simpletest
‣   Run drush test-run
‣   Expect successful completion
Thank You.

More on Code-Driven Development
 http://nuvole.org/blog
 http://nuvole.org/trainings

Mais conteúdo relacionado

Mais procurados

Gestione della configurazione in Drupal 8
Gestione della configurazione in Drupal 8Gestione della configurazione in Drupal 8
Gestione della configurazione in Drupal 8Eugenio Minardi
 
Drupal 8 - Corso frontend development
Drupal 8 - Corso frontend developmentDrupal 8 - Corso frontend development
Drupal 8 - Corso frontend developmentsparkfabrik
 
Building and Maintaining a Distribution in Drupal 7 with Features
Building and Maintaining a  Distribution in Drupal 7 with FeaturesBuilding and Maintaining a  Distribution in Drupal 7 with Features
Building and Maintaining a Distribution in Drupal 7 with FeaturesNuvole
 
Hive Quick Start Tutorial
Hive Quick Start TutorialHive Quick Start Tutorial
Hive Quick Start TutorialCarl Steinbach
 
Becoming A Drupal Master Builder
Becoming A Drupal Master BuilderBecoming A Drupal Master Builder
Becoming A Drupal Master BuilderPhilip Norton
 
Taking your module from Drupal 6 to Drupal 7
Taking your module from Drupal 6 to Drupal 7Taking your module from Drupal 6 to Drupal 7
Taking your module from Drupal 6 to Drupal 7Phase2
 
Improving your Drupal 8 development workflow DrupalCampLA
Improving your Drupal 8 development workflow DrupalCampLAImproving your Drupal 8 development workflow DrupalCampLA
Improving your Drupal 8 development workflow DrupalCampLAJesus Manuel Olivas
 
ExtBase workshop
ExtBase workshop ExtBase workshop
ExtBase workshop schmutt
 
Getting Into Drupal 8 Configuration
Getting Into Drupal 8 ConfigurationGetting Into Drupal 8 Configuration
Getting Into Drupal 8 ConfigurationPhilip Norton
 
Introduction to Drupal - Installation, Anatomy, Terminologies
Introduction to Drupal - Installation, Anatomy, TerminologiesIntroduction to Drupal - Installation, Anatomy, Terminologies
Introduction to Drupal - Installation, Anatomy, TerminologiesGerald Villorente
 
Drupal 8 Services And Dependency Injection
Drupal 8 Services And Dependency InjectionDrupal 8 Services And Dependency Injection
Drupal 8 Services And Dependency InjectionPhilip Norton
 
CertiFUNcation 2017 Best Practices Extension Development for TYPO3 8 LTS
CertiFUNcation 2017 Best Practices Extension Development for TYPO3 8 LTSCertiFUNcation 2017 Best Practices Extension Development for TYPO3 8 LTS
CertiFUNcation 2017 Best Practices Extension Development for TYPO3 8 LTScpsitgmbh
 
Working with Hive Analytics
Working with Hive AnalyticsWorking with Hive Analytics
Working with Hive AnalyticsManish Chopra
 
PiBase Updates
PiBase UpdatesPiBase Updates
PiBase Updatesschmutt
 
SpringBoot with MyBatis, Flyway, QueryDSL
SpringBoot with MyBatis, Flyway, QueryDSLSpringBoot with MyBatis, Flyway, QueryDSL
SpringBoot with MyBatis, Flyway, QueryDSLSunghyouk Bae
 

Mais procurados (20)

Gestione della configurazione in Drupal 8
Gestione della configurazione in Drupal 8Gestione della configurazione in Drupal 8
Gestione della configurazione in Drupal 8
 
Drupal 8 - Corso frontend development
Drupal 8 - Corso frontend developmentDrupal 8 - Corso frontend development
Drupal 8 - Corso frontend development
 
Building and Maintaining a Distribution in Drupal 7 with Features
Building and Maintaining a  Distribution in Drupal 7 with FeaturesBuilding and Maintaining a  Distribution in Drupal 7 with Features
Building and Maintaining a Distribution in Drupal 7 with Features
 
Hive Quick Start Tutorial
Hive Quick Start TutorialHive Quick Start Tutorial
Hive Quick Start Tutorial
 
Becoming A Drupal Master Builder
Becoming A Drupal Master BuilderBecoming A Drupal Master Builder
Becoming A Drupal Master Builder
 
Taking your module from Drupal 6 to Drupal 7
Taking your module from Drupal 6 to Drupal 7Taking your module from Drupal 6 to Drupal 7
Taking your module from Drupal 6 to Drupal 7
 
Improving your Drupal 8 development workflow DrupalCampLA
Improving your Drupal 8 development workflow DrupalCampLAImproving your Drupal 8 development workflow DrupalCampLA
Improving your Drupal 8 development workflow DrupalCampLA
 
ExtBase workshop
ExtBase workshop ExtBase workshop
ExtBase workshop
 
Getting Into Drupal 8 Configuration
Getting Into Drupal 8 ConfigurationGetting Into Drupal 8 Configuration
Getting Into Drupal 8 Configuration
 
Introduction to Drupal - Installation, Anatomy, Terminologies
Introduction to Drupal - Installation, Anatomy, TerminologiesIntroduction to Drupal - Installation, Anatomy, Terminologies
Introduction to Drupal - Installation, Anatomy, Terminologies
 
Drupal 8 Services And Dependency Injection
Drupal 8 Services And Dependency InjectionDrupal 8 Services And Dependency Injection
Drupal 8 Services And Dependency Injection
 
Beginning hive and_apache_pig
Beginning hive and_apache_pigBeginning hive and_apache_pig
Beginning hive and_apache_pig
 
CertiFUNcation 2017 Best Practices Extension Development for TYPO3 8 LTS
CertiFUNcation 2017 Best Practices Extension Development for TYPO3 8 LTSCertiFUNcation 2017 Best Practices Extension Development for TYPO3 8 LTS
CertiFUNcation 2017 Best Practices Extension Development for TYPO3 8 LTS
 
Drupal 8 Services
Drupal 8 ServicesDrupal 8 Services
Drupal 8 Services
 
Working with Hive Analytics
Working with Hive AnalyticsWorking with Hive Analytics
Working with Hive Analytics
 
PiBase Updates
PiBase UpdatesPiBase Updates
PiBase Updates
 
Local Drupal MultiSite Set-up
Local Drupal MultiSite Set-upLocal Drupal MultiSite Set-up
Local Drupal MultiSite Set-up
 
SpringBoot with MyBatis, Flyway, QueryDSL
SpringBoot with MyBatis, Flyway, QueryDSLSpringBoot with MyBatis, Flyway, QueryDSL
SpringBoot with MyBatis, Flyway, QueryDSL
 
Changelog
ChangelogChangelog
Changelog
 
CHANGELOG.txt
CHANGELOG.txtCHANGELOG.txt
CHANGELOG.txt
 

Semelhante a Automating Drupal Development: Makefiles, features and beyond

Drupal Day 2012 - Automating Drupal Development: Make!les, Features and Beyond
Drupal Day 2012 - Automating Drupal Development: Make!les, Features and BeyondDrupal Day 2012 - Automating Drupal Development: Make!les, Features and Beyond
Drupal Day 2012 - Automating Drupal Development: Make!les, Features and BeyondDrupalDay
 
[EXTENDED] Ceph, Docker, Heroku Slugs, CoreOS and Deis Overview
[EXTENDED] Ceph, Docker, Heroku Slugs, CoreOS and Deis Overview[EXTENDED] Ceph, Docker, Heroku Slugs, CoreOS and Deis Overview
[EXTENDED] Ceph, Docker, Heroku Slugs, CoreOS and Deis OverviewLeo Lorieri
 
Hands on Docker - Launch your own LEMP or LAMP stack
Hands on Docker -  Launch your own LEMP or LAMP stackHands on Docker -  Launch your own LEMP or LAMP stack
Hands on Docker - Launch your own LEMP or LAMP stackDana Luther
 
Asian Spirit 3 Day Dba On Ubl
Asian Spirit 3 Day Dba On UblAsian Spirit 3 Day Dba On Ubl
Asian Spirit 3 Day Dba On Ublnewrforce
 
2017-03-11 02 Денис Нелюбин. Docker & Ansible - лучшие друзья DevOps
2017-03-11 02 Денис Нелюбин. Docker & Ansible - лучшие друзья DevOps2017-03-11 02 Денис Нелюбин. Docker & Ansible - лучшие друзья DevOps
2017-03-11 02 Денис Нелюбин. Docker & Ansible - лучшие друзья DevOpsОмские ИТ-субботники
 
Sergei Stryukov.Drush.Why it should be used.DrupalCamp Kyiv 2011
Sergei Stryukov.Drush.Why it should be used.DrupalCamp Kyiv 2011Sergei Stryukov.Drush.Why it should be used.DrupalCamp Kyiv 2011
Sergei Stryukov.Drush.Why it should be used.DrupalCamp Kyiv 2011camp_drupal_ua
 
Hands on Docker - Launch your own LEMP or LAMP stack - SunshinePHP
Hands on Docker - Launch your own LEMP or LAMP stack - SunshinePHPHands on Docker - Launch your own LEMP or LAMP stack - SunshinePHP
Hands on Docker - Launch your own LEMP or LAMP stack - SunshinePHPDana Luther
 
Towards the perfect Drupal Dev Machine
Towards the perfect Drupal Dev MachineTowards the perfect Drupal Dev Machine
Towards the perfect Drupal Dev MachineKrimson
 
Using Composer with Drupal and Drush
Using Composer with Drupal and DrushUsing Composer with Drupal and Drush
Using Composer with Drupal and DrushPantheon
 
Development Setup of B-Translator
Development Setup of B-TranslatorDevelopment Setup of B-Translator
Development Setup of B-TranslatorDashamir Hoxha
 
Lean Drupal Repositories with Composer and Drush
Lean Drupal Repositories with Composer and DrushLean Drupal Repositories with Composer and Drush
Lean Drupal Repositories with Composer and DrushPantheon
 
Building and Customizing CoreOS
Building and Customizing CoreOSBuilding and Customizing CoreOS
Building and Customizing CoreOS雄也 日下部
 
Drush. Why should it be used?
Drush. Why should it be used?Drush. Why should it be used?
Drush. Why should it be used?Sergei Stryukov
 
2012 coscup - Build your PHP application on Heroku
2012 coscup - Build your PHP application on Heroku2012 coscup - Build your PHP application on Heroku
2012 coscup - Build your PHP application on Herokuronnywang_tw
 
Zend Framework 1.9 Setup & Using Zend_Tool
Zend Framework 1.9 Setup & Using Zend_ToolZend Framework 1.9 Setup & Using Zend_Tool
Zend Framework 1.9 Setup & Using Zend_ToolGordon Forsythe
 
Dependencies Managers in C/C++. Using stdcpp 2014
Dependencies Managers in C/C++. Using stdcpp 2014Dependencies Managers in C/C++. Using stdcpp 2014
Dependencies Managers in C/C++. Using stdcpp 2014biicode
 
Drupal 8 improvements for developer productivity php symfony and more
Drupal 8 improvements for developer productivity  php symfony and moreDrupal 8 improvements for developer productivity  php symfony and more
Drupal 8 improvements for developer productivity php symfony and moreAcquia
 
Virtualization and automation of library software/machines + Puppet
Virtualization and automation of library software/machines + PuppetVirtualization and automation of library software/machines + Puppet
Virtualization and automation of library software/machines + PuppetOmar Reygaert
 

Semelhante a Automating Drupal Development: Makefiles, features and beyond (20)

Drupal Day 2012 - Automating Drupal Development: Make!les, Features and Beyond
Drupal Day 2012 - Automating Drupal Development: Make!les, Features and BeyondDrupal Day 2012 - Automating Drupal Development: Make!les, Features and Beyond
Drupal Day 2012 - Automating Drupal Development: Make!les, Features and Beyond
 
[EXTENDED] Ceph, Docker, Heroku Slugs, CoreOS and Deis Overview
[EXTENDED] Ceph, Docker, Heroku Slugs, CoreOS and Deis Overview[EXTENDED] Ceph, Docker, Heroku Slugs, CoreOS and Deis Overview
[EXTENDED] Ceph, Docker, Heroku Slugs, CoreOS and Deis Overview
 
Hands on Docker - Launch your own LEMP or LAMP stack
Hands on Docker -  Launch your own LEMP or LAMP stackHands on Docker -  Launch your own LEMP or LAMP stack
Hands on Docker - Launch your own LEMP or LAMP stack
 
Secure your site
Secure your siteSecure your site
Secure your site
 
Asian Spirit 3 Day Dba On Ubl
Asian Spirit 3 Day Dba On UblAsian Spirit 3 Day Dba On Ubl
Asian Spirit 3 Day Dba On Ubl
 
2017-03-11 02 Денис Нелюбин. Docker & Ansible - лучшие друзья DevOps
2017-03-11 02 Денис Нелюбин. Docker & Ansible - лучшие друзья DevOps2017-03-11 02 Денис Нелюбин. Docker & Ansible - лучшие друзья DevOps
2017-03-11 02 Денис Нелюбин. Docker & Ansible - лучшие друзья DevOps
 
Sergei Stryukov.Drush.Why it should be used.DrupalCamp Kyiv 2011
Sergei Stryukov.Drush.Why it should be used.DrupalCamp Kyiv 2011Sergei Stryukov.Drush.Why it should be used.DrupalCamp Kyiv 2011
Sergei Stryukov.Drush.Why it should be used.DrupalCamp Kyiv 2011
 
Hands on Docker - Launch your own LEMP or LAMP stack - SunshinePHP
Hands on Docker - Launch your own LEMP or LAMP stack - SunshinePHPHands on Docker - Launch your own LEMP or LAMP stack - SunshinePHP
Hands on Docker - Launch your own LEMP or LAMP stack - SunshinePHP
 
Towards the perfect Drupal Dev Machine
Towards the perfect Drupal Dev MachineTowards the perfect Drupal Dev Machine
Towards the perfect Drupal Dev Machine
 
Docker, c'est bonheur !
Docker, c'est bonheur !Docker, c'est bonheur !
Docker, c'est bonheur !
 
Using Composer with Drupal and Drush
Using Composer with Drupal and DrushUsing Composer with Drupal and Drush
Using Composer with Drupal and Drush
 
Development Setup of B-Translator
Development Setup of B-TranslatorDevelopment Setup of B-Translator
Development Setup of B-Translator
 
Lean Drupal Repositories with Composer and Drush
Lean Drupal Repositories with Composer and DrushLean Drupal Repositories with Composer and Drush
Lean Drupal Repositories with Composer and Drush
 
Building and Customizing CoreOS
Building and Customizing CoreOSBuilding and Customizing CoreOS
Building and Customizing CoreOS
 
Drush. Why should it be used?
Drush. Why should it be used?Drush. Why should it be used?
Drush. Why should it be used?
 
2012 coscup - Build your PHP application on Heroku
2012 coscup - Build your PHP application on Heroku2012 coscup - Build your PHP application on Heroku
2012 coscup - Build your PHP application on Heroku
 
Zend Framework 1.9 Setup & Using Zend_Tool
Zend Framework 1.9 Setup & Using Zend_ToolZend Framework 1.9 Setup & Using Zend_Tool
Zend Framework 1.9 Setup & Using Zend_Tool
 
Dependencies Managers in C/C++. Using stdcpp 2014
Dependencies Managers in C/C++. Using stdcpp 2014Dependencies Managers in C/C++. Using stdcpp 2014
Dependencies Managers in C/C++. Using stdcpp 2014
 
Drupal 8 improvements for developer productivity php symfony and more
Drupal 8 improvements for developer productivity  php symfony and moreDrupal 8 improvements for developer productivity  php symfony and more
Drupal 8 improvements for developer productivity php symfony and more
 
Virtualization and automation of library software/machines + Puppet
Virtualization and automation of library software/machines + PuppetVirtualization and automation of library software/machines + Puppet
Virtualization and automation of library software/machines + Puppet
 

Mais de Nuvole

The OpenEuropa Initiative
The OpenEuropa InitiativeThe OpenEuropa Initiative
The OpenEuropa InitiativeNuvole
 
CMI 2.0 session at Drupal DevDays in Cluj-Napoca
CMI 2.0 session at Drupal DevDays in Cluj-NapocaCMI 2.0 session at Drupal DevDays in Cluj-Napoca
CMI 2.0 session at Drupal DevDays in Cluj-NapocaNuvole
 
Introducing the UI Patterns module: use atomic UI components everywhere in Dr...
Introducing the UI Patterns module: use atomic UI components everywhere in Dr...Introducing the UI Patterns module: use atomic UI components everywhere in Dr...
Introducing the UI Patterns module: use atomic UI components everywhere in Dr...Nuvole
 
Remote Collaboration and Institutional Intranets with Drupal and Open Atrium
Remote Collaboration and Institutional Intranets with Drupal and Open AtriumRemote Collaboration and Institutional Intranets with Drupal and Open Atrium
Remote Collaboration and Institutional Intranets with Drupal and Open AtriumNuvole
 
Public Works Monitoring
Public Works MonitoringPublic Works Monitoring
Public Works MonitoringNuvole
 
Extending and Customizing Open Atrium
Extending and Customizing Open AtriumExtending and Customizing Open Atrium
Extending and Customizing Open AtriumNuvole
 
Code driven development: using Features effectively in Drupal 6 and 7
Code driven development: using Features effectively in Drupal 6 and 7Code driven development: using Features effectively in Drupal 6 and 7
Code driven development: using Features effectively in Drupal 6 and 7Nuvole
 
Features based development workflow
Features based development workflowFeatures based development workflow
Features based development workflowNuvole
 
First Steps in Drupal Code Driven Development
First Steps in Drupal Code Driven DevelopmentFirst Steps in Drupal Code Driven Development
First Steps in Drupal Code Driven DevelopmentNuvole
 

Mais de Nuvole (9)

The OpenEuropa Initiative
The OpenEuropa InitiativeThe OpenEuropa Initiative
The OpenEuropa Initiative
 
CMI 2.0 session at Drupal DevDays in Cluj-Napoca
CMI 2.0 session at Drupal DevDays in Cluj-NapocaCMI 2.0 session at Drupal DevDays in Cluj-Napoca
CMI 2.0 session at Drupal DevDays in Cluj-Napoca
 
Introducing the UI Patterns module: use atomic UI components everywhere in Dr...
Introducing the UI Patterns module: use atomic UI components everywhere in Dr...Introducing the UI Patterns module: use atomic UI components everywhere in Dr...
Introducing the UI Patterns module: use atomic UI components everywhere in Dr...
 
Remote Collaboration and Institutional Intranets with Drupal and Open Atrium
Remote Collaboration and Institutional Intranets with Drupal and Open AtriumRemote Collaboration and Institutional Intranets with Drupal and Open Atrium
Remote Collaboration and Institutional Intranets with Drupal and Open Atrium
 
Public Works Monitoring
Public Works MonitoringPublic Works Monitoring
Public Works Monitoring
 
Extending and Customizing Open Atrium
Extending and Customizing Open AtriumExtending and Customizing Open Atrium
Extending and Customizing Open Atrium
 
Code driven development: using Features effectively in Drupal 6 and 7
Code driven development: using Features effectively in Drupal 6 and 7Code driven development: using Features effectively in Drupal 6 and 7
Code driven development: using Features effectively in Drupal 6 and 7
 
Features based development workflow
Features based development workflowFeatures based development workflow
Features based development workflow
 
First Steps in Drupal Code Driven Development
First Steps in Drupal Code Driven DevelopmentFirst Steps in Drupal Code Driven Development
First Steps in Drupal Code Driven Development
 

Último

Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Scriptwesley chun
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessPixlogix Infotech
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024Results
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...Neo4j
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Enterprise Knowledge
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxKatpro Technologies
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?Antenna Manufacturer Coco
 

Último (20)

Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your Business
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 

Automating Drupal Development: Makefiles, features and beyond

  • 1. Automating Drupal Development: Makefiles, Features and Beyond Antonio De Marco Andrea Pescetti http://nuvole.org @nuvoleweb
  • 2. Nuvole: Our Team BELGIUM ITALY Brussels Parma
  • 4. Working with Drupal Distributions
  • 7.
  • 9. Automating Drupal Development 1. Automating code retrieval 2. Automating installation 3. Automating site configuration 4. Automating tests
  • 12. Core Modules Contributed, Custom, Themes External Libraries Installation Profile Drupal site building blocks
  • 13. drupal.org github.com example.com
  • 14. The best way to download Introducing Drush Make
  • 15.
  • 16. Drush Make Drush make is a Drush command that can create a ready-to-use Drupal site, pulling sources from various locations. In practical terms, this means that it is possible to distribute a complicated Drupal distribution as a single text file.
  • 17. Drush Make ‣ A single .info file to describe modules, dependencies and patches ‣ A one-line command to download contributed and custom code: libraries, modules, themes, etc...
  • 18. Drush Make can download
  • 19. Minimal makefile: core only ; distro.make ; Usage: ; $ drush make distro.make [directory] ; api = 2 core = 7.x projects[drupal][type] = core projects[drupal][version] = "7.7"
  • 20. Minimal makefile: core only $ drush make distro.make myproject drupal-7.7 downloaded. $ ls -al myproject -rw-r--r-- 1 ademarco staff 174 May 16 20:04 .gitignore drwxr-xr-x 49 ademarco staff 1666 May 16 20:04 includes/ -rw-r--r-- 1 ademarco staff 529 May 16 20:04 index.php -rw-r--r-- 1 ademarco staff 688 May 16 20:04 install.php drwxr-xr-x 70 ademarco staff 2380 May 16 20:04 misc/ drwxr-xr-x 43 ademarco staff 1462 May 16 20:04 modules/ drwxr-xr-x 6 ademarco staff 204 May 28 13:28 profiles/ -rw-r--r-- 1 ademarco staff 1561 May 16 20:04 robots.txt drwxr-xr-x 13 ademarco staff 442 May 16 20:04 scripts/ drwxr-xr-x 5 ademarco staff 170 May 16 20:04 sites/ drwxr-xr-x 8 ademarco staff 272 May 16 20:04 themes/ -rw-r--r-- 1 ademarco staff 19338 May 16 20:04 update.php -rw-r--r-- 1 ademarco staff 2051 May 16 20:04 web.config -rw-r--r-- 1 ademarco staff 417 May 16 20:04 xmlrpc.php
  • 21. Downloading a module ; views.make ; Usage: ; $ drush make views.make --no-core . ; api = 2 core = 7.x projects[views][subdir] = contrib projects[views][version] = 3.1
  • 22. Downloading a module $ drush make views.make --no-core . views-7.x-3.1 downloaded. $ ls -al sites/all/modules/contrib/views/ total 64 ... -rw-r--r-- 1 ademarco staff 16067 May 28 13:28 views.info -rw-r--r-- 1 ademarco staff 20358 May 28 13:28 views.install -rw-r--r-- 1 ademarco staff 78204 May 28 13:28 views.module ...
  • 23. Drush Make can apply
  • 24. Applying patches ; distro.make ; Usage: ; $ drush make distro.make [directory] ; api = 2 core = 7.x projects[drupal][type] = core projects[drupal][version] = "7.7" ; Make system directories configurable to allow tests in profiles/[name]/modules ; http://drupal.org/node/911354 projects[drupal][patch][911354] = http://drupal.org/files/issues/911354.43.patch ; Missing drupal_alter() for text formats and filters ; http://drupal.org/node/903730 projects[drupal][patch][903730] = http://drupal.org/files/issues/drupal.filter-al ...
  • 25. Applying patches $ drush make distro.make myproject drupal-7.7 downloaded. drupal patched with 911354.43.patch. drupal patched with drupal.filter-alter.82.patch. drupal patched with 995156-5_portable_taxonomy_permissions.patch. Generated PATCHES.txt file for drupal
  • 27.
  • 28.
  • 29. flexslider / flexslider.make ; Flex Slider api = 2 core = 7.x libraries[flexslider][download][type] = "get" libraries[flexslider][download][url] = "https://github.com/.../zipball/master" libraries[flexslider][directory_name] = "flexslider" libraries[flexslider][type] = "library"
  • 30. Downloading flexslider ; flexslider-module.make ; Usage: ; $ drush make flexslider-module.make --no-core . ; api = 2 core = 7.x projects[flexslider][subdir] = contrib
  • 31. Recursive makefile parsing $ drush make flexslider-module.make --no-core . Project flexslider contains 4 modules: flexslider_views_slideshow, flexslider_views, flexslider_fields, flexslider. flexslider-7.x-1.0-rc3 downloaded. Found makefile: flexslider.make flexslider downloaded from https://github.com/.../zipball/master. $ tree -l sites/all/ sites/all/ !"" libraries #   %"" flexslider ... %"" modules %"" contrib %"" flexslider ...
  • 33. Including an external makefile ; distro.make ; ; $ drush make buildkit.make [directory] ; api = 2 core = 7.x ; Include Build Kit distro makefile via URL includes[] = http://drupalcode.org/project/buildkit.git/../7.x-2.x:/distro.make
  • 34. Build Kit Extendable distribution, reusable .make file
  • 35.
  • 36. Including Build Kit module set ; ; myproject.make ; api = 2 core = 7.x ; Include Build Kit install profile makefile via URL includes[] = http://drupalcode.org/project/buildkit.git/../drupal-org.make ; Modules ==================================================================== projects[views_bulk_operations][subdir] = contrib projects[coffee][subdir] = contrib
  • 37. Build Kit: A closer look Demonstrating makefile inclusion and recursion.
  • 38. Build Kit provides 2 make ‣ distro.make: Drupal core with possible core patches and a link to download drupal-org.make ‣ drupal-org.make: a selection of common modules from drupal.org
  • 39. Build Kit: full content $ git clone --branch 7.x-2.x http://git.drupal.org/project/buildkit.git ... $ ls -al buildkit/ total 48 drwxr-xr-x 9 ademarco staff 306 Jun 14 15:45 . drwxrwxr-x@ 20 ademarco staff 680 Jun 14 15:45 .. drwxr-xr-x 13 ademarco staff 442 Jun 14 15:45 .git -rw-r--r-- 1 ademarco staff 3868 Jun 14 15:45 README.txt -rw-r--r-- 1 ademarco staff 583 Jun 14 15:45 buildkit.info -rw-r--r-- 1 ademarco staff 151 Jun 14 15:45 buildkit.install -rw-r--r-- 1 ademarco staff 6 Jun 14 15:45 buildkit.profile -rw-r--r-- 1 ademarco staff 849 Jun 14 15:45 distro.make -rw-r--r-- 1 ademarco staff 902 Jun 14 15:45 drupal-org.make
  • 40. buildkit / distro.make api = 2 core = 7.x projects[drupal][type] = core projects[drupal][version] = "7.14" ; Use vocabulary machine name for permissions ; http://drupal.org/node/995156 projects[drupal][patch][995156] = http://drupal.org/files/issues/995156-5_portab projects[buildkit][type] = profile projects[buildkit][download][type] = git projects[buildkit][download][url] = http://git.drupal.org/project/buildkit.git projects[buildkit][download][branch] = 7.x-2.x
  • 41. Your project: 2 make files ‣ distro.make: Drupal core with possible core patches and a link to download myproject.make ‣ myproject.make: includes BuildKit’s drupal-org.make plus project-specific modules and themes
  • 49.
  • 50. Installation profile components $ tree myproject-profile myproject-profile !"" README.txt !"" distro.make !"" drushrc.php !"" myproject.info !"" myproject.install !"" myproject.make %"" myproject.profile
  • 51. Profiles: just like modules ‣ An .info file to specify installation dependencies ‣ An .install file to perform installation tasks and upgrades ‣ Fully customizable via .profile files ‣ Can include makefiles and other stuff
  • 52. myproject.info name = Myproject core = 7.x description = Myproject installation profile. ; Core dependencies[] = book dependencies[] = field_ui dependencies[] = file ... ; Contrib dependencies[] = admin dependencies[] = colorbox dependencies[] = ds ... ; Features dependencies[] = myproject_core dependencies[] = myproject_blog
  • 53. myproject.profile /** * Implements hook_install() */ function myproject_install() { // Enable custom theme theme_enable(array('custom_theme')); variable_set('theme_default', 'custom_theme'); }
  • 54. myproject.profile /** * Implements hook_form_FORM_ID_alter(). */ function myproject_form_install_configure_form_alter(&$form, $form_state) { $form['site_information']['site_name'] ['#default_value'] = 'Drupalissimo'; $form['site_information'] ['site_mail']['#default_value'] = 'info@drupalissimo.com'; $form['admin_account']['account'] ['name']['#default_value'] = 'admin'; $form['admin_account']['account'] ['mail']['#default_value'] = 'dev@nuvole.org'; $form['update_notifications'] ['update_status_module']['#default_value'] = array(1 => FALSE, 2 => FALSE }
  • 55.
  • 56.
  • 57. myproject.install /** * Implements hook_install_tasks() */ function myproject_install_tasks() { return array( 'myproject_create_terms' => array( 'display_name' => st('Create taxonomy terms'), ), ... ); }
  • 58.
  • 59.
  • 60. myproject.install /** * Implements hook_install_tasks() callback */ function myproject_create_terms() { $terms = array(); $vocabulary = taxonomy_vocabulary_machine_name_load('category'); $terms[] = 'Solution'; $terms[] = 'Client'; $terms[] = 'Use case'; foreach ($terms as $name) { $term = new stdClass(); $term->vid = $vocabulary->vid; $term->name = $name; taxonomy_term_save($term); } }
  • 61.
  • 62.
  • 63. Introducing Drush Bake A Drush command by Nuvole to create installation profiles based on templates
  • 64. Installation profile template $ git clone git.nuvole.org:/var/git/starter-profile.git ... $ tree starter-profile starter-profile/ !"" README.txt !"" distro.make !"" drushrc.php !"" starter.info !"" starter.install !"" starter.make %"" starter.profile
  • 65. Template distro.make $ cat starter-profile/distro.make api = 2 core = 7.x ; Include Build Kit distro makefile via URL includes[] = http://drupalcode.org/project/buildkit.git/blob_plain/refs/heads/7.x projects[starter][type] = profile projects[starter][download][type] = git projects[starter][download][url] = git.nuvole.org:/var/git/starter-profile.git
  • 66. Template starter.make (aka myproject.make) $ cat starter-profile/starter.make api = 2 core = 7.x ; Build Kit =================================================================== includes[] = http://drupalcode.org/project/buildkit.git/.../drupal-org.make ; Modules ===================================================================== projects[coffee][subdir] = contrib ... projects[twist][type] = theme projects[twist][download][type] = git projects[twist][download][url] = git.nuvole.org:/var/git/twist.git
  • 67. Template starter.install (aka myproject.install) $ cat starter-profile/starter.install <?php /** * Implements hook_install(). */ function starter_install() { theme_enable(array('twist')); variable_set('theme_default', 'twist'); }
  • 68. Generating a new installation profile $ drush bake starter-profile/distro.make myproject
  • 69. Generating a new installation profile $ # Create new installation profile starting from starter-profile template $ drush bake starter-profile/distro.make myproject ... $ tree myproject-profile myproject-profile !"" README.txt !"" distro.make !"" drushrc.php !"" myproject.info !"" myproject.install !"" myproject.make %"" myproject.profile
  • 70. Generated distro.make $ cat myproject-profile/distro.make api = 2 core = 7.x projects[drupal][type] = core projects[drupal][version] = "7.12" ; Make system directories configurable to allow tests in profiles/[name]/modules ; http://drupal.org/node/911354 projects[drupal][patch][911354] = http://drupal.org/files/issues/911354.43.patch ... projects[myproject][type] = profile projects[myproject][download][type] = git projects[myproject][download][url] = git.nuvole.org:/var/git/myproject-profile.gi
  • 71. Full bootstrap $ # Push profile folder to Nuvole server following internal conventions $ git nuvole myproject-profile $ # Build the project $ drush make myproject-profile/distro.make myproject drupal-7.12 downloaded. [ok] drupal patched with 911354.43.patch. [ok] drupal patched with drupal.filter-alter.82.patch. [ok] drupal patched with 995156-5_portable_taxonomy_permissions.patch. [ok] Generated PATCHES.txt file for drupal [ok] myproject cloned from git.nuvole.org:/var/git/myproject-profile.git.[ok] Found makefile: myproject.make [ok] libraries-7.x-1.0 downloaded. [ok] rubik-7.x-4.0-beta7 downloaded. [ok] twist cloned from git.nuvole.org:/var/git/twist.git. [ok] feature_core cloned from git.nuvole.org:/var/git/feature_core.git. [ok] Found makefile: feature_core.make [ok] ...
  • 72. Bootstrap your project in 3 steps $ drush bake starter-profile/distro.make myproject $ git nuvole myproject-profile $ drush make myproject-profile/distro.make myproject
  • 74. Features The best way to package configuration
  • 75.
  • 76. What is a feature? ‣ A collection of Drupal elements which taken together satisfy a certain use-case. ‣ A modular piece of functionality for a Drupal site. ‣ A way to export configuration into PHP code, in the form of a module. ‣ http://drupal.org/project/features
  • 82.
  • 83.
  • 84.
  • 85. It’s all in the feature’s .info Features are Modules
  • 86. core = "7.x" description = "Core feature, stuff we need all the time." dependencies[] = "colorbox" dependencies[] = "ds" dependencies[] = "features" dependencies[] = "insert" dependencies[] = "markdown" dependencies[] = "menu" dependencies[] = "pathauto" dependencies[] = "strongarm" dependencies[] = "token" features[ctools][] = "ds:ds:1" features[ctools][] = "strongarm:strongarm:1" features[ds_view_modes][] = "core_small_teaser" features[filter][] = "core_rich_text" features[menu_custom][] = "main-menu" features[menu_links][] = "main-menu:<front>" features[user_permission][] = "access content" features[user_permission][] = "use text format core_rich_text" features[variable][] = "admin_toolbar" features[variable][] = "date_format_long" ...
  • 87. A feature can have a .make Drush Make operates recursively
  • 88.
  • 89.
  • 90. api = 2 core = 7.x ; Modules ===================================================================== projects[colorbox][subdir] = contrib projects[colorbox][version] = 1.0-beta4 projects[insert][subdir] = contrib projects[insert][version] = 1.1 ; Libraries =================================================================== libraries[colorbox_library][download][type] = "get" libraries[colorbox_library][download][url] = "http://colorpowered.com/colorbox/ libraries[colorbox_library][directory_name] = "colorbox" libraries[colorbox_library][destination] = "libraries" feature_core.mak A feature can specify where to find its own dependencies
  • 91. How to download your projects from any custom
  • 92. $ cat starter-profile/starter.make api = 2 core = 7.x ; Build Kit =================================================================== includes[] = http://drupalcode.org/project/buildkit.git/blob_plain/refs/heads/7.x ; Modules ===================================================================== projects[libraries][subdir] = contrib projects[libraries][version] = 1.0 ; Features ==================================================================== projects[feature_core][type] = module projects[feature_core][subdir] = features projects[feature_core][download][type] = "git" projects[feature_core][download][url] = git.nuvole.org:/var/git/feature_core.git ; Themes ====================================================================== projects[twist][type] = theme projects[twist][download][type] = git projects[twist][download][url] = git.nuvole.org:/var/git/twist.git
  • 93. Introducing Feature Keep features, themes, makefiles, etc... organized.
  • 94.
  • 95.
  • 96.
  • 97.
  • 98. $ cat starter-profile/starter.make api = 2 core = 7.x ; Build Kit =================================================================== includes[] = http://drupalcode.org/project/buildkit.git/blob_plain/refs/heads/7.x- ; Modules ===================================================================== projects[libraries][subdir] = contrib projects[libraries][version] = 1.0 ; Features ==================================================================== projects[feature_core][subdir] = features projects[feature_core][location] = http://fserver.nuvole.org/fserver ; Themes ====================================================================== projects[twist][type] = theme projects[twist][location] = http://fserver.nuvole.org/fserver
  • 99. Feature Server and Drush $ # Drush goodies $ drush | grep fserver fserver-distro Update packaging for a distribution. fserver-package Update packaging for a project. fserver-status Determine the packaging status of a project. $ # Build releases for feature_news based on GIT tags and branches $ drush fserver-package feature_news $ # Check releases status $ drush fserver-status Method Project New tags git Feature News 7.x-1.0 git Feature Pages 7.x-1.0 ...
  • 101. Don't depend on trust Automatically test every component
  • 102. Meet Continuous Use Hudson/Jenkins to automatically test: 1. Makefile 2. Installation 3. Configuration
  • 103.
  • 104. Building a CI Job ‣ Create a job for testing your site ‣ Triggered: ‣ Manually ‣ Scheduled ‣ By events (git push or other jobs) ‣ A job can consist of ant scripts or simple shell commands (including drush)
  • 105.
  • 106. Test #1: Makefile ‣ Clone your code from git ‣ Run drush make ‣ Test that the profile is downloaded ‣ Test that modules are placed in the expected folders
  • 107. Test #1: Shell commands ‣ drush -y --pipe make distro.make ‣ test -d profiles/myproject ‣ test -d profiles/myproject/modules/contrib ‣ test -d profiles/myproject/modules/custom ‣ test -d profiles/myproject/modules/features
  • 108.
  • 109. Test #2: Installation ‣ Triggered by successful completion of Test #1 ‣ Run drush site-install: drush -y site-install ... myproject ‣ Expect successful completion
  • 110.
  • 111. Test #3: Configuration ‣ Triggered by successful completion of Test #2 ‣ Relies on simpletest ‣ Run drush test-run ‣ Expect successful completion
  • 112.
  • 113. Thank You. More on Code-Driven Development http://nuvole.org/blog http://nuvole.org/trainings

Notas do Editor

  1. \n
  2. \n
  3. \n
  4. \n
  5. \n
  6. \n
  7. \n
  8. \n
  9. \n
  10. \n
  11. [Each of them lives in separate domains and can be shipped in different forms]\n
  12. [Each of them lives in separate domains and can be shipped in different forms]\n
  13. [Each of them lives in separate domains and can be shipped in different forms]\n
  14. [Each of them lives in separate domains and can be shipped in different forms]\n
  15. [Each of them lives in separate domains and can be shipped in different forms]\n
  16. [Each of them lives in separate domains and can be shipped in different forms]\n
  17. [Each of them lives in separate domains and can be shipped in different forms]\n
  18. [Each of them lives in separate domains and can be shipped in different forms]\n
  19. [Each of them lives in separate domains and can be shipped in different forms]\n
  20. [Each of them lives in separate domains and can be shipped in different forms]\n
  21. [Each of them lives in separate domains and can be shipped in different forms]\n
  22. [Each of them lives in separate domains and can be shipped in different forms]\n
  23. [Each of them lives in separate domains and can be shipped in different forms]\n
  24. [Each of them lives in separate domains and can be shipped in different forms]\n
  25. [Each of them lives in separate domains and can be shipped in different forms]\n
  26. [Each of them lives in separate domains and can be shipped in different forms]\n
  27. \n
  28. \n
  29. \n
  30. Clear upgrade path [easy to make assumptions on configuration state]\nClean installation procedure [produce a &amp;#x201C;vanilla&amp;#x201D; database]\n
  31. Clear upgrade path [easy to make assumptions on configuration state]\nClean installation procedure [produce a &amp;#x201C;vanilla&amp;#x201D; database]\n
  32. \n
  33. Illustrate make file: core directive, drupal version and core patches.\nthis only downloads drupal core, where is our distribution?\n
  34. \n
  35. Illustrate make file: core directive, drupal version and core patches.\nthis only downloads drupal core, where is our distribution?\n
  36. \n
  37. \n
  38. Illustrate make file: core directive, drupal version and core patches.\nthis only downloads drupal core, where is our distribution?\n
  39. \n
  40. \n
  41. \n
  42. \n
  43. \n
  44. Illustrate make file: core directive, drupal version and core patches.\nthis only downloads drupal core, where is our distribution?\n
  45. \n
  46. \n
  47. Illustrate make file: core directive, drupal version and core patches.\nthis only downloads drupal core, where is our distribution?\n
  48. \n
  49. \n
  50. \n
  51. \n
  52. \n
  53. \n
  54. \n
  55. \n
  56. \n
  57. \n
  58. \n
  59. \n
  60. \n
  61. \n
  62. \n
  63. \n
  64. \n
  65. \n
  66. \n
  67. \n
  68. \n
  69. Clear upgrade path [easy to make assumptions on configuration state]\nClean installation procedure [produce a &amp;#x201C;vanilla&amp;#x201D; database]\n
  70. \n
  71. \n
  72. \n
  73. \n
  74. \n
  75. \n
  76. \n
  77. \n
  78. \n
  79. \n
  80. \n
  81. \n
  82. \n
  83. \n
  84. \n
  85. \n
  86. \n
  87. \n
  88. \n
  89. \n
  90. \n
  91. \n
  92. \n
  93. \n
  94. \n
  95. \n
  96. \n
  97. \n
  98. Clear upgrade path [easy to make assumptions on configuration state]\nClean installation procedure [produce a &amp;#x201C;vanilla&amp;#x201D; database]\n
  99. \n
  100. \n
  101. \n
  102. \n
  103. \n
  104. \n
  105. \n
  106. \n
  107. \n
  108. \n
  109. \n
  110. \n
  111. \n
  112. \n
  113. \n
  114. \n
  115. \n
  116. \n
  117. \n
  118. \n
  119. \n
  120. \n
  121. \n
  122. \n
  123. \n
  124. \n
  125. \n
  126. \n
  127. \n
  128. \n
  129. \n
  130. \n
  131. \n
  132. \n
  133. \n
  134. \n
  135. \n
  136. \n
  137. \n
  138. \n
  139. \n
  140. \n
  141. \n
  142. \n
  143. \n