Note: Please go to docs.rightscale.com to access the current RightScale documentation set. Also, feel free to Chat with us!
Home > Guides > Dashboard Users Guide > Design > Cookbooks > Actions > Download a Cookbook

Download a Cookbook

Table of Contents

Table of Contents

Overview

Downloading a cookbook allows you to get the contents of a cookbook that had been imported into your account. You can make changes to this on your machine locally and, if you want to bring it into RightScale and use it with a ServerTemplate, you can do so by adding it as a repository. 

Steps

  1. Go to Design > Cookbooks.
  2. Select the Cookbook you would like to download.
  3. Choose the version.
  4. Select Download
     

screen_DownloadaCookbook.png

 

  1. A .tar file of the cookbook will download. You can unzip this file to view the contents of the cookbook. A cookbook can contain the following folders and files:
    • attributes - Attributes are displayed as user-configurable inputs in the RightScale dashboard. Attributes are most commonly used in Chef recipes. In order for attributes to be displayed in the dashboard, they must be properly documented in the Chef metadata (metadata.rb). 
    • definitions - Definitions allow you to create new Resources by stringing together existing resources. 
    • providers - A provider consists of the platform-specific code that will be executed on a server based on its underlying system architecture. Whereas a Chef resource describes the desired task (e.g. install a package), it's the related Chef provider that actually provides the underlying code that's executed to accomplish the task. Instead of creating a single bash script that contains each supported option through a long list of If/Else statements, you can create a single Chef recipe that leverages existing Chef resources and providers that accomplish the same task in a more efficient and scalable manner.
    • recipes - Recipes are located inside of a Chef cookbook. A recipe is a script written in Chef's domain-specific language (DSL) that will be executed on a running instance. A ServerTemplate consists of scripts that are either RightScripts or Chef recipes. Similar to RightScripts, Chef recipes support variable substitution where inputs (called Chef attributes) allow a user to define values that will be used when the script is executed. A recipe can also contain Chef resources that are located in another cookbook of a referenced repository. 
    • templates - A template is a file written in a markup language that allows one to dynamically generate a file's final content based on variables or more complex logic. Templates are commonly used to manage configuration files with Chef.
    • MANIFEST
    • metadata.rb - Contains a Ruby DSL that's used to build the metadata.json file.  The metadata.rb file is a human readable version of the metadata.json file. When you create a new cookbook using knife, a metadata.rb will automatically be created for you. 
    • metadata.json - The actual meta-data file that's used by RightScale (which acts as the Chef Server) to understand the contents of the cookbook and how its components can be used.

For more information about using Chef in RightScale, see the Chef Cookbooks Developer Guide

 

Note: If you made changes to the file on your machine locally, you can upload that file to RightScale so you can add your cookbooks to ServerTemplates. For more information, see Add a Repository.  

You must to post a comment.
Last modified
09:34, 14 Aug 2013

Tags

This page has no custom tags.

Classifications

This page has no classifications.

Announcements

None


© 2006-2014 RightScale, Inc. All rights reserved.
RightScale is a registered trademark of RightScale, Inc. All other products and services may be trademarks or servicemarks of their respective owners.