Method: Lono::Cfn::Preview::Param#run

Defined in:
lib/lono/cfn/preview/param.rb

#runObject



9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
# File 'lib/lono/cfn/preview/param.rb', line 9

def run
  return unless stack_exists?(@stack)

  generated_parameters # eager call generated_parameters so its output is above Parameter Diff Preview
  puts "Parameter Diff Preview:".color(:green)
  if @options[:noop]
    puts "NOOP CloudFormation parameters preview for #{@stack} update"
    return
  end

  write_to_tmp(existing_path, existing_params)
  write_to_tmp(new_path, new_params)

  show_diff(existing_path, new_path)
end