SlideShare a Scribd company logo
1 of 27
Features + Installation Profiles
          February 24, 2012
David Watson
Rensselaer Polytechnic Institute
  Web Developer
   Experimental Media and
   Performing Arts Center (EMPAC)
  Adjunct Professor
   Web Systems Development
Drupal Consultant
  ~3 years in the community
  Specialized Generalist
Best Practices
Revision Control
Dev/Test/Prod workflow
One-click Deployment
Revision Control
Easier collaboration with conflict handling
Change history
Ability to revert
Easier to merge in new code
Best Practice: Use it.
Reality: This is hard to do for sites!
Dev/Test/Prod
Workstations check out code from Dev server
Patches are reviewed, committed to Dev
  Possibly running Jenkins/Hudson
Release candidates are pushed to Test/Staging
 environment
Final release pushed to Production along with
  any staged content
Dev/Test/Prod
Best Practice: Use a workflow like this to ensure
 that only production-quality code is running on
 production servers.
Reality: This is hard to do for sites!
One-click Deployment
End-users shouldn't have to configure their sites,
 that's what we're here for!
Best practice: Let the installer do all of the
 heavy lifting, providing sane defaults site-wide
Reality: ...You get the idea.
Drupal Database
Data
  Nodes
  Fields
  ...
Configuration
  Content Types
  Field Info
  Rules
  Views Settings
  Variables
Drupal Deployment Challenges
How do we deploy our Drupal instances from one
 box to another?
  Moving the database?
  Manually duplicating configuration changes?
Drupal Deployment Challenges
How to we use revision control with Drupal?
  Works great with modules, but what about our
   configuration?
  Add SQL dumps to the repository?
Drupal Deployment Challenges
How do we achieve one-click deployment?
  Modules are handled through dependencies...
  What about our configuration?
  Write some sort of custom installation script?
THE Drupal Deployment Challenge
All of these problems can be reduced to one:
  configuration that lives in the database instead
  of the code
How do we move as much configuration into
 code as possible, and load it when the site is
 first installed?
The Answer
Installation Profiles provide a means of one-
  click (or even fully automated!) deployment for
  modules and themes
Features provide a means of exporting
 configuration to code as feature modules, used
 to satisfy a specific use case
Installation Profiles
Core functionality
Allows users to perform one-time setup tasks
  during installation, based on presets
  Install and enable modules/themes
  Run custom code
Can be used to package modules and themes
Possible to select through the UI and through
 drush site-install!
Anatomy of an Install Profile
Exist in profiles/PROFILENAME
Within each...
  PROFILENAME.info – metadata/dependencies
  PROFILENAME.install – installation-specific hooks
  PROFILENAME.profile – other hooks
  modules/ - modules packaged with this profile
  themes/ - themes packaged in the profile
  libraries/ - Libraries API looks here for libs
Features
Contrib module that allows for exporting existing
 configuration as modules
First, some terminology...
Features Terminology
Features refers to the Features module
Features packages components together - bits
 of configuration for individual modules, like
 individual views
These components are taken from modules that
 integrate with Features, usually by providing
 CTools exportables
The feature modules that Features creates
 contain the components that you select
Why Features?
Feature modules can be committed to version
 control
Code is more portable than database between
 Dev/Test/Prod
Overrides to feature modules can be reverted to
 their default state
Hooks can be added to the module later
 (remember, feature modules are just modules!)
Commonly Used
Boxes – What custom blocks should've been
Views – All views are exportable!
Rules – Also exportable. Very handy when
 working w/ Drupal Commerce!
Strongarm – Makes the variables table
 exportable
UUID – Paired with other modules to provide
 unique identifiers for content that won't change
 depending on the order they're installed
Special Cases
Not everything is exportable
  Make it exportable, and contribute a patch!
  Last resort: hook_(un)install()
Content-based Configuration?
  Boxes module for blocks
  Defaultcontent for nodes
  Drupal Commerce7 in progress...
Putting it all together
Features provides the means of separating
 configuration from content
Install Profiles allow for packaging of modules
  (contrib/devel/features/custom) and themes,
  while offering one-click deployment
Features Workflow
Perform configuration in the UI
Export config as a feature and move to
 profiles/PROFILENAME/modules/features/
