Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

London devops - orc

864 views

Published on

Talk about Orc, our continuous deployment framework

  • Be the first to comment

  • Be the first to like this

London devops - orc

  1. 1. OrcZero downtime deployments made easy Tomas Doran (t0m) @bobtfish <bobtfish@bobtfish.net> https://github.com/bobtfish/
  2. 2. Problem space:• Multiple heterogeneous applications• Multiple servers per app• Multiple environments• Custom deployment solutions / semi- manual deployment
  3. 3. Observed problems:• Support nightmare• Failed / inconsistent deployments• New applications extremely costly to deploy
  4. 4. Solution:• Application infrastructure contract• Defined interface for infrastructure to interact with your application: • How to launch • How to query health• Any application which complies gets continuous deployment - free
  5. 5. Reliable• Contract conformity checked by a common test suite• CI builds to check deployability
  6. 6. Predictable• Deployment is model driven• Store desired state in ‘cmdb’• Audit live servers, adjust reality to conform to desired state• State machine - easy to test!
  7. 7. Safe• Each possible step in a deployment is a state transition• Sample live state after each transition - if model doesn’t match reality, stop!• Mcollective agent - flexible per-user + fact based permissions for free
  8. 8. Architecture
  9. 9. Participation?• Need to be able to cleanly remove instances from load balancer• Make load balancer health check do 2 things: • Check app = healthy • Check participation = true• Tatin - tiny REST service to drop state into
  10. 10. Contract URIs• App: • http://localhost:xxxx/info/health • http://localhost:xxxx/info/version• Participation: • http://localhost :yyyy/app_name/environment_name/insta nce_name
  11. 11. deployapp methods• get status (health + version)• enable participation• disable participation• upgrade version
  12. 12. State machine
  13. 13. Multiple instances• Discover all instances• Work out next transition for each instance• Each transition has a weight• Sort by weight - take highest weighted• Repeat until no transitions left
  14. 14. Simple example Desired Actual Desired ActualApp Action Weight version version part part Disablehost1 5 4 Y Y 1 part Disablehost2 5 4 Y Y 1 part
  15. 15. Simple example Desired Actual Desired ActualApp Action Weight version version part parthost1 5 4 Y N Upgrade 2 Disablehost2 5 4 Y Y 1 part
  16. 16. Simple example Desired Actual Desired ActualApp Action Weight version version part part Enablehost1 5 5 Y N 3 part Disablehost2 5 4 Y Y 1 part
  17. 17. Simple example Desired Actual Desired ActualApp Action Weight version version part parthost1 5 5 Y Y None 0 Disablehost2 5 4 Y Y 1 part
  18. 18. Simple example Desired Actual Desired ActualApp Action Weight version version part parthost1 5 5 Y Y None 0 Disablehost2 5 4 Y N 1 part
  19. 19. Simple example Desired Actual Desired ActualApp Action Weight version version part parthost1 5 5 Y Y None 0host2 5 4 Y N Upgrade 2
  20. 20. Simple example Desired Actual Desired ActualApp Action Weight version version part parthost1 5 5 Y Y None 0host2 5 5 Y Y None 0
  21. 21. A/B groups• Can run A/B groups of the same app with different versions• Can upgrade non-participating group, test, then swap participation.• Same model just works
  22. 22. Status• Orc, deployapp + contract test harness open source• Docs still very lacking.• You need to plug in your own repository module (and your own launcher for non jar apps)
  23. 23. Todo• Better deployment (public gem+debs)• Deployapp configuration rewrite• http artifact fetcher• More app launchers - rack/wsgi/psgi apps!• Docs - specifically load balancer configs + installation.
  24. 24. Code• The ideas here are way more important than the code• Development sponsored by TIM Group • Yes, of course we are hiring :)• https://github.com/youdevise/orc
  25. 25. Thanks!https://github.com/youdevise/orc Questions?

×