Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Deploying Distributed Systems - London Web

Deploying Distributed Systems - London Web

mattheath

April 18, 2013
Tweet

More Decks by mattheath

Other Decks in Programming

Transcript

  1. WHAT ELSE? COMPRESS & MINIFY RESTART SERVERS ASSET VERSIONING DATABASE

    MIGRATIONS LOAD NEW CONFIGS LINT CHECKS CLEAR CACHES SPAWN WORKERS WARM CACHES
  2. “Capistrano is a utility and framework for executing commands in

    parallel on multiple remote machines, via SSH”
  3. • Identify version to deploy • Update remotely cached git

    repository • Checkout specific version • Copy code to a new timestamped folder • Final preflight tasks • Switch symlink to point to new code • ‘Restart’ web servers • Post deploy tasks • Clean up old releases
  4. $ capify . [add] writing './Capfile' [add] making directory './config'

    [add] writing './config/deploy.rb' [done] capified!
  5. cap londonstaging deploy cap dublinstaging deploy cap torontostaging deploy cap

    chicagostaging deploy cap nycstaging deploy cap bostonstaging deploy cap ...staging deploy cap ...staging deploy ... MULTI-CONFIGURATION?
  6. INTERNAL TOOLS & APIS HAILOCAB.COM DRIVER APIS CUSTOMER SERVICES CREDIT

    SERVICES COMMUNICATION SERVICES AUTHENTICATION SERVICES CONFIGURATION SERVICES CRM SERVICES PAYMENT SERVICES EVENTS SERVICES STATS SERVICES ALLOCATION SERVICES BACKGROUND QUEUES CUSTOMER APIS MESSAGING SERVICES APPLICATIONS
  7. One application to deploy all applications Deploy in parallel to

    n servers in distributed geographic regions with the correct configuration Dynamic server lists Add additional functionality in one central place Play a shipping horn sound when deploying
  8. IRC / CHAT NOTIFICATION [03:14:58] <CONAN> mobile-api/intlrelease (6957bb87) is being

    deployed to staging by Matt Heath [03:15:25] <CONAN> mobile-api/intlrelease successfully deployed to staging [12:29:20] <CONAN> elasticride/master (390eae4c) is being deployed to staging by Saul Howard
  9. Image credits: Conan ‘8-bit Marvels’ - Paulo Capdeville Network diagram

    - Elijah Meeks, dhs.stanford.edu Creative Commons images from sxc.hu thanks to Miguel Saavedra, @rbval, G. Marcus Still interested? Caphub - Multistage capistrano: http://bit.ly/Tkkn4W Deploying at Github: http://git.io/FlaFhA Asgard - Web based deployment from Netflix: http://nflx.it/NsJVtD