Class: AWSCDK::CloudFormation::CfnLambdaHook::StackRolesProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
cloud_formation/cfn_lambda_hook.rb

Overview

Specifies the stack roles for the StackFilters property type to include or exclude specific stacks from Hook invocations based on their associated IAM roles.

For more information, see CloudFormation Hooks stack level filters .

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(exclude: nil, include: nil) ⇒ StackRolesProperty

Returns a new instance of StackRolesProperty.

Parameters:

  • exclude (Array<String>, nil) (defaults to: nil)

    The IAM role ARNs for stacks you want to exclude.

  • include (Array<String>, nil) (defaults to: nil)

    The IAM role ARNs to target stacks associated with these roles.



769
770
771
772
773
774
# File 'cloud_formation/cfn_lambda_hook.rb', line 769

def initialize(exclude: nil, include: nil)
  @exclude = exclude
  Jsii::Type.check_type(@exclude, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "exclude") unless @exclude.nil?
  @include = include
  Jsii::Type.check_type(@include, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "include") unless @include.nil?
end

Instance Attribute Details

#excludeArray<String>? (readonly)

The IAM role ARNs for stacks you want to exclude.

The Hook will be invoked on all stacks except those initiated by the specified roles.



782
783
784
# File 'cloud_formation/cfn_lambda_hook.rb', line 782

def exclude
  @exclude
end

#includeArray<String>? (readonly)

The IAM role ARNs to target stacks associated with these roles.

Only stack operations initiated by these roles will invoke the Hook.



789
790
791
# File 'cloud_formation/cfn_lambda_hook.rb', line 789

def include
  @include
end

Class Method Details

.jsii_propertiesObject



791
792
793
794
795
796
# File 'cloud_formation/cfn_lambda_hook.rb', line 791

def self.jsii_properties
  {
    :exclude => "exclude",
    :include => "include",
  }
end

Instance Method Details

#to_jsiiObject



798
799
800
801
802
803
804
805
# File 'cloud_formation/cfn_lambda_hook.rb', line 798

def to_jsii
  result = {}
  result.merge!({
    "exclude" => @exclude,
    "include" => @include,
  })
  result.compact
end