Skip to content

Commit

Permalink
Merge pull request #462 from guardian/mm-add-domain-for-fastly-dr-tes…
Browse files Browse the repository at this point in the history
…ting

Add a domain to be used in Fastly disaster recovery testing
  • Loading branch information
michaelwmcnamara authored Apr 11, 2024
2 parents 8778304 + ace3c9b commit bb8833d
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 0 deletions.
13 changes: 13 additions & 0 deletions cdk/lib/__snapshots__/cdk-playground.test.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ Object {
"GuApplicationTargetGroup",
"GuHttpsApplicationListener",
"GuCname",
"GuCname",
"GuApiLambda",
"GuCertificate",
"GuCname",
Expand Down Expand Up @@ -275,6 +276,18 @@ Object {
},
"Type": "Guardian::DNS::RecordSet",
},
"FastlyDRTestDNS": Object {
"Properties": Object {
"Name": "cdk-status-resources.guardianapis.com",
"RecordType": "CNAME",
"ResourceRecords": Array [
"dualstack.guardian.map.fastly.net",
],
"Stage": "PROD",
"TTL": 3600,
},
"Type": "Guardian::DNS::RecordSet",
},
"GetDistributablePolicyCdkplaygroundBFB4D02B": Object {
"Properties": Object {
"PolicyDocument": Object {
Expand Down
13 changes: 13 additions & 0 deletions cdk/lib/cdk-playground.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ export class CdkPlayground extends GuStack {

const ec2App = 'cdk-playground';
const ec2AppDomainName = 'cdk-playground.gutools.co.uk';
//New domain added for Fastly disaster recovery testing. Will be deleted after this testing is complete
//todo - delete fastlyTestDomainName once the Fastly disaster recovery testing is complete.
const fastlyDRTestDomainName = 'cdk-status-resources.guardianapis.com';

const { loadBalancer } = new GuPlayApp(this, {
app: ec2App,
Expand All @@ -50,6 +53,16 @@ export class CdkPlayground extends GuStack {
imageRecipe: 'developerPlayground-arm64-java11',
});

// This is a temporary domain name for use in some ongoing Fastly Disaster Recovery testing
// It will be removed after this testing is complete
// todo - remove this Cname after Fastly disaster recovery testing is complete
new GuCname(this, 'FastlyDRTestDNS', {
app: ec2App,
ttl: Duration.hours(1),
domainName: fastlyDRTestDomainName,
resourceRecord: 'dualstack.guardian.map.fastly.net',
});

new GuCname(this, 'EC2AppDNS', {
app: ec2App,
ttl: Duration.hours(1),
Expand Down

0 comments on commit bb8833d

Please sign in to comment.