-
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
HostedZone: Referencing array attributes cross-stack breaks with Template Format Error #22846
Comments
Thanks for reporting this @surecloud-meason, I was able to reproduce this. I'm pretty stumped why this is occurring. Everything in the template is formatted correctly, there should be no validation errors occurring here. I've created a ticket for CloudFormation (P75318355), hopefully they'll be able to help out here. I'll let you know if there are any updates. Thanks! |
Ah, the issue is due to the result of the output
You could work around this for now by creating your own CfnOutput and referencing it directly in the other stack when needed |
Is this still an issue? Pretty sure this has been fixed by #22873 |
Yeah we can probably close this, I tested this prior to the change linked |
|
@peterwoodworth I just hit this with the latest version of CDK (2.147.2 (build f4b0897)) FYI. Basically the same setup - create a hosted zone in my main stack and trying to reference .hostedZoneNameServers when creating a |
As you can see in the docs @kbrownlees, it says that it will be undefined if its imported from another stack. I wish this was different, because It feels pretty dumb. |
Describe the bug
When referencing a HostedZoneNameServer from another stack the Output created is invalid and on deployment errors with:
"Template format error: Every Value member must be a string."
CDK Synth Cloudformation Snippet Generated:
Expected Behavior
The auto created output handles lists correctly for use within another stack.
Current Behavior
The deploy fails due to an cloudformation format error .
Reproduction Steps
DNS Stack:
Stack Referencing the above stack
Stack Instantiations
Possible Solution
No response
Additional Information/Context
No response
CDK CLI Version
2.50.0
Framework Version
No response
Node.js Version
v16.18.0
OS
Ubuntu 20.04
Language
Typescript
Language Version
No response
Other information
No response
The text was updated successfully, but these errors were encountered: