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

Cloud meets Fog & Puppet A Story of Version Co...

Cloud meets Fog & Puppet A Story of Version Controlled Infrastructure

This is the presentation deck I used for the talk I gave at rootconf - A conference at Bangalore for sysadmins.
Gist of the talk:-
Puppet is a great configuration management tool and git is great at version controlling.AWS lets you create instances in few clicks. But when it comes to large deployments only automation(where tools come together) can make you productive and happy. I will take you through following.. Fog - The Ruby cloud services library and how it helps you to create vendor neutral cloud deployments, Puppet- Multi region puppet masters, Ruby- How Ruby pulls the strings together in EC2/ELB/RDS creation, Security group creation, IP authorization, Route53 DNS etc, Git- how we use git to version control deployment configs/configurations.

Avatar for hrahman

hrahman

May 26, 2012
Tweet

More Decks by hrahman

Other Decks in Technology

Transcript

  1. Cloud meets Fog & Puppet A Story of Version Controlled

    Infrastructure Habeeb Rahman | apigee | @habi_pk
  2. Git hooks Pre-update => puppet syntax checks (puppet parser, puppet

    lint) Post-update => sync with regional puppet masters
  3. Puppet Git branches => Puppet environments Single puppet master =>

    Test Dev Production manifests and files/data => Separate git repo Puppet masters per AWS regions Hiera: a pluggable hierarchical data store
  4. Cross service compatibility (multitude of services=> Storage, Compute, DNS…) Avoid

    vendor lock-in (Vendor independent=>EC2, Rackspace, Slicehost, Linode…) Power of Ruby
  5. Fog quick starter kit Look at the test suites (thanks

    to TDD) https://github.com/fog/fog/blob/master/tests/aws/requests/compute/instance_tests.rb
  6. Fog command line [root@zebra ~]$ less ~/.fog [root@zebra ~]$ fog

    testaws Welcome to fog interactive! :testaws provides AWS >>
  7. ec2 = Fog::Compute.new( provider: "AWS", aws_access_key_id: "KEY", aws_secret_access_key: "SECRET" )

    rsc = Fog::Compute.new( provider: "Rackspace", rackspace_api_key: "KEY", rackspace_username: "SECRET" ) ec2.servers.create( flavor_id: "c1.medium", image_id: "ami-6936fb00", # Ubuntu 10.04 LTS key_name: "mykeyname", groups: ["default"], ) rsc.servers.create( flavor_id: 5, # 4GB Memory image_id: 49, # Ubuntu 10.04 LTS name: 'my_server_name' )
  8. irb is your friend (ruby interactive shell) root@zebra:~/$ irb 1.9.3-p125

    :001 > irb alternative = > pry (gem install pry)