Code Monkey home page Code Monkey logo

chef-cookbooks's Introduction

Description

This repository contains a collection of chef cookbooks that can be used to deploy, and manage, the suite of OpenStack core projects (nova, glance, keystone, swift, horizon). User documentation is available in our knowledge center! The rest of this documentation is primarily aimed at developers who want to hack on the cookbooks.

The cookbooks have been designed and written in such a way that they can be used to deploy individual service components on any of the nodes in the infrastructure; in short they can be used for single node 'all-in-one' installs (for testing), right up to multi/many node production installs.

In order to achieve this flexibility, they make use of the chef search functionality, and therefore require that if you are deploying anything larger than a single node deployment, you use chef server to host your cookbooks rather than using chef solo.

Cookbooks

Each of the cookbooks in the cookbooks directory is actually a git submodule, linking to an individual git repository where that cookbook is maintained.

Roles

There are a number of different chef roles that are included with these cookbooks. Descriptions of each of the roles can be found in the readme in the roles directory.

Network configuration

Network configuration is stored in Chef environment. Please see environments/example.json and networking documentation.

Usage

getting the cookbooks
  • clone the parent repository (note the --recursive flag - this will ensure that each of the repositories that the submodules point to is also cloned):

git clone --recursive [email protected]:rcbops/chef-cookbooks.git

  • upload your cookbooks and roles to your chef server( assuming you have already configured your knife client with the credentials of your chef server:

cd chef-cookbooks
knife cookbook upload -o cookbooks --all
knife role from file roles/*.rb

using the cookbooks

NOTE: You must use chef >= 0.10.12 NOTE: If you are using Red Hat Enterprise Linux you must use RHEL >= 6 and you must enable the repository rhel-x86_64-server-optional-6

Ensure you have registered, one or more nodes with your chef server. Then use knife to assign roles to your nodes:

  • for an all-in-one deployment of nova, using keystone and glance, on a node called node1:

knife node run_list add node1 'role[allinone]'

  • for a 2 node deployment of nova, installing all nova controller functions, keystone and glance on node1, and setting node2 up as a compute server:

knife node run_list add node1 'role[single-controller]'
knife node run_list add node2 'role[single-compute]'

  • for a multi node deployment as above but with 'N' nova compute nodes

knife node run_list add node1 'role[single-controller]'
knife node run_list add node2 'role[single-compute]'
knife node run_list add node3 'role[single-compute]'
...
knife node run_list add node[n] 'role[single-compute]'

  • for a many node deployment with mysql and keystone on one node, nova core functions and horizon on another, glance on another, rabbitmq on another, and 'N' compute nodes:

knife node run_list add node1 'role[keystone]'
knife node run_list add node1 'role[mysql-master]'
knife node run_list add node2 'role[nova-controller]'
knife node run_list add node2 'role[horizon-server]'
knife node run_list add node3 'role[glance-api]'
knife node run_list add node3 'role[glance-registry]'
knife node run_list add node4 'role[rabbitmq-server]'
knife node run_list add node5 'role[single-compute]'
knife node run_list add node6 'role[single-compute]'
...
knife node run_list add nodeN 'role[single-compute]'

Custom template banners

You can define a custom string to be included in every template file managed by the Rackspace cookbooks by defining the custom_template_banner environment variable. For Example:

knife environment edit <environment name> "override_attributes": { "custom_template_banner": "# This\n# is\n# a\n# multiline\n# message"

License and Author

Author:: Justin Shepherd ([email protected])
Author:: Jason Cannavale ([email protected])
Author:: Ron Pedde ([email protected])
Author:: Joseph Breu ([email protected])
Author:: William Kelly ([email protected])
Author:: Darren Birkett ([email protected])
Author:: Evan Callicoat ([email protected])
Author:: Andy McCrae ([email protected])

Copyright 2012, Rackspace US, Inc.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

chef-cookbooks's People

Contributors

andymcc avatar apsu avatar brc avatar breu avatar claco avatar cloudnull avatar doublerr avatar galstrom21 avatar git-harry avatar hughsaunders avatar ilyash avatar jcannava avatar john5223 avatar mancdaz avatar mattt416 avatar paulczar avatar rcbjenkins avatar rpedde avatar rpedde-rcbops avatar willkelly avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.