OpenStack Deployment with Chef Workshop

  • Published on
    08-May-2015

  • View
    1.793

  • Download
    0

Embed Size (px)

DESCRIPTION

OpenStack Deployment with Chef Workshop at the 2013 Hong Kong OpenStack Summit. Co-presented with Justin Shepherd, a Private Cloud Architect from Rackspace.

Transcript

<ul><li>1.Friday, November 8, 13</li></ul> <p>2. OpenStack Deployment with Chef Workshop November 8, 2013 Justin Shepherd Matt RayFriday, November 8, 13 3. Getting Started Instructions: http://bit.ly/HKchef Download mirrors at: http://119.9.70.64 http://192.168.1.10 SSID 'opscode-dd-wrt' Background then deep-dive walkthrough Friday, November 8, 13 4. Introductions Justin Shepherd Rackspace Private Cloud ArchitectMatt Ray Opscode Cloud Integrations Leadjustin.shepherd@rackspace.commatt@opscode.comGitHub: galstrom21GitHub: mattrayIRC: galstromIRC: mattrayTwitter: mattrayFriday, November 8, 13 5. Overview &amp; Current Status of Chef for OpenStack Friday, November 8, 13 6. Chef for OpenStack: Project Community around the automated deployment and management of OpenStack Reduce fragmentation and increase collaboration Deploying OpenStack is not "Secret Sauce" Project, not a 'Product' Apache 2 License Friday, November 8, 13 7. Community#openstack-chef on irc.freenode.net groups.google.com/group/opscode-chef-openstack @chefopenstackFriday, November 8, 13 8. Who's Involved? AT&amp;T Dell DreamHost Gap HP HubSpot IBM Friday, November 8, 13Korea Telecom Opscode Rackspace SUSE and many more 9. Chef Requirements Chef 11 Ruby 1.9.x Foodcritic, ChefSpec for testing attribute-driven by Environments platform logic in attributes currently packages-only installation Friday, November 8, 13 10. StackForge: Cookbooks "Official" OpenStack StackForge repositories github.com/stackforge/cookbook-openstack-* gated by review.openstack.org OpenStack services for Grizzly cookbooks block-storage, common, compute, dashboard, identity, image, metering, network, object-storage, orchestration Operational support cookbooks ops-database, ops-messaging Friday, November 8, 13 11. StackForge: Deployment Chef repository for deploying Grizzly example Environments and Roles example "All-in-One" Vagrant deployment github.com/stackforge/openstack-chef-repo Gated by review.openstack.org More single and multi-node testing coming Friday, November 8, 13 12. Reference Implementation Deployment examples in documentation All-in-One Compute Single Controller + N Compute more coming Will provide example HA configurations Operations outside of scope of core repository logging, monitoring, provisioning Friday, November 8, 13 13. docs.opscode.com/ openstack.html Friday, November 8, 13 14. Documentation docs.opscode.com/openstack.html Architecture Deployment Prerequisites Installation Development Cookbooks and Repositories Example Deployments github.com/opscode/chef-docs Creative Commons, no CLA required Friday, November 8, 13 15. Example Deployments Vagrant "All-in-One" for development/testing Developer lab deployment "1+N" Single controller, N compute boxes 5 boxes, consumer-grade hardware Opscode production deployment "HA+N" HA controller, N compute and storage 30 boxes, enterprise-grade hardware Friday, November 8, 13 16. StackForge: Grizzly Status Operating Systems: Ubuntu 12.04, openSUSE 12.3, SLES 11 SP2 Databases: MySQL, SQLite (testing) Messaging: RabbitMQ Compute: KVM, LXC, Qemu Network: Nova + Quantum (Open vSwitch) Block Storage: LVM Object Storage: Swift Dashboard: Apache or Nginx Friday, November 8, 13 17. StackForge: Roadmap branching for Havana soon 'master' moved to 'grizzly' metering and orchestration cookbooks already started More contributors! Icehouse branch Friday, November 8, 13 18. StackForge: Roadmap Operating Systems: Red Hat 6 Databases: DB2, Postgres Compute: Baremetal, Docker, ESX, Hyper-V, Xen Messaging: Qpid Network: NSX, OpenDaylight Block Storage: Ceph, NetApp Object Storage: Ceph Source builds via Omnibus Friday, November 8, 13 19. Opscode Community SummitDeveloper/Community unconference November 12 &amp; 13 in Seattle, WA wiki.opscode.com/display/chef/ Community+Summit+3+-+2013Friday, November 8, 13 20. knife openstack Friday, November 8, 13 21. knife openstack $ knife openstack Available openstack subcommands: (for details, knife SUB-COMMAND --help) ** OPENSTACK COMMANDS ** knife openstack flavor list (options) knife openstack group list (options) knife openstack image list (options) knife openstack server create (options) knife openstack server delete SERVER [SERVER] (options) knife openstack server list (options) Friday, November 8, 13 22. knife openstack flavor list $ knife openstack flavor list ID Name Virtual CPUs RAM 1 m1.tiny 1 512 MB 2 m1.small 1 2048 MB 3 m1.medium 2 4096 MB 4 m1.large 4 8192 MB 5 m1.xlarge 8 16384 MBFriday, November 8, 13Disk 0 GB 10 GB 10 GB 10 GB 10 GB 23. knife openstack group list $ knife openstack group list Name Protocol From To default tcp 22 22 default icmp -1 -1 haproxy tcp 22002 22002Friday, November 8, 13CIDR 0.0.0.0/0 0.0.0.0/0 0.0.0.0/0Description default default 22022 24. knife openstack image list $ knife openstack image list IDNameSnapshot03860dc3-f4b5-4ecf-bb13-804d6618cf15canonical-ubuntu-10.04-amd64no663656ce-2fe4-4164-b842-214f221cff55canonical-ubuntu-12.04-amd64noad8a6e48-ea86-4afc-8aee-f427c02eb3cecanonical-ubuntu-13.04-amd64no6efbafc0-fcb1-4623-9f7a-17125bba413acentos-6.2noe0184596-577f-4eb0-9887-d70117c6b77bdebian-6.0.4-amd64noFriday, November 8, 13 25. knife openstack server list $ knife openstack server list Instance IDNamePublic IP08f2d9f7-eeb0-45e7-8562-63aed8f096ccos-4553934572330937743c6bbf5-b397-4986-8aec-392d955ce5b1FlavorImageKeypairState50.56.12.2292737969f8-6091-4896-ba9c-f3cf63bd25c5rs-demoactiveos-992442669102041650.56.12.2322737969f8-6091-4896-ba9c-f3cf63bd25c5rs-demoactivec1b9e3df-e566-4378-8a52-ed998b516608os-55342571428708850.56.12.2302737969f8-6091-4896-ba9c-f3cf63bd25c5rs-demoactivef3edc5da-ef99-4acb-a141-d957e09809e3os-0745955028750068250.56.12.2312737969f8-6091-4896-ba9c-f3cf63bd25c5rs-demoactiveFriday, November 8, 13Private IP 26. knife openstack server create $ knife openstack server create -a -f 2 -I 737969f8-6091-4896-ba9c-f3cf63bd25c5 -S rs-demo -i ~/.ssh/rs-demo.pem -x ubuntu -r "role[base]" Instance Name: os-45539345723309377 Instance ID: 08f2d9f7-eeb0-45e7-8562-63aed8f096cc Waiting for server......... Flavor: 2 Image: 737969f8-6091-4896-ba9c-f3cf63bd25c5 SSH Identity File: /Users/mray/.ssh/rs-demo.pem SSH Keypair: rs-demo Public IP Address: 10.241.0.12 Floating IP Address: 50.56.12.229 Waiting for sshd.....done Bootstrapping Chef on 50.56.12.229 Instance Name: os-45539345723309377 Instance ID: 08f2d9f7-eeb0-45e7-8562-63aed8f096cc Flavor: 2 Image: 737969f8-6091-4896-ba9c-f3cf63bd25c5 SSH Keypair: rs-demo Public IP Address: 50.56.12.229 Environment: _default Run List: role[base]Friday, November 8, 13 27. knife openstack server createFriday, November 8, 13 28. knife openstack Compatibility Uses the OpenStack API Diablo, Essex, Folsom, Grizzly, Havana, trunk Cloudscaling Crowbar DreamHost MetaCloud Nebula Piston Rackspace Private Cloud Friday, November 8, 13 29. knife openstack Resources knife openstack --help docs.opscode.com/ plugin_knife_openstack.html github.com/opscode/knife-openstack tickets.opscode.com/browse/KNIFE/ component/Friday, November 8, 13 30. knife openstack Roadmap Continuous Integration for Opscodesupported knife plugins soon Testing against multiple deployments 0.9.0: json, API choices, alt networks 1.0.0: common knife-cloud base class 1.1.0: Network enhancements 1.2.0 guid cleanup, other niceties Friday, November 8, 13 31. Vagrant All-in-One Walkthrough Friday, November 8, 13 32. "The Plan" Setup Tools Vagrantfile Environment Roles Cookbooks Dashboard knife openstack Friday, November 8, 13 33. Setup Instructions: http://bit.ly/HKchef Vagrant + Virtualbox installed Workshop.tar.gz/zip downloaded and unpacked Download Ubuntu 12.04 boxFriday, November 8, 13 34. Tools used Bento JEOS images github.com/opscode/bento Packer image builder packer.io Chef Zero Berkshelf Friday, November 8, 13 35. Vagrantfile Vagrant plugins vagrant-berkshelf vagrant-chef-zero vagrant-omnibus chef-client provider environment = vagrant run_list = [ "recipe[apt]", "role[allinonecompute]" ] Friday, November 8, 13 36. Environmentvagrant setup for all-in-one developer_mode = true services each have attributes network setupFriday, November 8, 13 37. Rolesallinone-compute os-compute-single-controller os-compute-workerFriday, November 8, 13 38. os-compute-single-controller os-base os-ops-database openstack-ops-database::openstack-db os-ops-messaging os-identity os-image os-network ... Friday, November 8, 13 39. os-compute-single-controller 2 os-compute-setup os-compute-conductor os-compute-scheduler os-compute-api os-block-storage os-compute-cert os-compute-vncproxy os-dashboard Friday, November 8, 13 40. os-compute-worker os-base openstack-compute::computeFriday, November 8, 13 41. Dashboardhttp://localhost:8443 admin/adminFriday, November 8, 13 42. knife-openstackChef Zero creds OpenStack creds knife openstack ...Friday, November 8, 13 43. Thanks! Justin Shepherd justin.shepherd@rackspace.com Matt Ray matt@opscode.comFriday, November 8, 13 </p>