Implement any necessary hooks in the
  feature's .module file
Make sure the install profile depends on the new
 feature
Reinstall the site and test
Site Development Workflow
Create an install profile
Download/write contrib/custom modules
  Required libraries should go in the profile's libraries/
   directory
Create core feature for site-wide settings, add to
 profile's .info
Repeat feature creation for all other functionality
  Remember, features are modules too; you can
   depend on other features!
Site Theming Workflow
Create an install profile
Download/create (sub)themes in
 profiles/PROFILENAME/themes
In .install file...
   theme_enable(THEMENAME);
   variable_set('theme_default', THEMENAME);
*hack hack hack*
Example
Aqueduct Install Profile
Heavily commented
Uses Features to export configuration settings
Play, experiment, use as a base, send
  suggestions/patches for improvement, enjoy!
Questions?
Get in Touch!
d.o – davidwatson
e – dmw@davidwatson.name
t - @caughtexception
in – linkedin.com/in/davidmwatson

More Related Content

What's hot

Vsx5 getting started_guide_en
Vsx5 getting started_guide_enVsx5 getting started_guide_en
Vsx5 getting started_guide_enGeraldo Camargo
 
Securely connecting to apps over the internet using rds
Securely connecting to apps over the internet using rdsSecurely connecting to apps over the internet using rds
Securely connecting to apps over the internet using rdsConcentrated Technology
 
eXo Platform SEA - Play Framework Introduction
eXo Platform SEA - Play Framework IntroductioneXo Platform SEA - Play Framework Introduction
eXo Platform SEA - Play Framework Introductionvstorm83
 
Improve Your IBM Domino Designer Experience
Improve Your IBM Domino Designer ExperienceImprove Your IBM Domino Designer Experience
Improve Your IBM Domino Designer Experiencepanagenda
 
Eclipse tools for deployment to was liberty profile in Bluemix
Eclipse tools for deployment to was liberty profile in BluemixEclipse tools for deployment to was liberty profile in Bluemix
Eclipse tools for deployment to was liberty profile in BluemixEclipse Day India
 
Core java environment setup and details
Core java environment setup and detailsCore java environment setup and details
Core java environment setup and detailse-visionlabs
 
websphere commerce server admin configuration
websphere commerce server admin configuration websphere commerce server admin configuration
websphere commerce server admin configuration Laxmi Kanth Kshatriya
 
Lab 6) package and deploy a j2 ee application
Lab 6) package and deploy a j2 ee applicationLab 6) package and deploy a j2 ee application
Lab 6) package and deploy a j2 ee applicationtechbed
 
Connect 2014 AD209 - Making Your Development Team More Productive With IBM Do...
Connect 2014 AD209 - Making Your Development Team More Productive With IBM Do...Connect 2014 AD209 - Making Your Development Team More Productive With IBM Do...
Connect 2014 AD209 - Making Your Development Team More Productive With IBM Do...marjoramg
 
SharePoint 2010 Training Session 3
SharePoint 2010 Training Session 3SharePoint 2010 Training Session 3
SharePoint 2010 Training Session 3Usman Zafar Malik
 
VAST 7.5 and Beyond
VAST 7.5 and BeyondVAST 7.5 and Beyond
VAST 7.5 and BeyondESUG
 
WebSphere Liberty and IBM Containers: The Perfect Combination for Java Micros...
WebSphere Liberty and IBM Containers: The Perfect Combination for Java Micros...WebSphere Liberty and IBM Containers: The Perfect Combination for Java Micros...
WebSphere Liberty and IBM Containers: The Perfect Combination for Java Micros...David Currie
 
XPages: No Experience Needed
XPages: No Experience NeededXPages: No Experience Needed
XPages: No Experience NeededKathy Brown
 
How to Containerize WebSphere Application Server Traditional, and Why You Mig...
How to Containerize WebSphere Application Server Traditional, and Why You Mig...How to Containerize WebSphere Application Server Traditional, and Why You Mig...
How to Containerize WebSphere Application Server Traditional, and Why You Mig...David Currie
 
Connect 2014 SHOW102: XPages Still No Experience Necessary
Connect 2014 SHOW102: XPages Still No Experience NecessaryConnect 2014 SHOW102: XPages Still No Experience Necessary
Connect 2014 SHOW102: XPages Still No Experience Necessarypanagenda
 

