From Fedora Project Wiki

< Cloud SIG

Revision as of 18:48, 29 July 2011 by Jforbes (talk | contribs) (Created page with "== Intro == Creating your own custom images for EC2 is a quick and easy process. While there are many ways to create an EC2 image, this page will walk you through using [http://...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Intro

Creating your own custom images for EC2 is a quick and easy process. While there are many ways to create an EC2 image, this page will walk you through using boxgrinder. Boxgrinder is chosen here because the packages are in fedora, and it is a simple process that anyone can use. The Cloud SIG maintains basic appliance definition files in the cloud-kickstarts git repository on fedorahosted.org

Local creation or EC2 based creation

For boxgrinder to generate images, you will need to have boxgrinder installed somewhere. Simple enough, though you have a couple of options here. Boxgrinder can be installed on your fedora host by running:

'yum install rubygem-boxgrinder-core rubygem-boxgrinder-build'

Or, if you would rather have the image creation and publish happen on AMI hosts, you can run boxgrinder in one of the project supported meta-appliances.

Configuration

Whichever route you choose, a little bit of configuration is required. First, you will need a config file with a little information about your Amazon AWS account. Put the following BoxGrinder config into a file named: /root/.boxgrinder/config. Insert appropriate values, see: http://boxgrinder.org/tutorials/boxgrinder-build-plugins/#S3_Delivery_Plugin, for more information.

plugins:
  s3:
    access_key: AWS_ACCESS_KEY                        # (required)
    secret_access_key: AWS_SECRET_ACCESS_KEY          # (required)
    bucket: stormgrind-test                           # (required)
    account_number: 0000-0000-0000                    # (required)
    path: /images                                     # default: /
    cert_file: /home/a/cert-ABCD.pem                  # required only for ami type
    key_file: /home/a/pk-ABCD.pem                     # required only for ami type
  ebs:
    access_key: AWS_ACCESS_KEY                        # required
    secret_access_key: AWS_SECRET_ACCESS_KEY          # required
    account_number: AWS_ACCOUNT_NUMBER                # required
    delete_on_termination: false                      # default: true
Warning.png
BoxGrinder Build config file location
The default location for this file is /root/.boxgrinder/config. You can put this file in different location by specifying BG_CONFIG_FILE environment variable.