SlideShare a Scribd company logo
Recipes for Drupal distributions



       Lakshmi Narasimhan
           @lakshminp
Outline of this talk
Chapter 0 – Intro
Chapter 1 – Anotomy of a distribution
Chapter 2 – So, one fine saturday afternoon...
Chapter 3– Business models
Chapter 4 – Now what?
Questions
Chapter 0

   Intro
About me
Zero web programming
experience
until 2 years ago

Initially a djangonaut

started tinkering with
drupal in 2010

Haven't looked back
The drupal model of a site
It's a cms
A Framework?
Platform...
er... Product.
So, I want to create a blog
api                                       Daily, weekly and
                        wysiwyg           monthly archives
           Tag cloud
                              CAPTCHA
SEO
                            Recent comments, recent posts etc.
      sitemap

                        Media management
  search                                             Backup'n
                                        Wp import    restore
                  polling
Any drupal solution which
       does this...
Any drupal solution which
       does this...




                      Out of the box?
Enter distributions.
Custom editions of drupal
Custom editions of drupal

         Tuned to a desired set of features
Custom editions of drupal

          Tuned to a desired set of features




Does one job well
Custom editions of drupal

           Tuned to a desired set of features




Does one job well
           ...usually.
wiki
           blog
                  Online shop

  videos
                       Q&A

                   Social
                  network
Distributions can even be non-functional



pressflow
                            mongodb
Chapter 1

Anatomy of Drupal
   distributions
Distros started life in Drupal 5.

              Gained good momentum in 6.


Improved in drupal 7.
Each distro is wrapped in a profile

         Profile similar to a module

           .info, .profile, .install, .make.
.info

basic info about
your distro.

your module and
theme dependencies.

.install
perform upgrades and
install tasks
.profile

site specific
installation

Ex:
1. adding a
vocabulary
2. sample content
3. adding new users.
configurations to be present
in site before starting to
use it.
core modules already imported
by drupal.

contrib modules.
Ex:ctools, pathauto.
best practice: put under
"contrib"

custom modules.
your own modules, but not
under drupal.org(yet!)
best practice: put under
"custom"
.make file contents:(contd)
Themes, both custom and
contrib.

Libraries.
Any other dependecies for
your module.
Ex:CKEditor js library for
wysiwyg module.
projects[ctools][subdir] = "contrib"
projects[ctools][version] = "1.0-rc1"
...

projects[save_as_draft][type] = module
projects[save_as_draft][download][type] = "git"
projects[save_as_draft][subdir] = "custom"
projects[save_as_draft][download][url] =
git://github.com/druplug/save_as_draft.git
...

; Themes
projects[blogbuzz][subdir] = "contrib"
projects[blogbuzz][version] = "1.0-rc2"
...

libraries[ckeditor][download][type] = "get"
libraries[ckeditor][download][url] =
"http://ckeditor/download/source"
libraries[ckeditor][download][directory_name] =
 "ckeditor"
libraries[ckeditor][download][destination] =
Features. Best way to package drupal
           distributions.
Features. Best way to package drupal
           distributions.


 Modular piece of functionality for a distro
Features. Best way to package drupal
           distributions.


 Modular piece of functionality for a distro


All configuration is
   stored in code
      http://bit.ly/dev-staging-workflow
Some drupal entities exported by
feature

  content types
  views
  nodes & taxonomies(using uuid)
  variables and
settings(strongarm)
  user permissions
  text input formats
  <insert your fav. here>
Writing your own feature

features work on a set of hooks.

Each hook does a specific task
towards building an exportable
feature.
Feature hooks

hook_features_api()

defines the entity we are going
to export. Ex: views.
Feature hooks

hook_features_export()

defines the contents of the
entity we are going to export.
Ex: the widget type and display
options if we are exporting a
field.

Related dependencies.
Feature hooks

hook_features_export_render()