What's hot (17)

Vsx5 getting started_guide_en
Vsx5 getting started_guide_enVsx5 getting started_guide_en
Vsx5 getting started_guide_en
 
Securely connecting to apps over the internet using rds
Securely connecting to apps over the internet using rdsSecurely connecting to apps over the internet using rds
Securely connecting to apps over the internet using rds
 
eXo Platform SEA - Play Framework Introduction
eXo Platform SEA - Play Framework IntroductioneXo Platform SEA - Play Framework Introduction
eXo Platform SEA - Play Framework Introduction
 
Improve Your IBM Domino Designer Experience
Improve Your IBM Domino Designer ExperienceImprove Your IBM Domino Designer Experience
Improve Your IBM Domino Designer Experience
 
Sonar qube
Sonar qubeSonar qube
Sonar qube
 
Eclipse tools for deployment to was liberty profile in Bluemix
Eclipse tools for deployment to was liberty profile in BluemixEclipse tools for deployment to was liberty profile in Bluemix
Eclipse tools for deployment to was liberty profile in Bluemix
 
Core java environment setup and details
Core java environment setup and detailsCore java environment setup and details
Core java environment setup and details
 
websphere commerce server admin configuration
websphere commerce server admin configuration websphere commerce server admin configuration
websphere commerce server admin configuration
 
Lab 6) package and deploy a j2 ee application
Lab 6) package and deploy a j2 ee applicationLab 6) package and deploy a j2 ee application
Lab 6) package and deploy a j2 ee application
 
Connect 2014 AD209 - Making Your Development Team More Productive With IBM Do...
Connect 2014 AD209 - Making Your Development Team More Productive With IBM Do...Connect 2014 AD209 - Making Your Development Team More Productive With IBM Do...
Connect 2014 AD209 - Making Your Development Team More Productive With IBM Do...
 
Workflow for XPages
Workflow for XPagesWorkflow for XPages
Workflow for XPages
 
SharePoint 2010 Training Session 3
SharePoint 2010 Training Session 3SharePoint 2010 Training Session 3
SharePoint 2010 Training Session 3
 
VAST 7.5 and Beyond
VAST 7.5 and BeyondVAST 7.5 and Beyond
VAST 7.5 and Beyond
 
WebSphere Liberty and IBM Containers: The Perfect Combination for Java Micros...
WebSphere Liberty and IBM Containers: The Perfect Combination for Java Micros...WebSphere Liberty and IBM Containers: The Perfect Combination for Java Micros...
WebSphere Liberty and IBM Containers: The Perfect Combination for Java Micros...
 
XPages: No Experience Needed
XPages: No Experience NeededXPages: No Experience Needed
XPages: No Experience Needed
 
How to Containerize WebSphere Application Server Traditional, and Why You Mig...
How to Containerize WebSphere Application Server Traditional, and Why You Mig...How to Containerize WebSphere Application Server Traditional, and Why You Mig...
How to Containerize WebSphere Application Server Traditional, and Why You Mig...
 
Connect 2014 SHOW102: XPages Still No Experience Necessary
Connect 2014 SHOW102: XPages Still No Experience NecessaryConnect 2014 SHOW102: XPages Still No Experience Necessary
Connect 2014 SHOW102: XPages Still No Experience Necessary
 

Viewers also liked

SoCal Newsletter September 2012
SoCal Newsletter September 2012 SoCal Newsletter September 2012
SoCal Newsletter September 2012 socalMRA
 
VNP Resume
VNP ResumeVNP Resume
VNP Resumesnpar
 
CFU Business Plan
CFU Business PlanCFU Business Plan
CFU Business Planhbilletter
 
Undine: Turnkey Drupal Development Environments
Undine: Turnkey Drupal Development EnvironmentsUndine: Turnkey Drupal Development Environments
Undine: Turnkey Drupal Development EnvironmentsDavid Watson
 
April 2012 SoCal Newsletter
April 2012 SoCal NewsletterApril 2012 SoCal Newsletter
April 2012 SoCal NewslettersocalMRA
 

Viewers also liked (6)

