Class: Swa::CloudFormation::Stack

Inherits:
Resource
  • Object
show all
Defined in:
lib/swa/cloud_formation/stack.rb

Instance Attribute Summary

Attributes inherited from Resource

#aws_resource

Instance Method Summary collapse

Methods inherited from Resource

#data, delegate, #initialize, list

Constructor Details

This class inherits a constructor from Swa::Resource

Instance Method Details

#idObject



10
11
12
# File 'lib/swa/cloud_formation/stack.rb', line 10

def id
  name
end

#last_modified_atObject



24
25
26
# File 'lib/swa/cloud_formation/stack.rb', line 24

def last_modified_at
  stack.last_updated_time || stack.creation_time
end

#outputsObject



40
41
42
# File 'lib/swa/cloud_formation/stack.rb', line 40

def outputs
  stackup_stack.outputs
end

#parametersObject



36
37
38
# File 'lib/swa/cloud_formation/stack.rb', line 36

def parameters
  stackup_stack.parameters
end

#resourcesObject



44
45
46
# File 'lib/swa/cloud_formation/stack.rb', line 44

def resources
  stackup_stack.resources
end

#summaryObject



14
15
16
17
18
19
20
# File 'lib/swa/cloud_formation/stack.rb', line 14

def summary
  [
    pad(name, 44),
    pad(stack.stack_status, 24),
    last_modified_at.iso8601
  ].join("  ")
end

#template_bodyObject



28
29
30
# File 'lib/swa/cloud_formation/stack.rb', line 28

def template_body
  stackup_stack.template_body
end

#template_dataObject



32
33
34
# File 'lib/swa/cloud_formation/stack.rb', line 32

def template_data
  stackup_stack.template
end