Sha256: 12f215ac268cec94c31e67e5c5569fd0ffaea6e35252edd9d05c927893ef8f55

Contents?: true

Size: 861 Bytes

Versions: 29

Compression:

Stored size: 861 Bytes

Contents

module Lono::Sets::Preview
  # Inherits from Lono::Cfn::Preview::Param and override what's needed:
  #
  #      stack_parameters
  #
  class Param < Lono::Cfn::Preview::Param
    def run
      return unless stack_set_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

    def stack_parameters
      stack_set_parameters
    end

    def stack_set_parameters
      resp = cfn.describe_stack_set(stack_set_name: @stack)
      resp.stack_set.parameters
    end
  end
end

Version data entries

29 entries across 29 versions & 1 rubygems

Version Path
lono-7.5.2 lib/lono/sets/preview/param.rb
lono-7.5.1 lib/lono/sets/preview/param.rb
lono-7.5.0 lib/lono/sets/preview/param.rb
lono-7.4.11 lib/lono/sets/preview/param.rb
lono-7.4.10 lib/lono/sets/preview/param.rb
lono-7.4.9 lib/lono/sets/preview/param.rb
lono-7.4.8 lib/lono/sets/preview/param.rb
lono-7.4.7 lib/lono/sets/preview/param.rb
lono-7.4.6 lib/lono/sets/preview/param.rb
lono-7.4.5 lib/lono/sets/preview/param.rb
lono-7.4.4 lib/lono/sets/preview/param.rb
lono-7.4.3 lib/lono/sets/preview/param.rb
lono-7.4.2 lib/lono/sets/preview/param.rb
lono-7.4.1 lib/lono/sets/preview/param.rb
lono-7.4.0 lib/lono/sets/preview/param.rb
lono-7.3.2 lib/lono/sets/preview/param.rb
lono-7.3.1 lib/lono/sets/preview/param.rb
lono-7.3.0 lib/lono/sets/preview/param.rb
lono-7.2.3 lib/lono/sets/preview/param.rb
lono-7.2.2 lib/lono/sets/preview/param.rb