renders the exported part as
code.
function
bloggio_features_filter_default_formats() {
  $formats = array();

    // Exported format: CKEditor
    $formats['ckeditor'] = array(
      'format' => 'ckeditor',
      'name' => 'CKEditor',
      'cache' => '1',
      'status' => '1',
      'weight' => '0',
      'filters' => array(),
    );

    return $formats;
}
Drush make
Drush make


             One step makefile
              for your distro
Drush make


                One step makefile
                 for your distro
Stub makefile
Drush make


                      One step makefile
                       for your distro
Stub makefile
                profile makefile
Contrib stuff + features + drush make =
             distributions
Missing ingradient
testing
Things break.
Things break.



                Core upgrade?
Things break.



                        Core upgrade?

   New version of a module
Simpletest.
simpletest

modelled after simpletest php
library.
simpletest

modelled after simpletest php
library.

Part of the core in Drupal 7.
simpletest

modelled after simpletest php
library.

Part of the core in Drupal 7.

can be automated from
commandline(drush).
simpletest

modelled after simpletest php
library.

Part of the core in Drupal 7.

can be automated from
commandline(drush).

Which begs the question....
How to automate all this?
How to automate all this?

Continuous integration
Drupal + CI

hook up your version control
with Jenkins.
(in case of github, a post
receive hook.)
Drupal + CI

hook up your version control
with Jenkins.
(in case of github, a post
receive hook.)

Jenkins runs the simpletest for
your distro
Drupal + CI

hook up your version control
with Jenkins.
(in case of github, a post
receive hook.)

Jenkins runs the simpletest for
your distro

you get a report of some sort.
Drupal + CI

download this book.
(free!).
(http://www.wakaleo.com/b
ooks/jenkins-the-
definitive-guide)
Drupal + CI

run-tests.sh is your
friend.

Emits junit-compatible
XML, plays well with
Jenkins.
Other testing ideas

Coder module
(http://drupal.org/project/coder
)

Selenium
(http://drupal.org/project/selen
ium)
Site ideas + hard testing +
distributions = reliable, reusable, zero
               config apps.
Chapter 2

So, one fine saturday
    afternoon...
We started an idea called
Druplug.
We started an idea called
Druplug.

Wordpress is a platform super
optimized for blogs.
We started an idea called
Druplug.

Wordpress is a platform super
optimized for blogs.

Drupal is a
CMS/framework/platform which can
be super optimized for wiki,
blogs, forums, Q&A sites,<insert
your own site pattern here>
We started an idea called
Druplug.

Wordpress is a platform super
optimized for blogs.

Drupal is a
CMS/framework/platform which can
be super optimized for wiki,
blogs, forums, Q&A sites,<insert
your own site pattern here>

Some awesome distros already out
there.
We want to make them better.
We want to make them better.

         Portmanteau of Drupal and
                pluggable.
We want to make them better.

         Portmanteau of Drupal and
                pluggable.


              Conquering the world, one
                distribution at a time.
We thrive on a set of visions
We thrive on a set of visions
Make superb distributions
We thrive on a set of visions
Make superb distributions
                       Test, test, test.
We thrive on a set of visions
Make superb distributions
                       Test, test, test.


 Stick to the Drupal way.
Don't hack core.
 Collaboration rather than competition.

        Follow module writing guidelines.
            http://bit.ly/module-manifesto
Chapter 3

Business models
How to make money?
The open source way

Give away distributions for
free.
The open source way

Give away distributions for
free.

Build an ecosystem around it.
The open source way

Give away distributions for
free.

Build an ecosystem around it.

Themes, support, customization
etc.
Examples of customization

wiki with a badge system

multiuser blog with affiliate
management

Emerging pattern:
<base part> + <custom fitting>
There are other models too.
bleeding edge -> open source and
free

Tested and stable -> $$
Offer distributions as SaaS.
Chapter 4

  Now what?
Go and build distributions.
Fork us on github.




            Github.com/druplug
Report bugs.
Spread the word.
Spread the word.

Follow or development in twitter.
@druplug




Spread the word.

Follow or development in twitter.
Slides will be made
available online @ lanyrd
and slideshare in a while.
Thank you for having me.
?
Image credits

