Class: Cucloud::CfnUtils
- Inherits:
-
Object
- Object
- Cucloud::CfnUtils
- Defined in:
- lib/cucloud/cfn_utils.rb
Overview
CFNUtils - Utilities for CloudFormation
Defined Under Namespace
Classes: UnknownServiceError
Instance Method Summary collapse
-
#create_stack(stack_name, template_json) ⇒ String
Create cloud formation stack from template.
-
#initialize(cfn = Aws::CloudFormation::Client.new) ⇒ CfnUtils
constructor
A new instance of CfnUtils.
-
#update_stack(stack_name, template_json) ⇒ String
Update cloud formation stack from template.
Constructor Details
#initialize(cfn = Aws::CloudFormation::Client.new) ⇒ CfnUtils
Returns a new instance of CfnUtils.
8 9 10 |
# File 'lib/cucloud/cfn_utils.rb', line 8 def initialize(cfn = Aws::CloudFormation::Client.new) @cfn = cfn end |
Instance Method Details
#create_stack(stack_name, template_json) ⇒ String
Create cloud formation stack from template
16 17 18 |
# File 'lib/cucloud/cfn_utils.rb', line 16 def create_stack(stack_name, template_json) manage_stack(stack_name, template_json) end |
#update_stack(stack_name, template_json) ⇒ String
Update cloud formation stack from template
24 25 26 |
# File 'lib/cucloud/cfn_utils.rb', line 24 def update_stack(stack_name, template_json) manage_stack(stack_name, template_json, :update_stack) end |