implementing continuous integration best practices with drupal - 2014

22
Implementing Continuous Integration Best Practices with Drupal Barry Jaspan Senior Architect May 22 nd  2014 Jess Iandiorio Sr. Director, Cloud Product Marketing Niels van Mourik Backline support engineer Acquia Client Advisory Team

Upload: nielsvm

Post on 10-May-2015

243 views

Category:

Technology


4 download

DESCRIPTION

On May 22nd 2014 I was asked to speak at a Drupalcafé (http://www.meetup.com/drupalnetherlands/events/173046492/) on the subject of Continuous Integration on Acquia. I gave a refreshed presentation of one done on CI by Acquia in a 2012 Webinar and focused on the pillars that allow our customers to assemble a full CI implementation tailored to their own needs and workflows.

TRANSCRIPT

Page 1: Implementing Continuous Integration Best Practices with Drupal - 2014

Implementing Continuous Integration Best Practices with Drupal

Barry JaspanSenior Architect

May 22nd 2014

Jess IandiorioSr. Director, Cloud Product Marketing

Niels van MourikBackline support engineerAcquia Client Advisory Team

Page 2: Implementing Continuous Integration Best Practices with Drupal - 2014

Creating killer websites is hard …

Page 3: Implementing Continuous Integration Best Practices with Drupal - 2014

Deploying them shouldn’t be.

Page 4: Implementing Continuous Integration Best Practices with Drupal - 2014

Yeah, right.

Page 5: Implementing Continuous Integration Best Practices with Drupal - 2014

Continuous Integration decides between success or failure

• Work in small batches

• Always know where you stand

• Release often so there are no big surprises

• Test everything

Page 6: Implementing Continuous Integration Best Practices with Drupal - 2014

Principles of Continuous Integration

• Use a source code repository

• Automate testing

• Test in a clone of the production environment

• Make all versions easily accessible

• Have an audit trail (“blame list”)

• Automate site deployment

• Measure results 

• Iterate rapidly

http://en.wikipedia.org/wiki/Continuous_integration

Page 7: Implementing Continuous Integration Best Practices with Drupal - 2014

Sounds great. How do I get there?

Page 8: Implementing Continuous Integration Best Practices with Drupal - 2014

Option 1: Build it Yourself

• Git/SVN server

• Lots of Jenkins jobs• Deploy on commit

• Copy DB/files for dev

• Test on deploy

• Tag and release on success

• Many more…

• OS management• Server build

• Security updates

• Multiple web vhosts• Domains, SSL, php.ini, …

• Multiple databases• Manage credentials

• HA, memcached, Varnish, Tomcat, Jenkins, Solr, ... Scaling all of this

• Backups and restores

• 24/7 monitoring

Page 9: Implementing Continuous Integration Best Practices with Drupal - 2014

You do not want to do this.

(If you want this job, I have a job for you)

Page 10: Implementing Continuous Integration Best Practices with Drupal - 2014

Option 2: Use someone else's

Page 11: Implementing Continuous Integration Best Practices with Drupal - 2014

Principles of Continuous Integration

• Use a source code repository

• Automate testing

• Test in a clone of the production environment

• Make all versions easily accessible

• Have an audit trail (“blame list”)

• Automate site deployment

• Measure results 

• Iterate rapidly

Page 12: Implementing Continuous Integration Best Practices with Drupal - 2014

Acquia Cloud free tier

Completely free for site development.

• Intuitive Dev workflow

• Power tools for power users

• Drupal­optimized infrastructure

• No production siteswww.acquia.com/acquia­

cloud­for­free

Page 13: Implementing Continuous Integration Best Practices with Drupal - 2014

Acquia Cloud AC/DC'Dev Cloud'

Page 14: Implementing Continuous Integration Best Practices with Drupal - 2014

Acquia Cloud Enterprise ACE'Managed Cloud'

Never let your best day become your worst.

• White­glove managed service for mission­ critical Drupal websites

• Drupal­tuned hosting infrastructure

• HA, elastic resources with multi­region failover

Page 15: Implementing Continuous Integration Best Practices with Drupal - 2014

One size doesn't fit all

Therefore Acquia's CI solutionallow you to assemble it toyour needs and workflow

Page 16: Implementing Continuous Integration Best Practices with Drupal - 2014

SSH

Read­only SSH access toyour document root(s)

• Upload SSH pubkeys

• Access to file directory

• All Drush flavors available

• Access to all web servers

• VPN to your network is a possibility

Page 17: Implementing Continuous Integration Best Practices with Drupal - 2014

Cloud Hooks

Act upon anything that ishappening on your site

• hooks / [ENV] / [name].sh

• Run any drush command

• Clean production DB's during copies/dumps (e.g. cache tbls)

• Run your tests and e­mail/ssh results

• Some events:• post­code­deploy

• post­db­copy

• post­files­copy

http://bit.ly/1oj3YPM

https://github.com/acquia/cloud­hooks

Page 18: Implementing Continuous Integration Best Practices with Drupal - 2014

Acquia Cloud API

Automate everything youcould click­ethy­click!

• Nice RESTful goodness

• 40 drush integration cmds• Therefore entirely scriptable• Deploy tags and branches

• Databases

• Domain names

• Purge varnish

• Copy fileshttps://cloudapi.acquia.com/

Page 19: Implementing Continuous Integration Best Practices with Drupal - 2014

https://www.youtube.com/watch?v=_iA8h-Bh1Z0

Page 20: Implementing Continuous Integration Best Practices with Drupal - 2014

Putting things togetherwith CI systems

Page 21: Implementing Continuous Integration Best Practices with Drupal - 2014

Jenkins, Travis CI, CruiseControl

• Acquia focuses on Drupal

• VPS: el­cheapo 5,00 € 

• Make your Acquia Cloud a scripted marionet...

• Your build server, your workflow 

https://cloudapi.acquia.com/

Page 22: Implementing Continuous Integration Best Practices with Drupal - 2014

• For more information visit: http://www.acquia.com

• Sales: [email protected] / (+31) (0) 20 890 3987

• Twitter: @acquia

• Comments welcome:

[email protected]

this presentation is available as webinar on:http://acquia.com/resources/recorded_webinars

Questions?