Skip to content
v2.277.0

EC2TagSetProperty Struct ​

The EC2TagSet property type specifies information about groups of tags applied to Amazon EC2 instances.

The deployment group includes only Amazon EC2 instances identified by all the tag groups. EC2TagSet cannot be used in the same template as EC2TagFilter .

For information about using tags and tag groups to help manage your Amazon EC2 instances and on-premises instances, see Tagging Instances for Deployment Groups in AWS CodeDeploy .

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_codedeploy as codedeploy } from 'aws-cdk-lib';
const eC2TagSetProperty: codedeploy.CfnDeploymentGroup.EC2TagSetProperty = {
  ec2TagSetList: [{
    ec2TagGroup: [{
      key: 'key',
      type: 'type',
      value: 'value',
    }],
  }],
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_codedeploy as codedeploy

e_c2_tag_set_property = codedeploy.CfnDeploymentGroup.EC2TagSetProperty(
    ec2_tag_set_list=[codedeploy.CfnDeploymentGroup.EC2TagSetListObjectProperty(
        ec2_tag_group=[codedeploy.CfnDeploymentGroup.EC2TagFilterProperty(
            key="key",
            type="type",
            value="value"
        )]
    )]
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.codedeploy.*;

EC2TagSetProperty eC2TagSetProperty = EC2TagSetProperty.builder()
        .ec2TagSetList(List.of(EC2TagSetListObjectProperty.builder()
                .ec2TagGroup(List.of(EC2TagFilterProperty.builder()
                        .key("key")
                        .type("type")
                        .value("value")
                        .build()))
                .build()))
        .build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.CodeDeploy;

var eC2TagSetProperty = new EC2TagSetProperty {
    Ec2TagSetList = new [] { new EC2TagSetListObjectProperty {
        Ec2TagGroup = new [] { new EC2TagFilterProperty {
            Key = "key",
            Type = "type",
            Value = "value"
        } }
    } }
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

eC2TagSetProperty := &EC2TagSetProperty{
	Ec2TagSetList: []interface{}{
		&EC2TagSetListObjectProperty{
			Ec2TagGroup: []interface{}{
				&EC2TagFilterProperty{
					Key: jsii.String("key"),
					Type: jsii.String("type"),
					Value: jsii.String("value"),
				},
			},
		},
	},
}

Properties ​

ec2TagSetListoptionalIResolvable | IResolvable | CfnDeploymentGroup.EC2TagSetListObjectProperty[]ec2_tag_set_listoptionaltyping.Union[IResolvable, typing.List[typing.Union[IResolvable, EC2TagSetListObjectProperty]]]ec2TagSetListoptionalIResolvableEc2TagSetListoptionalIResolvableEc2TagSetListoptionalinterface{}#
The Amazon EC2 tags that are already applied to Amazon EC2 instances that you want to include in the deployment group.

CodeDeploy includes all Amazon EC2 instances identified by any of the tags you specify in this deployment group.

Duplicates are not allowed.