http://www.flickr.com/photos/origamiancy/3595747075/
http://www.flickr.com/photos/yandle/3347966806/
http://www.flickr.com/photos/kazk/198640938/
http://www.flickr.com/photos/kinghuang/3226925608/
http://www.flickr.com/photos/alexkerhead/3495304775/
http://www.flickr.com/photos/jennycu/3602064857/
http://www.flickr.com/photos/colinkinner/2200500024/
http://www.flickr.com/photos/vfsdigitaldesign/5396011779/
http://www.flickr.com/photos/vfsdigitaldesign/5396638970/
http://www.flickr.com/photos/dnwallace/4344120241/
http://www.flickr.com/photos/joeshlabotnik/305410323/
http://www.flickr.com/photos/jetalone/1787639152/
http://www.flickr.com/photos/evergreenkamal/384258822/
http://www.flickr.com/photos/restlessglobetrotter/448362507/
http://www.flickr.com/photos/blyzz/4534655474/
http://www.flickr.com/photos/askdavetaylor/4261149346/
http://www.flickr.com/photos/myfuturedotcom/6053500178/
http://www.flickr.com/photos/lizadaly/2945260782/
http://www.flickr.com/photos/enerva/4302079406/
http://www.flickr.com/photos/thales/5249512668/
http://www.flickr.com/photos/roblee/2697052/
http://www.flickr.com/photos/39747297@N05/5229733647/
http://www.flickr.com/photos/stopbits/5422661273/
http://www.flickr.com/photos/54400117@N03/5069108088/
http://www.flickr.com/photos/carbonnyc/365132202/
http://www.flickr.com/photos/vizzzual-dot-com/2232185965/
http://www.flickr.com/photos/hulagway/5162234765/
http://www.flickr.com/photos/eusebius/4486572552/
Colophon:
made using Open office 3.2.1 on an
Ubuntu.


Fonts used:
Purisa
Franchise
Inconsolata

More Related Content

PPTX
Maven
PPTX
PDF
Writing Android Libraries
PPTX
Drupal8 theming
PPTX
Drupal Migration
PPT
Create Website In Indian Languages using drupal
PPTX
8 Web Practices for Drupal
PPTX
Building Archivable Websites
Maven
Writing Android Libraries
Drupal8 theming
Drupal Migration
Create Website In Indian Languages using drupal
8 Web Practices for Drupal
Building Archivable Websites

Viewers also liked (13)

PDF
Drush 5.0 (DrupalCamp LA 2012) - Chris Charlton
PDF
GeorgiaGov's move to Drupal - presentation by Nikhil Deshpande @nikofthehill
PDF
Using Drupal Features in B-Translator
PDF
Migrate
PDF
Staging Drupal 8 31 09 1 3
PDF
Moving In: how to port your content from * to Drupal
PDF
Moving Drupal to the Cloud
PDF
Drupal in the Cloud with Windows Azure
PPTX
Data migration to Drupal using the migrate module
PPT
Migraine Drupal - syncing your staging and live sites
ODP
Content Staging in Drupal 8
PDF
Managing Translation Workflows in Drupal 7
PPTX
Migration from Legacy CMS to Drupal
Drush 5.0 (DrupalCamp LA 2012) - Chris Charlton
GeorgiaGov's move to Drupal - presentation by Nikhil Deshpande @nikofthehill
Using Drupal Features in B-Translator
Migrate
Staging Drupal 8 31 09 1 3
Moving In: how to port your content from * to Drupal
Moving Drupal to the Cloud
Drupal in the Cloud with Windows Azure
Data migration to Drupal using the migrate module
Migraine Drupal - syncing your staging and live sites
Content Staging in Drupal 8
Managing Translation Workflows in Drupal 7
Migration from Legacy CMS to Drupal
Ad

Similar to Recipes for Drupal distributions (20)

