Class: AWSCDK::SSM::CfnAssociation::TargetProperty
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::SSM::CfnAssociation::TargetProperty
- Defined in:
- ssm/cfn_association.rb
Overview
Target is a property of the AWS::SSM::Association resource that specifies the targets for an SSM document in Systems Manager . You can target all instances in an AWS account by specifying the InstanceIds key with a value of * . To view a JSON and a YAML example that targets all instances, see the example "Create an association for all managed instances in an AWS account " later in this page.
Instance Attribute Summary collapse
-
#key ⇒ String
readonly
User-defined criteria for sending commands that target managed nodes that meet the criteria.
-
#values ⇒ Array<String>
readonly
User-defined criteria that maps to
Key.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(key:, values:) ⇒ TargetProperty
constructor
A new instance of TargetProperty.
- #to_jsii ⇒ Object
Constructor Details
#initialize(key:, values:) ⇒ TargetProperty
Returns a new instance of TargetProperty.
856 857 858 859 860 861 |
# File 'ssm/cfn_association.rb', line 856 def initialize(key:, values:) @key = key Jsii::Type.check_type(@key, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "key") @values = values Jsii::Type.check_type(@values, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "values") end |
Instance Attribute Details
#key ⇒ String (readonly)
User-defined criteria for sending commands that target managed nodes that meet the criteria.
867 868 869 |
# File 'ssm/cfn_association.rb', line 867 def key @key end |
#values ⇒ Array<String> (readonly)
User-defined criteria that maps to Key .
For example, if you specified tag:ServerRole , you could specify value:WebServer to run a command on instances that include EC2 tags of ServerRole,WebServer .
Depending on the type of target, the maximum number of values for a key might be lower than the global maximum of 50.
876 877 878 |
# File 'ssm/cfn_association.rb', line 876 def values @values end |
Class Method Details
.jsii_properties ⇒ Object
878 879 880 881 882 883 |
# File 'ssm/cfn_association.rb', line 878 def self.jsii_properties { :key => "key", :values => "values", } end |
Instance Method Details
#to_jsii ⇒ Object
885 886 887 888 889 890 891 892 |
# File 'ssm/cfn_association.rb', line 885 def to_jsii result = {} result.merge!({ "key" => @key, "values" => @values, }) result.compact end |