SoCal Newsletter September 2012
SoCal Newsletter September 2012 SoCal Newsletter September 2012
SoCal Newsletter September 2012
 
VNP Resume
VNP ResumeVNP Resume
VNP Resume
 
CFU Business Plan
CFU Business PlanCFU Business Plan
CFU Business Plan
 
Undine: Turnkey Drupal Development Environments
Undine: Turnkey Drupal Development EnvironmentsUndine: Turnkey Drupal Development Environments
Undine: Turnkey Drupal Development Environments
 
Intro to Drush
Intro to DrushIntro to Drush
Intro to Drush
 
April 2012 SoCal Newsletter
April 2012 SoCal NewsletterApril 2012 SoCal Newsletter
April 2012 SoCal Newsletter
 

Similar to Features & Installation Profiles

Intro to Features Module on Drupal
Intro to Features Module on DrupalIntro to Features Module on Drupal
Intro to Features Module on DrupalAidan Foster
 
Strategies and Tips for Building Enterprise Drupal Applications - PNWDS 2013
Strategies and Tips for Building Enterprise Drupal Applications - PNWDS 2013Strategies and Tips for Building Enterprise Drupal Applications - PNWDS 2013
Strategies and Tips for Building Enterprise Drupal Applications - PNWDS 2013Mack Hardy
 
Features everywhere
Features everywhere Features everywhere
Features everywhere Mediacurrent
 
DDAY2014 - Features per Drupal 8
DDAY2014 - Features per Drupal 8DDAY2014 - Features per Drupal 8
DDAY2014 - Features per Drupal 8DrupalDay
 
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
 
Features and Context Overview
Features and Context OverviewFeatures and Context Overview
Features and Context Overviewbrentratliff
 
Understanding and extending p2 for fun and profit
Understanding and extending p2 for fun and profitUnderstanding and extending p2 for fun and profit
Understanding and extending p2 for fun and profitPascal Rapicault
 
Drupal Workflow Concepts
Drupal Workflow ConceptsDrupal Workflow Concepts
Drupal Workflow Conceptscgmonroe
 
Migraine Drupal - syncing your staging and live sites
Migraine Drupal - syncing your staging and live sitesMigraine Drupal - syncing your staging and live sites
Migraine Drupal - syncing your staging and live sitesdrupalindia
 
Beginner's guide to drupal
Beginner's guide to drupalBeginner's guide to drupal
Beginner's guide to drupalmayank.grd
 
Drupal distributions - how to build them
Drupal distributions - how to build themDrupal distributions - how to build them
Drupal distributions - how to build themDick Olsson
 
Building and Deployment of Drupal sites with Features and Context
Building and Deployment of Drupal sites with Features and ContextBuilding and Deployment of Drupal sites with Features and Context
Building and Deployment of Drupal sites with Features and ContextSvilen Sabev
 
Best practices for share point solution deployment
Best practices for share point solution deploymentBest practices for share point solution deployment
Best practices for share point solution deploymentSalaudeen Rajack
 
PHP North-East - Automated Deployment
PHP North-East - Automated DeploymentPHP North-East - Automated Deployment
PHP North-East - Automated DeploymentMichael Peacock
 
Automated Deployment
Automated DeploymentAutomated Deployment
Automated Deploymentphpne
 
IBM Drupal Users Group Discussion on Managing and Deploying Configuration
IBM Drupal Users Group Discussion on Managing and Deploying ConfigurationIBM Drupal Users Group Discussion on Managing and Deploying Configuration
IBM Drupal Users Group Discussion on Managing and Deploying ConfigurationDevelopment Seed
 
Extend Eclipse p2 framework capabilities: Add your custom installation steps
Extend Eclipse p2 framework capabilities: Add your custom installation stepsExtend Eclipse p2 framework capabilities: Add your custom installation steps
Extend Eclipse p2 framework capabilities: Add your custom installation stepsDragos_Mihailescu
 
CloudStack templates with OpenVM
CloudStack templates with OpenVMCloudStack templates with OpenVM
CloudStack templates with OpenVMShapeBlue
 
Puppet | Custom Modules & Using the Forge
Puppet | Custom Modules & Using the ForgePuppet | Custom Modules & Using the Forge
Puppet | Custom Modules & Using the ForgeAaron Bernstein
 

