Skip to content

Commit efe5561

Browse files
committed
Add missing ASG tag
1 parent 0e30a1b commit efe5561

File tree

2 files changed

+13
-1
lines changed

2 files changed

+13
-1
lines changed

cdk/lib/__snapshots__/notification.test.ts.snap

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -274,6 +274,11 @@ exports[`The Notification stack matches the snapshot for CODE 1`] = `
274274
"PropagateAtLaunch": true,
275275
"Value": "guardian/mobile-n10n",
276276
},
277+
{
278+
"Key": "gu:riffraff:new-asg",
279+
"PropagateAtLaunch": true,
280+
"Value": "true",
281+
},
277282
{
278283
"Key": "LogKinesisStreamName",
279284
"PropagateAtLaunch": true,
@@ -2458,6 +2463,11 @@ exports[`The Notification stack matches the snapshot for PROD 1`] = `
24582463
"PropagateAtLaunch": true,
24592464
"Value": "guardian/mobile-n10n",
24602465
},
2466+
{
2467+
"Key": "gu:riffraff:new-asg",
2468+
"PropagateAtLaunch": true,
2469+
"Value": "true",
2470+
},
24612471
{
24622472
"Key": "LogKinesisStreamName",
24632473
"PropagateAtLaunch": true,

cdk/lib/notification.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import {
1111
} from '@guardian/cdk/lib/constructs/core';
1212
import { GuAllowPolicy } from '@guardian/cdk/lib/constructs/iam';
1313
import type { App } from 'aws-cdk-lib';
14-
import { Duration } from 'aws-cdk-lib';
14+
import { Duration, Tags } from 'aws-cdk-lib';
1515
import type { CfnAutoScalingGroup } from 'aws-cdk-lib/aws-autoscaling';
1616
import { Table } from 'aws-cdk-lib/aws-dynamodb';
1717
import { InstanceClass, InstanceSize, InstanceType } from 'aws-cdk-lib/aws-ec2';
@@ -166,6 +166,8 @@ export class Notification extends GuStack {
166166
const cfnAsg = autoScalingGroup.node.defaultChild as CfnAutoScalingGroup;
167167
cfnAsg.healthCheckGracePeriod = Duration.seconds(400).toSeconds();
168168

169+
Tags.of(autoScalingGroup).add('gu:riffraff:new-asg', 'true');
170+
169171
adjustCloudformationParameters(this);
170172

171173
// This is necessary whilst dual-stacking because there is already a parameter called VpcId in the YAML template

0 commit comments

Comments
 (0)