You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello, I'm creating several cross-env buckets via the aws cdk. Everything is fine when I use my own bucket names, but if I try to use cdk.PhysicalName.GENERATE_IF_NEEDED, it throws an exception that the account is unresolved or missing. When I try to print out the account number I get the sub: ${Token[AWS.AccountId.3]}. I'm not sure why the account number wouldn't resolve if the only thing I do differently is set my own bucket names vs. allowing cloudformation to pick. I just want to know if anyone actually got this to work or if it is even supported? Thanks in advance!
Error: Resolution error: Resolution error: Resolution error: Resolution error: Cannot generate a physical name for BucketStack1/Bucket, because the account is un-resolved or missing.
Object creation stack:
at stack traces disabled.
Object creation stack:
at stack traces disabled..
at generatePhysicalName (/Users/iljazi/Projects/React/CerberusCloud/node_modules/aws-cdk-lib/core/lib/private/physical-name-generator.js:1:1112)
at Bucket.generatePhysicalName (/Users/iljazi/Projects/React/CerberusCloud/node_modules/aws-cdk-lib/core/lib/resource.js:1:3568)
at Bucket._enableCrossEnvironment (/Users/iljazi/Projects/React/CerberusCloud/node_modules/aws-cdk-lib/core/lib/resource.js:1:2967)
at Object.produce (/Users/iljazi/Projects/React/CerberusCloud/node_modules/aws-cdk-lib/core/lib/resource.js:1:4422)
at Reference.resolve (/Users/iljazi/Projects/React/CerberusCloud/node_modules/aws-cdk-lib/core/lib/resource.js:1:4877)
at RememberingTokenResolver.resolveToken (/Users/iljazi/Projects/React/CerberusCloud/node_modules/aws-cdk-lib/core/lib/resolvable.js:1:1401)
at RememberingTokenResolver.resolveToken (/Users/iljazi/Projects/React/CerberusCloud/node_modules/aws-cdk-lib/core/lib/private/resolve.js:1:4134)
at resolve (/Users/iljazi/Projects/React/CerberusCloud/node_modules/aws-cdk-lib/core/lib/private/resolve.js:1:2711)
at Object.resolve [as mapToken] (/Users/iljazi/Projects/React/CerberusCloud/node_modules/aws-cdk-lib/core/lib/private/resolve.js:1:1079)
at TokenizedStringFragments.mapTokens (/Users/iljazi/Projects/React/CerberusCloud/node_modules/aws-cdk-lib/core/lib/string-fragments.js:1:1475)
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hello, I'm creating several cross-env buckets via the aws cdk. Everything is fine when I use my own bucket names, but if I try to use cdk.PhysicalName.GENERATE_IF_NEEDED, it throws an exception that the account is unresolved or missing. When I try to print out the account number I get the sub: ${Token[AWS.AccountId.3]}. I'm not sure why the account number wouldn't resolve if the only thing I do differently is set my own bucket names vs. allowing cloudformation to pick. I just want to know if anyone actually got this to work or if it is even supported? Thanks in advance!
Beta Was this translation helpful? Give feedback.
All reactions