Similar to Features & Installation Profiles (20)

Intro to Features Module on Drupal
Intro to Features Module on DrupalIntro to Features Module on Drupal
Intro to Features Module on Drupal
 
Strategies and Tips for Building Enterprise Drupal Applications - PNWDS 2013
Strategies and Tips for Building Enterprise Drupal Applications - PNWDS 2013Strategies and Tips for Building Enterprise Drupal Applications - PNWDS 2013
Strategies and Tips for Building Enterprise Drupal Applications - PNWDS 2013
 
Features everywhere
Features everywhere Features everywhere
Features everywhere
 
DDAY2014 - Features per Drupal 8
DDAY2014 - Features per Drupal 8DDAY2014 - Features per Drupal 8
DDAY2014 - Features per Drupal 8
 
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
 
Features and Context Overview
Features and Context OverviewFeatures and Context Overview
Features and Context Overview
 
Understanding and extending p2 for fun and profit
Understanding and extending p2 for fun and profitUnderstanding and extending p2 for fun and profit
Understanding and extending p2 for fun and profit
 
Drupal Workflow Concepts
Drupal Workflow ConceptsDrupal Workflow Concepts
Drupal Workflow Concepts
 
Migraine Drupal - syncing your staging and live sites
Migraine Drupal - syncing your staging and live sitesMigraine Drupal - syncing your staging and live sites
Migraine Drupal - syncing your staging and live sites
 
Beginner's guide to drupal
Beginner's guide to drupalBeginner's guide to drupal
Beginner's guide to drupal
 
Drupal distributions - how to build them
Drupal distributions - how to build themDrupal distributions - how to build them
Drupal distributions - how to build them
 
Drupal
DrupalDrupal
Drupal
 
Building and Deployment of Drupal sites with Features and Context
Building and Deployment of Drupal sites with Features and ContextBuilding and Deployment of Drupal sites with Features and Context
Building and Deployment of Drupal sites with Features and Context
 
Best practices for share point solution deployment
Best practices for share point solution deploymentBest practices for share point solution deployment
Best practices for share point solution deployment
 
PHP North-East - Automated Deployment
PHP North-East - Automated DeploymentPHP North-East - Automated Deployment
PHP North-East - Automated Deployment
 
Automated Deployment
Automated DeploymentAutomated Deployment
Automated Deployment
 
IBM Drupal Users Group Discussion on Managing and Deploying Configuration
IBM Drupal Users Group Discussion on Managing and Deploying ConfigurationIBM Drupal Users Group Discussion on Managing and Deploying Configuration
IBM Drupal Users Group Discussion on Managing and Deploying Configuration
 
Extend Eclipse p2 framework capabilities: Add your custom installation steps
Extend Eclipse p2 framework capabilities: Add your custom installation stepsExtend Eclipse p2 framework capabilities: Add your custom installation steps
Extend Eclipse p2 framework capabilities: Add your custom installation steps
 
CloudStack templates with OpenVM
CloudStack templates with OpenVMCloudStack templates with OpenVM
CloudStack templates with OpenVM
 
Puppet | Custom Modules & Using the Forge
Puppet | Custom Modules & Using the ForgePuppet | Custom Modules & Using the Forge
Puppet | Custom Modules & Using the Forge
 

Recently uploaded

FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...
FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...
FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...FIDO Alliance
 
The Metaverse: Are We There Yet?
The  Metaverse:    Are   We  There  Yet?The  Metaverse:    Are   We  There  Yet?
The Metaverse: Are We There Yet?Mark Billinghurst
 
PLAI - Acceleration Program for Generative A.I. Startups
PLAI - Acceleration Program for Generative A.I. StartupsPLAI - Acceleration Program for Generative A.I. Startups
PLAI - Acceleration Program for Generative A.I. StartupsStefano
 
Speed Wins: From Kafka to APIs in Minutes
Speed Wins: From Kafka to APIs in MinutesSpeed Wins: From Kafka to APIs in Minutes
Speed Wins: From Kafka to APIs in Minutesconfluent
 
How Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdf
How Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdfHow Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdf
How Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdfFIDO Alliance
 
How we scaled to 80K users by doing nothing!.pdf
How we scaled to 80K users by doing nothing!.pdfHow we scaled to 80K users by doing nothing!.pdf
How we scaled to 80K users by doing nothing!.pdfSrushith Repakula
 
