Class: AwsAuditor::Scripts::StackAudit

Inherits:
Object
  • Object
show all
Extended by:
AWSWrapper, EC2Wrapper, OpsWorksWrapper
Defined in:
lib/aws_auditor/scripts/stack-audit.rb

Instance Attribute Summary

Attributes included from AWSWrapper

#aws

Attributes included from EC2Wrapper

#ec2

Attributes included from OpsWorksWrapper

#opsworks

Class Method Summary collapse

Class Method Details

.execute(environment) ⇒ Object



8
9
10
11
# File 'lib/aws_auditor/scripts/stack-audit.rb', line 8

def self.execute(environment)
  aws(environment)
  get_stacks
end

.get_stacksObject



13
14
15
16
17
18
19
20
# File 'lib/aws_auditor/scripts/stack-audit.rb', line 13

def self.get_stacks
  stacks = opsworks.describe_stacks
  stacks.data[:stacks].map do |stack|
    stck = Stack.new(stack)
    stck.pretty_print
    stck
  end if stacks
end