chef-partners/marketplace_ami

Name: marketplace_ami

Owner: Chef Partners

Description: The marketplace_ami cookbook provides a chef resource for publishing AMI's into the AWS Marketplace.

Created: 2015-08-19 01:06:25.0

Updated: 2016-03-12 01:36:45.0

Pushed: 2015-08-20 20:49:33.0

Homepage: null

Size: 124

Language: Ruby

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

marketplace_ami Cookbook

The marketplace_ami cookbook provides a chef resource for publishing AMI's into the AWS Marketplace. The resource will provision a new EC2 instance, converge your application cookbook, create an AMI and share it with AWS Marketplace. Optionally you can enable a security recipe that will remove sensitive data and a chef-client audit mode recipe that will audit the image for known AWS security policies.

Requirements

Chef 12.3.0 or higher. Chef Provisioning 1.2.0 or higher. Chef Provisioning AWS 1.2.1 or higher.

The latest versions are always recommended.

Cookbooks

Only to be used if chef-provisioning-aws has not been installed

Attributes

The attributes in this cookbook are used only by the the security recipe and audit controls.

Key Type Description Default
['marketplace_ami']['controls']['cloud_init_enabled'] Boolean Whether or not the security audit should expect cloud-init to installed true
['marketplace_ami']['controls']['default_user'] String The default user for SSH access ec2-user
['marketplace_ami']['controls']['login_shell'] String The default users login_shell /bin/bash
Resources
marketplace_ami

Creates an AWS Marketplace AMI

Actions Properties
Usage

Before you being you'll need to properly set up valid EC2 credentials on the node that will be converging the recipe.

Update the metadata.rb of your application's cookbook to depend on 'marketplace_ami'

ur_application/metadata.rb

 'your_application'

nds 'marketplace_ami'

Create a publishing recipe that utilizes the marketplace_ami resource to build your Marketplace AMI

ur_application/recipes/ami_publisher.rb

etplace_ami "your_application-#{node['your_application']['version']}" do
stance_type   't2.medium'
urce_image_id 'ami-123456'
h_keyname     'publisher'
h_keypath     '~/.aws/publisher.pem'
h_username    'ec2-user'
oduct_code    '123799879'
curity        true
dit           true

le 'company_wide_role'
cipe 'your_application::setup'
cipe 'your_application::install'
tribute %w(your_application tofu), 'yes'
tribute %w(your_application brocolli), 'more_please'

tion :create

Run the chef-client!

License and Authors

Author:: Chef Partner Engineering (partnereng@chef.io)


This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.