Free and Effective: Making Flows Publicly Accessible, Yumi Ibrahimzade
Free and Effective: Making Flows Publicly Accessible, Yumi IbrahimzadeFree and Effective: Making Flows Publicly Accessible, Yumi Ibrahimzade
Free and Effective: Making Flows Publicly Accessible, Yumi IbrahimzadeCzechDreamin
 
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...Integrating Telephony Systems with Salesforce: Insights and Considerations, B...
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...CzechDreamin
 
Demystifying gRPC in .Net by John Staveley
Demystifying gRPC in .Net by John StaveleyDemystifying gRPC in .Net by John Staveley
Demystifying gRPC in .Net by John StaveleyJohn Staveley
 
10 Differences between Sales Cloud and CPQ, Blanka Doktorová
10 Differences between Sales Cloud and CPQ, Blanka Doktorová10 Differences between Sales Cloud and CPQ, Blanka Doktorová
10 Differences between Sales Cloud and CPQ, Blanka DoktorováCzechDreamin
 
A Business-Centric Approach to Design System Strategy
A Business-Centric Approach to Design System StrategyA Business-Centric Approach to Design System Strategy
A Business-Centric Approach to Design System StrategyUXDXConf
 
Unpacking Value Delivery - Agile Oxford Meetup - May 2024.pptx
Unpacking Value Delivery - Agile Oxford Meetup - May 2024.pptxUnpacking Value Delivery - Agile Oxford Meetup - May 2024.pptx
Unpacking Value Delivery - Agile Oxford Meetup - May 2024.pptxDavid Michel
 
Linux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdf
Linux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdfLinux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdf
Linux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdfFIDO Alliance
 
Extensible Python: Robustness through Addition - PyCon 2024
Extensible Python: Robustness through Addition - PyCon 2024Extensible Python: Robustness through Addition - PyCon 2024
Extensible Python: Robustness through Addition - PyCon 2024Patrick Viafore
 
Powerful Start- the Key to Project Success, Barbara Laskowska
Powerful Start- the Key to Project Success, Barbara LaskowskaPowerful Start- the Key to Project Success, Barbara Laskowska
Powerful Start- the Key to Project Success, Barbara LaskowskaCzechDreamin
 
What's New in Teams Calling, Meetings and Devices April 2024
What's New in Teams Calling, Meetings and Devices April 2024What's New in Teams Calling, Meetings and Devices April 2024
What's New in Teams Calling, Meetings and Devices April 2024Stephanie Beckett
 
Salesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
Salesforce Adoption – Metrics, Methods, and Motivation, Antone KomSalesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
Salesforce Adoption – Metrics, Methods, and Motivation, Antone KomCzechDreamin
 
Simplified FDO Manufacturing Flow with TPMs _ Liam at Infineon.pdf
Simplified FDO Manufacturing Flow with TPMs _ Liam at Infineon.pdfSimplified FDO Manufacturing Flow with TPMs _ Liam at Infineon.pdf
Simplified FDO Manufacturing Flow with TPMs _ Liam at Infineon.pdfFIDO Alliance
 
AI revolution and Salesforce, Jiří Karpíšek
AI revolution and Salesforce, Jiří KarpíšekAI revolution and Salesforce, Jiří Karpíšek
AI revolution and Salesforce, Jiří KarpíšekCzechDreamin
 
Google I/O Extended 2024 Warsaw
Google I/O Extended 2024 WarsawGoogle I/O Extended 2024 Warsaw
Google I/O Extended 2024 WarsawGDSC PJATK
 

Recently uploaded (20)

FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...
FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...
FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...
 
The Metaverse: Are We There Yet?
The  Metaverse:    Are   We  There  Yet?The  Metaverse:    Are   We  There  Yet?
The Metaverse: Are We There Yet?
 
PLAI - Acceleration Program for Generative A.I. Startups
PLAI - Acceleration Program for Generative A.I. StartupsPLAI - Acceleration Program for Generative A.I. Startups
PLAI - Acceleration Program for Generative A.I. Startups
 
Speed Wins: From Kafka to APIs in Minutes
Speed Wins: From Kafka to APIs in MinutesSpeed Wins: From Kafka to APIs in Minutes
Speed Wins: From Kafka to APIs in Minutes
 
How Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdf
How Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdfHow Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdf
How Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdf
 
How we scaled to 80K users by doing nothing!.pdf
How we scaled to 80K users by doing nothing!.pdfHow we scaled to 80K users by doing nothing!.pdf
How we scaled to 80K users by doing nothing!.pdf
 
Free and Effective: Making Flows Publicly Accessible, Yumi Ibrahimzade
Free and Effective: Making Flows Publicly Accessible, Yumi IbrahimzadeFree and Effective: Making Flows Publicly Accessible, Yumi Ibrahimzade
Free and Effective: Making Flows Publicly Accessible, Yumi Ibrahimzade
 
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...Integrating Telephony Systems with Salesforce: Insights and Considerations, B...
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...
 
Demystifying gRPC in .Net by John Staveley
Demystifying gRPC in .Net by John StaveleyDemystifying gRPC in .Net by John Staveley
Demystifying gRPC in .Net by John Staveley
 
10 Differences between Sales Cloud and CPQ, Blanka Doktorová
10 Differences between Sales Cloud and CPQ, Blanka Doktorová10 Differences between Sales Cloud and CPQ, Blanka Doktorová
10 Differences between Sales Cloud and CPQ, Blanka Doktorová
 
A Business-Centric Approach to Design System Strategy
A Business-Centric Approach to Design System StrategyA Business-Centric Approach to Design System Strategy
A Business-Centric Approach to Design System Strategy
 
Unpacking Value Delivery - Agile Oxford Meetup - May 2024.pptx
Unpacking Value Delivery - Agile Oxford Meetup - May 2024.pptxUnpacking Value Delivery - Agile Oxford Meetup - May 2024.pptx
Unpacking Value Delivery - Agile Oxford Meetup - May 2024.pptx
 
Linux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdf
Linux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdfLinux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdf
Linux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdf
 
Extensible Python: Robustness through Addition - PyCon 2024
Extensible Python: Robustness through Addition - PyCon 2024Extensible Python: Robustness through Addition - PyCon 2024
Extensible Python: Robustness through Addition - PyCon 2024
 
Powerful Start- the Key to Project Success, Barbara Laskowska
Powerful Start- the Key to Project Success, Barbara LaskowskaPowerful Start- the Key to Project Success, Barbara Laskowska
Powerful Start- the Key to Project Success, Barbara Laskowska
 
What's New in Teams Calling, Meetings and Devices April 2024
What's New in Teams Calling, Meetings and Devices April 2024What's New in Teams Calling, Meetings and Devices April 2024
What's New in Teams Calling, Meetings and Devices April 2024
 
Salesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
Salesforce Adoption – Metrics, Methods, and Motivation, Antone KomSalesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
Salesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
 
Simplified FDO Manufacturing Flow with TPMs _ Liam at Infineon.pdf
Simplified FDO Manufacturing Flow with TPMs _ Liam at Infineon.pdfSimplified FDO Manufacturing Flow with TPMs _ Liam at Infineon.pdf
Simplified FDO Manufacturing Flow with TPMs _ Liam at Infineon.pdf
 
AI revolution and Salesforce, Jiří Karpíšek
AI revolution and Salesforce, Jiří KarpíšekAI revolution and Salesforce, Jiří Karpíšek
AI revolution and Salesforce, Jiří Karpíšek
 
Google I/O Extended 2024 Warsaw
Google I/O Extended 2024 WarsawGoogle I/O Extended 2024 Warsaw
Google I/O Extended 2024 Warsaw
 

