Class: StackMaster::Commands::Nag
- Inherits:
-
Object
- Object
- StackMaster::Commands::Nag
- Includes:
- Commander::UI, StackMaster::Command
- Defined in:
- lib/stack_master/commands/nag.rb
Instance Method Summary collapse
Methods included from StackMaster::Command
included, #initialize, #success?
Instance Method Details
#perform ⇒ Object
7 8 9 10 11 12 13 14 15 16 |
# File 'lib/stack_master/commands/nag.rb', line 7 def perform rv = Tempfile.open(['stack', "___#{stack_definition.stack_name}.#{proposed_stack.template_format}"]) do |f| f.write(proposed_stack.template_body) f.flush system('cfn_nag', f.path) $?.exitstatus end failed!("cfn_nag check failed with exit status #{rv}") if rv > 0 end |