aws-cdk-lib.aws_ssm.CfnAssociation.TargetProperty

interface TargetProperty

LanguageType name
.NETAmazon.CDK.AWS.SSM.CfnAssociation.TargetProperty
Gogithub.com/aws/aws-cdk-go/awscdk/v2/awsssm#CfnAssociation_TargetProperty
Javasoftware.amazon.awscdk.services.ssm.CfnAssociation.TargetProperty
Pythonaws_cdk.aws_ssm.CfnAssociation.TargetProperty
TypeScript aws-cdk-lib » aws_ssm » CfnAssociation » TargetProperty

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 "Create an association for all managed instances in an AWS account " on the Examples page.

Example

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_ssm as ssm } from 'aws-cdk-lib';
const targetProperty: ssm.CfnAssociation.TargetProperty = {
  key: 'key',
  values: ['values'],
};

Properties

NameTypeDescription
keystringUser-defined criteria for sending commands that target managed nodes that meet the criteria.
valuesstring[]User-defined criteria that maps to Key .

key

Type: string

User-defined criteria for sending commands that target managed nodes that meet the criteria.


values

Type: string[]

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.