PDF
IBM Drupal Users Group Discussion on Managing and Deploying Configuration
ODP
Drupal distributions - how to build them
PDF
Features everywhere
ODP
Drupal distribution
PDF
Building and Maintaining a Distribution in Drupal 7 with Features
PPTX
Lazy Coder Camp Edition 1
PDF
Open event (show&tell april 2016)
PDF
Sergei Stryukov.Drush.Why it should be used.DrupalCamp Kyiv 2011
PDF
Drupal For Designers 1st Edition Dani Nordin
PDF
Introduction to Drupal, Wayne Eaker, Nov 11, 09
PDF
Lean Drupal Repositories with Composer and Drush
PDF
Pilot Tech Talk #10 — Practical automation by Kamil Cholewiński
KEY
Drupal in 30 Minutes
PPT
Drush. Why should it be used?
PPTX
Drupal 8 Modules
PDF
Drupal 8 Configuration Management for you and your team
KEY
Intro to Features Module on Drupal
PDF
Drupal Presentation for CapitalCamp 2011: Features Driven Development
PPT
An introduction to maven gradle and sbt
IBM Drupal Users Group Discussion on Managing and Deploying Configuration
Drupal distributions - how to build them
Features everywhere
Drupal distribution
Building and Maintaining a Distribution in Drupal 7 with Features
Lazy Coder Camp Edition 1
Open event (show&tell april 2016)
Sergei Stryukov.Drush.Why it should be used.DrupalCamp Kyiv 2011
Drupal For Designers 1st Edition Dani Nordin
Introduction to Drupal, Wayne Eaker, Nov 11, 09
Lean Drupal Repositories with Composer and Drush
Pilot Tech Talk #10 — Practical automation by Kamil Cholewiński
Drupal in 30 Minutes
Drush. Why should it be used?
Drupal 8 Modules
Drupal 8 Configuration Management for you and your team
Intro to Features Module on Drupal
Drupal Presentation for CapitalCamp 2011: Features Driven Development
An introduction to maven gradle and sbt
Ad

Recently uploaded (20)

PDF
CIFDAQ's Market Insight: SEC Turns Pro Crypto
PDF
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
PDF
Agricultural_Statistics_at_a_Glance_2022_0.pdf
PDF
Chapter 3 Spatial Domain Image Processing.pdf
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
PPTX
Understanding_Digital_Forensics_Presentation.pptx
PDF
Per capita expenditure prediction using model stacking based on satellite ima...
PDF
Encapsulation theory and applications.pdf
PDF
Shreyas Phanse Resume: Experienced Backend Engineer | Java • Spring Boot • Ka...
PPTX
Cloud computing and distributed systems.
PPTX
PA Analog/Digital System: The Backbone of Modern Surveillance and Communication
PDF
Encapsulation_ Review paper, used for researhc scholars
PDF
Modernizing your data center with Dell and AMD
PDF
Electronic commerce courselecture one. Pdf
PDF
Machine learning based COVID-19 study performance prediction
PPT
“AI and Expert System Decision Support & Business Intelligence Systems”
PPTX
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
PPT
Teaching material agriculture food technology
PDF
Mobile App Security Testing_ A Comprehensive Guide.pdf
CIFDAQ's Market Insight: SEC Turns Pro Crypto
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
Agricultural_Statistics_at_a_Glance_2022_0.pdf
Chapter 3 Spatial Domain Image Processing.pdf
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
Understanding_Digital_Forensics_Presentation.pptx
Per capita expenditure prediction using model stacking based on satellite ima...
Encapsulation theory and applications.pdf
Shreyas Phanse Resume: Experienced Backend Engineer | Java • Spring Boot • Ka...
Cloud computing and distributed systems.
PA Analog/Digital System: The Backbone of Modern Surveillance and Communication
Encapsulation_ Review paper, used for researhc scholars
Modernizing your data center with Dell and AMD
Electronic commerce courselecture one. Pdf
Machine learning based COVID-19 study performance prediction
“AI and Expert System Decision Support & Business Intelligence Systems”
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
Teaching material agriculture food technology
Mobile App Security Testing_ A Comprehensive Guide.pdf

Recipes for Drupal distributions