I have a cloudformation template for creating a security group as follows. It references tags.yaml
that contains pre-defined tags in a s3 bucket.
Resources:
EC2SecurityGroup:
Type: "AWS::EC2::SecurityGroup"
DeletionPolicy: Delete
Properties:
GroupDescription: Test Security Group.
GroupName: !Ref SecurityGroupName
SecurityGroupEgress:
- Description: Direct traffic to all destinations.
CidrIp: "0.0.0.0/0"
IpProtocol: -1
SecurityGroupIngress:
- Description: Sec. group of LB.
FromPort: 80
IpProtocol: tcp
SourceSecurityGroupId: sg-xxxxxxxx
ToPort: 80
VpcId: !Ref VPCId
"Fn::Transform":
Name: AWS::Include
Parameters:
Location: "s3://{bucket-name}/tags.yaml"
I want to now append/add additional tags in this template. Is that possible? I tried adding Tags
property but that didnt work. Example:
"Fn::Transform":
Name: AWS::Include
Parameters:
Location: "s3://{bucket-name}/tags.yaml"
Tags:
- Key: TestName
Value: DummyVal