Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a construct to redirect traffic to another domain with HTTPS support #3893

Closed
1 of 2 tasks
jogold opened this issue Aug 31, 2019 · 5 comments 路 Fixed by #3946
Closed
1 of 2 tasks

Add a construct to redirect traffic to another domain with HTTPS support #3893

jogold opened this issue Aug 31, 2019 · 5 comments 路 Fixed by #3946
Assignees
Labels
@aws-cdk/aws-route53 Related to Amazon Route 53 feature-request A feature should be added or improved.

Comments

@jogold
Copy link
Contributor

jogold commented Aug 31, 2019

馃殌 Feature Request

General Information

  • 馃憢 I am able to implement this feature request
  • 鈿狅笍 This feature might incur a breaking change

Description

Add a construct to redirect internet traffic to another domain and redirect HTTP requests to HTTPS

Proposed Solution

Implement the following https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/tutorial-redirecting-dns-queries.html using Route53, CloudFront, ACM and S3.

new HTTPSRedirect(this, 'Redirect', {
  fromDomain: 'example.com',
  toDomain: 'example.net',
  hostedZone: myHostedZone, // to create the record
});

To which package does this belong? I would say @aws-cdk/aws-route53 or @aws-cdk/aws-cloudfront...

@jogold jogold added feature-request A feature should be added or improved. needs-triage This issue or PR still needs to be triaged. labels Aug 31, 2019
@hoegertn
Copy link
Contributor

I have this as part of my website hosting construct. https://github.com/taimos/cdk-constructs/blob/master/lib/web/single-page-app.ts We can just move this part to CDK.

@jogold
Copy link
Contributor Author

jogold commented Sep 2, 2019

Great! You open the PR or should I?

(note: website configuration is now supported by Bucket, no need for CfnBucket)

@hoegertn
Copy link
Contributor

hoegertn commented Sep 2, 2019

I can do this. Where should I put it? It has several dependencies...

@jogold
Copy link
Contributor Author

jogold commented Sep 2, 2019

I would say that it fits in @aws-cdk/aws-route53... @eladb opinion on this?

@eladb
Copy link
Contributor

eladb commented Sep 3, 2019

looks like @aws-cdk/aws-route53-patterns

@NGL321 NGL321 added the @aws-cdk/aws-route53 Related to Amazon Route 53 label Sep 5, 2019
@NGL321 NGL321 removed the needs-triage This issue or PR still needs to be triaged. label Sep 5, 2019
eladb pushed a commit that referenced this issue Sep 16, 2019
This implements an HTTPS redirect using a CloudFront distribution and an S3 bucket. (fix #3893)
eladb pushed a commit that referenced this issue Sep 23, 2019
This implements an HTTPS redirect using a CloudFront distribution and an S3 bucket. (fix #3893)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
@aws-cdk/aws-route53 Related to Amazon Route 53 feature-request A feature should be added or improved.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants