-
Notifications
You must be signed in to change notification settings - Fork 4k
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βll occasionally send you account related emails.
Already on GitHub? Sign in to your account
@aws-cdk/aws-certificatemanager.Certification to support Global certificate creation #3556
Comments
CloudFormation (and by extension the CDK) deploys resources into the region in which the CloudFormation stack lives (with the exception of StackSets). Would this be considered a bit of an anti-pattern for CloudFormation, and therefore the CDK? It almost sounds like the ACM certificate is being coupled to something else - Have you considered decoupling it, and using env props to specify a deploy region for the certificate stack? Personally, I'd create a certificate stack in the 'global' region (aka A little something like this, perhaps? Edit: I misread - You're asking for the ability to prevent the module from attempting to create the Route53 records, because the zone exists outside of the account? |
@jordankueh You are quite right in your first read - though I do have another issue open regarding cross account deployments and Route53 #3470. I am essentially asking to be able to issue a certificate in a different region from the CloudFormation stack. This isn't so much a design decision but how this particular part of AWS works. CloudFront (a global service) requires an ACM certificate (regional service) to be issued in us-east-1 but is configured with an origin which resides in eu-west-1. To avoid the problem the stack would have to be deployed entirely to us-east-1 which isn't the right fit for the solution. It's a pretty light stack and splitting in to multiple stacks doesn't seem sensible. Though, nested stacks are an option but would need to wait for nested stack support in CDK. Maybe I do need to reconsider my approach here. However, while somewhat of an anti-pattern the president has already been set and the ability to deploy a stack in a specific region with a certificate in a different region is already there with |
@PhilKershaw I appreciate the clarification - And I'm familiar with the CloudFront conundrumβ’, so I empathise! π I suspect what's happened here is when Considering that there'd be a bit of ClickOpsβ’ for validating the certificate anyway, you could justify it as a separate stack that way... Until they support the region parameter ;) |
We are unfortunately not able to create regular You could automate this by writing your own custom resource, and you could share your implementation with others via NPM, but I'm not sure the base construct library is a place for a resource that does this. |
So I find this really weird, I do everything via CDK, in region AP-southeast-2, and now I noticed that creating the Certificate and linking it to my cloudfront doesnt work, because the CDK will create the certificate in the region of the profile used during deploy.
Since I do all this in CDK, it doesn't make sense to give this example in https://docs.aws.amazon.com/cdk/api/latest/docs/aws-certificatemanager-readme.html. Is it an idea to add a |
I'm submitting a ...
What is the current behaviour?
When creating a certificate like:
The certificate is created in the region specified in the profile.
As is with the ability to specify whether the certificate should be global - i.e. for CloudFront - or adding the ability to customise the region, though this option seems overkill.
Would like to create an ACM Certificate for a domain not yet managed via Route53 - so not able to leverage
DnsValidatedCertificate
, where region can be specified - in order to provision CloudFront in front of an S3 bucket.Please tell us about your environment:
Other information (e.g. detailed explanation, stacktraces, related issues, suggestions how to fix, links for us to have context, eg. associated pull-request, stackoverflow, gitter, etc)
Related to #3464
The text was updated successfully, but these errors were encountered: