-
Notifications
You must be signed in to change notification settings - Fork 3.9k
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
(route53-patterns): certificate-redirect-stack cannot reference ... Set crossRegionReferences=true to enable cross region references #29453
Comments
Can you share more about the details? Are you trying to build http redirect in a region out of |
Deploying in For a while, we've been using the deprecated Some warnings remained, and that's because Enabling this flag was intended to create the certificate in I don't see how it would work without |
PR that implemented this initially: #23575 (/cc @corymhall) I believe the integration test may be wrong here: https://github.com/aws/aws-cdk/pull/23575/files#diff-f979b7bb5df1e4840178e9c77eea1a18ccc87711a1dd71bf271d09ab60ec984dR14-R17 It doesn't specifically enable the flag, so it tests the old behavior. |
Repro: const app = new App({
postCliContext: {
"@aws-cdk/aws-route53-patters:useCertificate": true,
},
});
const props: StackProps = {
env: { account: "...", region: "eu-west-1" },
crossRegionReferences: true,
};
const stack = new Stack(app, "Redirect-Test-Stack", props);
new HttpsRedirect(stack, "redirect", {
zone: new route53.HostedZone(
this,
"HostedZone",
{
zoneName: "some.domain",
},
),
recordNames: [`integ.some.domain`],
targetDomain: "aws.amazon.com",
}); |
It appears that enabling I opened a draft PR here which shows the new error: Let's move discussion there. |
Describe the bug
I'm attempting to remove some deprecation and I set
"@aws-cdk/aws-route53-patters:useCertificate": "true"
however, I'm running into this error:My stack already has
crossRegionReferences: true
in its props.Expected Behavior
No error
Current Behavior
See error above
Reproduction Steps
cdk.json:
Possible Solution
I noticed that in here:
aws-cdk/packages/aws-cdk-lib/aws-route53-patterns/lib/website-redirect.ts
Lines 134 to 136 in 840ec97
crossRegionReferences: true
.That seems suspect; shouldn't that stack also enable cross-region references?
Additional Information/Context
No response
CDK CLI Version
2.130.0
Framework Version
No response
Node.js Version
20
OS
macOS
Language
TypeScript
Language Version
No response
Other information
No response
The text was updated successfully, but these errors were encountered: