Skip to content

Commit

Permalink
Merge pull request #188 from vrk-kpa/REKDAT-73_cdk-stack-termination-…
Browse files Browse the repository at this point in the history
…protections

REKDAT-73: Add termination protection to DB/FS stacks
  • Loading branch information
bzar authored Apr 23, 2024
2 parents b900b3e + 366ed4d commit 422f9ff
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 5 deletions.
12 changes: 8 additions & 4 deletions cdk/bin/cdk.ts
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,8 @@ const DatabaseStackDev = new DatabaseStack(app, 'DatabaseStack-dev', {
backups: true,
backupPlan: BackupStackDev.backupPlan,
cacheNodeType: 'cache.t3.micro',
numCacheNodes: 1
numCacheNodes: 1,
terminationProtection: true
})

const LoadBalancerStackDev = new LoadBalancerStack(app, 'LoadBalancerStack-dev', {
Expand Down Expand Up @@ -175,7 +176,8 @@ const FileSystemStackDev = new FileSystemStack(app, 'FilesystemStack-dev', {
},
envProps: envProps,
environment: devStackProps.environment,
vpc: VpcStackDev.vpc
vpc: VpcStackDev.vpc,
terminationProtection: true
})


Expand Down Expand Up @@ -323,7 +325,8 @@ const DatabaseStackProd = new DatabaseStack(app, 'DatabaseStack-prod', {
backups: true,
backupPlan: BackupStackProd.backupPlan,
cacheNodeType: 'cache.t3.micro',
numCacheNodes: 1
numCacheNodes: 1,
terminationProtection: true
})

const LoadBalancerStackProd = new LoadBalancerStack(app, 'LoadBalancerStack-prod', {
Expand Down Expand Up @@ -375,7 +378,8 @@ const FileSystemStackProd = new FileSystemStack(app, 'FilesystemStack-prod', {
},
envProps: envProps,
environment: prodStackProps.environment,
vpc: VpcStackProd.vpc
vpc: VpcStackProd.vpc,
terminationProtection: true
})


Expand Down
1 change: 1 addition & 0 deletions cdk/lib/database-stack-props.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,6 @@ export interface DatabaseStackProps extends CommonStackProps {
backupPlan: aws_backup.BackupPlan;
cacheNodeType: string;
numCacheNodes: number;
terminationProtection: boolean;
}

1 change: 1 addition & 0 deletions cdk/lib/efs-stack-props.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,5 @@ import {aws_backup} from "aws-cdk-lib";

export interface EfsStackProps extends CommonStackProps {
vpc: ec2.IVpc;
terminationProtection: boolean;
}
1 change: 0 additions & 1 deletion cdk/lib/shield-stack.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ import {
import {Construct} from "constructs";

import {ShieldStackProps} from "./shield-stack-props";
import any = jasmine.any;


export class ShieldStack extends Stack {
Expand Down

0 comments on commit 422f9ff

Please sign in to comment.