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

Clocker and OpenStack

Clocker and OpenStack

Presented at OpenStack online meetup, August 2014

Andrew Kennedy

August 19, 2014
Tweet

More Decks by Andrew Kennedy

Other Decks in Technology

Transcript

  1. Clocker  and  OpenStack   Andrew  Kennedy,  Dave  Nielsen  and  Andrea

     Turli   OpenStack  Meetup,  19  August  2014    
  2. IntroducCon   •  Speakers   –  Andrew  Kennedy  and  Andrea

     Turli   –  Dave  Neilsen   •  Overview   –  Docker   –  Brooklyn   –  Campsite   –  OpenStack  
  3. Docker   •  Technical   •  Containers   •  Micro

     Services   •  Dockerfiles   –  ConfiguraCon   –  Volumes   –  Composable  
  4. Docker   •  Cloud  Usage   •  OpenStack   • 

    Manual  Process   –  CredenCals  and  Keys   –  OperaCng  System  and  Hardware   –  Download  and  InstallaCon   –  ConfiguraCon   –  Dockerfile  per  Service  
  5. Brooklyn   •  Brooklyn   –  ApplicaCon  Management  PlaOorm  

    –  Autonomic  CompuCng   •  YAML  Blueprint   –  Services  (EnCCes)   –  ConfiguraCon   –  ATributes  (Sensors)   –  AcCons  (Effectors)  
  6. Clocker   •  Infrastructure   –  Apache  jclouds  Supported  Cloud

     with  CredenCals   •  Docker  Host   –  Running  the  Docker  Service   –  REST  API  Access  Using  jclouds  1.8.0  Docker  Driver   –  Virtual  Machine  Access  Using  SSH   –  Cluster  of  Containers   •  Docker  Container   –  Running  Services  and  Commands  for  EnCty  
  7. Clocker   •  Demand  Side   –  Create  a  New

     Container   –  Resize  Cluster  of  EnCCes   –  AutoScaler  Policy  ATached  to  Cluster   •  Supply  Side   –  Placement  Strategies  for  Containers   –  Depth  or  Breadth  First   –  Affinity  Rules   –  Resource  AllocaCon  (CPU  Shares,  Load,  Memory,  …)  
  8. Clocker   •  ApplicaCon  Deployment   –  CAMP  Blueprint  in

     YAML   –  Java  Classes   –  Mostly  Unchanged   •  Docker  Specific  ConfiguraCon   –  Affinity  Rules  or  Placement  Strategy   –  Dockerfile  or  Image  ID   –  CPU  or  Memory  Shares   –  Docker  Volumes  
  9. Campsite  ApplicaCon   •  GitHub  Repository   •  Components  

    –  PHP  Web  ApplicaCon   –  Node.JS  RESTful  API   –  MySQL  Database   •  Cloud  Services   –  Email   –  Message  Queue   –  Object  Store  
  10. Campsite  Blueprint   id:  campsite-­‐application   locations:   -­‐  jclouds:hpcloud-­‐compute

      services:   -­‐  serviceType:  brooklyn.entity.database.mysql.MySqlNode   -­‐  serviceType:  brooklyn.campsite.entity.CampsiteWebapp      brooklyn.config:          objectStorage:  AWSObjectStorage          queueService:  AWS_SQS          emailService:  AWS_SES          databaseHost:  $brooklyn:component("mysql").attributeWhenReady("host.name")          databasePort:  $brooklyn:component("mysql").attributeWhenReady("mysql.port")          databaseUser:  "campsite"          databasePassword:  "p4ssw0rd"          domainName:  "campsite.org"   -­‐  serviceType:  brooklyn.campsite.entity.CampsiteApi  
  11. Campsite  Blueprint   •  Java  Components   –  CampsiteWebapp  PHP

     EnCty   –  CampsiteApi  Node.JS  EnCty   •  Campsite  ApplicaCon   –  ConfiguraCon  ProperCes   –  Webapp,  API  and  MySQL  Database  EnCCes   •  YAML  Blueprint  
  12. Campsite  Cluster   •  Add  Cluster  CapabiliCes   •  No

     Extra  Coding   –  Just  Write  YAML  Blueprint   –  CampsiteWebapp  Already  Set  Up   –  Stateless  Service  (Uses  SQL  Database)   –  Only  Run  Database  Create  and  Install  Once   •  New  Services   –  Nginx  Load  Balancer  EnCty   –  Rabbit  MQ  Broker  EnCty  
  13. Summary   •  Docker  Containers   –  Micro  Services  

    •  LimitaCons   –  MulCple  Hosts   –  Management   •  Clocker   –  ApplicaCon  Blueprints   –  OrchestraCon