O slideshow foi denunciado.
Utilizamos seu perfil e dados de atividades no LinkedIn para personalizar e exibir anúncios mais relevantes. Altere suas preferências de anúncios quando desejar.

Best practices for Continuous Deployment with Drupal - DrupalCon Latin América 2015

Apresentação realizada por Renato Gomes Vasconcellos, o Revagomes, na DrupalCon Bogotá 2015!

Best practices for Continuous Deployment with Drupal - DrupalCon Latin América 2015

  1. 1. Best Practices for CD with Drupal Renato Vasconcellos renato@taller.net.br
  2. 2. What you’re about to see in this presentation?
  3. 3. ● What’s Continuous Deployment ● Tools & Modules ● Development Workflow ● Tips & Resources Agenda
  4. 4. Disclaimer This presentation aims those people who are willing to start or to get lessons learned with Continuous Deployment. If you’re used to the devops principles and you’re an advanced Drupal developer maybe you already know what is coming next.
  5. 5. What means Deploy?
  6. 6. “Placement of equipment and troops in a battlefield.” www.webopedia.com/TERM/D/deploy.html
  7. 7. “To install, test and implement an application or computer system.” www.webopedia.com/TERM/D/deploy.htm
  8. 8. Continuous Integration? Continuous Delivery? Continuous Deployment?
  9. 9. Continuous Integration
  10. 10. To integrate your work constantly with your team members.
  11. 11. Continuous Delivery
  12. 12. Provide your work constantly for review by the team or client.
  13. 13. Continuous Deployment
  14. 14. Deploy your work constantly into client’s server.
  15. 15. Continuous Deployment is a reflex the team’s culture and discipline.
  16. 16. Continuous Deployment in 5 steps Eric Ries - O'Reilly Radar http://lb.cm/dploy5stps
  17. 17. CI Server (Continuous Integration server)
  18. 18. Source control commit check
  19. 19. Simple deployment scripts
  20. 20. Real-time alerting
  21. 21. Root cause analysis (the five whys)
  22. 22. Where/how to start? Image by Jalel
  23. 23. Standardized Workflow
  24. 24. Work Agreements
  25. 25. WAs are the set of rules/disciplines/processes the team agrees to follow without fail to make themselves more efficient and successful. Vignesh Murthy https://www.scrumalliance.org/community/articles/2014/january/work-agreements-scrum- team
  26. 26. Coding Standards drupal.org/coding-standards
  27. 27. Everything in Code
  28. 28. Test Driven Development
  29. 29. CI/CD Server
  30. 30. Make your choice ● Jenkins ● CircleCI ● Codeship ● Strider CD ● Dploy ● Travis CI ● Go ● Other
  31. 31. Deploy on Green!
  32. 32. Development Workflow
  33. 33. Pipeline Develop. Test/QA Productio n UAT/Stagin g
  34. 34. Development Environment
  35. 35. Development environment should resemble the production environment.
  36. 36. Test/QA Environment
  37. 37. QA environment should resemble the production environment.
  38. 38. UAT/Staging/Pre-prod Environment
  39. 39. UAT environment must resemble the production environment.
  40. 40. Production Environment
  41. 41. Recap. Develop. Test/QA http://dltj.org/article/software-development-practice/ http://spacebug.com/effective_development_environments/ Productio n UAT/Stagin g
  42. 42. What about Drupal?
  43. 43. Drupal Development Virtual Machine drupal.org/project/vm github.com/zivtech/vagrant-development-vm github.com/geerlingguy/drupal-dev-vm github.com/sebas5384/charm-drupal
  44. 44. Drush drush.org
  45. 45. Install Profiles / Custom Distributions drupal.org/documentation/build/distributions
  46. 46. Strongarm Module drupal.org/project/strongarm
  47. 47. Features Module drupal.org/project/features drupal.org/documentation/modules/features
  48. 48. Default Config Module drupal.org/project/defaultconfig
  49. 49. Custom Deployment Module befused.com/drupal/site-deployment-module
  50. 50. Configuration Management Module drupal.org/project/configuration
  51. 51. UUID Module drupal.org/project/uuid
  52. 52. Deploy Module drupal.org/project/deploy
  53. 53. WF Tools Module drupal.org/project/wf_tools
  54. 54. Git Workflow atlassian.com/git/workflows
  55. 55. Centralized workflow
  56. 56. Feature branch workflow
  57. 57. Git flow workflow
  58. 58. Forking workflow
  59. 59. A successful git branch model? Vincent Driessen nvie.com/posts/a-successful-git-branching-model
  60. 60. Git flow Workflow Git flow https://github.com/nvie/gitflow Git flow cheat sheet http://danielkummer.github.io/git-flow-cheatsheet/
  61. 61. .git/Hooks git-scm.com/book/en/v2/Customizing-Git-Git-Hooks
  62. 62. Client Side
  63. 63. Pre Commit ● Coding Standards (Lint) ● Automated tests
  64. 64. Post Checkout ● Automated tests ● Broken branch check
  65. 65. Server Side
  66. 66. Pre Receive ● Coding Standards (Lint) ● Automated tests ● Branch protection
  67. 67. Post Receive ● Load tests ● Notifications
  68. 68. What about Drupal?
  69. 69. Coder Module drupal.org/project/coder
  70. 70. PAReview script drupal.org/project/pareviewsh
  71. 71. Drupal Code Quality Module drupal.org/project/dcq
  72. 72. Automated Tests
  73. 73. Automated Tests brings security and reliability to a continual improvement process.
  74. 74. Joseph Yodel slideshare.net/yodamann/pragmatic-not-dogmatic-tdd-agile2012
  75. 75. Joseph Yodel slideshare.net/yodamann/pragmatic-not-dogmatic-tdd-agile2012
  76. 76. Joseph Yodel slideshare.net/yodamann/pragmatic-not-dogmatic-tdd-agile2012
  77. 77. What about Drupal?
  78. 78. Simple Test drupal.org/project/simpletest
  79. 79. PHP Unit phpunit.de drupal.org/phpunit
  80. 80. Behat Extension Module drupal.org/project/drupalextension
  81. 81. Barbor (BDD Framework) github.com/barbor/barbor
  82. 82. Questions & Answers
  83. 83. Give your feedback! latinamerica2015.drupal.org/session/best-practices-continuous-deployment- drupal
  84. 84. Let’s talk! @revagomes renato@taller.net.br drupal.org/u/revagomes about.me/revagomes

×