Features & Installation Profiles

  • 1. Features + Installation Profiles February 24, 2012
  • 2. David Watson Rensselaer Polytechnic Institute Web Developer Experimental Media and Performing Arts Center (EMPAC) Adjunct Professor Web Systems Development Drupal Consultant ~3 years in the community Specialized Generalist
  • 3. Best Practices Revision Control Dev/Test/Prod workflow One-click Deployment
  • 4. Revision Control Easier collaboration with conflict handling Change history Ability to revert Easier to merge in new code Best Practice: Use it. Reality: This is hard to do for sites!
  • 5. Dev/Test/Prod Workstations check out code from Dev server Patches are reviewed, committed to Dev Possibly running Jenkins/Hudson Release candidates are pushed to Test/Staging environment Final release pushed to Production along with any staged content
  • 6. Dev/Test/Prod Best Practice: Use a workflow like this to ensure that only production-quality code is running on production servers. Reality: This is hard to do for sites!
  • 7. One-click Deployment End-users shouldn't have to configure their sites, that's what we're here for! Best practice: Let the installer do all of the heavy lifting, providing sane defaults site-wide Reality: ...You get the idea.
  • 8. Drupal Database Data Nodes Fields ... Configuration Content Types Field Info Rules Views Settings Variables
  • 9. Drupal Deployment Challenges How do we deploy our Drupal instances from one box to another? Moving the database? Manually duplicating configuration changes?
  • 10. Drupal Deployment Challenges How to we use revision control with Drupal? Works great with modules, but what about our configuration? Add SQL dumps to the repository?
  • 11. Drupal Deployment Challenges How do we achieve one-click deployment? Modules are handled through dependencies... What about our configuration? Write some sort of custom installation script?
  • 12. THE Drupal Deployment Challenge All of these problems can be reduced to one: configuration that lives in the database instead of the code How do we move as much configuration into code as possible, and load it when the site is first installed?
  • 13. The Answer Installation Profiles provide a means of one- click (or even fully automated!) deployment for modules and themes Features provide a means of exporting configuration to code as feature modules, used to satisfy a specific use case
  • 14. Installation Profiles Core functionality Allows users to perform one-time setup tasks during installation, based on presets Install and enable modules/themes Run custom code Can be used to package modules and themes Possible to select through the UI and through drush site-install!
  • 15. Anatomy of an Install Profile Exist in profiles/PROFILENAME Within each... PROFILENAME.info – metadata/dependencies PROFILENAME.install – installation-specific hooks PROFILENAME.profile – other hooks modules/ - modules packaged with this profile themes/ - themes packaged in the profile libraries/ - Libraries API looks here for libs
  • 16. Features Contrib module that allows for exporting existing configuration as modules First, some terminology...
  • 17. Features Terminology Features refers to the Features module Features packages components together - bits of configuration for individual modules, like individual views These components are taken from modules that integrate with Features, usually by providing CTools exportables The feature modules that Features creates contain the components that you select
  • 18. Why Features? Feature modules can be committed to version control Code is more portable than database between Dev/Test/Prod Overrides to feature modules can be reverted to their default state Hooks can be added to the module later (remember, feature modules are just modules!)
  • 19. Commonly Used Boxes – What custom blocks should've been Views – All views are exportable! Rules – Also exportable. Very handy when working w/ Drupal Commerce! Strongarm – Makes the variables table exportable UUID – Paired with other modules to provide unique identifiers for content that won't change depending on the order they're installed
  • 20. Special Cases Not everything is exportable Make it exportable, and contribute a patch! Last resort: hook_(un)install() Content-based Configuration? Boxes module for blocks Defaultcontent for nodes Drupal Commerce7 in progress...
  • 21. Putting it all together Features provides the means of separating configuration from content Install Profiles allow for packaging of modules (contrib/devel/features/custom) and themes, while offering one-click deployment
  • 22. Features Workflow Perform configuration in the UI Export config as a feature and move to profiles/PROFILENAME/modules/features/ Implement any necessary hooks in the feature's .module file Make sure the install profile depends on the new feature Reinstall the site and test
  • 23. Site Development Workflow Create an install profile Download/write contrib/custom modules Required libraries should go in the profile's libraries/ directory Create core feature for site-wide settings, add to profile's .info Repeat feature creation for all other functionality Remember, features are modules too; you can depend on other features!
  • 24. Site Theming Workflow Create an install profile Download/create (sub)themes in profiles/PROFILENAME/themes In .install file... theme_enable(THEMENAME); variable_set('theme_default', THEMENAME); *hack hack hack*
  • 25. Example Aqueduct Install Profile Heavily commented Uses Features to export configuration settings Play, experiment, use as a base, send suggestions/patches for improvement, enjoy!
  • 27. Get in Touch! d.o – davidwatson e – dmw@davidwatson.name t - @caughtexception in – linkedin.com/in/davidmwatson