(aws-sam): ContentUri in LayerVersion does not support S3 bucket/key #12413
Labels
@aws-cdk/aws-sam
Related to AWS Serverless Application Model
bug
This issue is a bug.
needs-triage
This issue or PR still needs to be triaged.
The
ContentUri
forAWS::Serverless::LayerVersion
requires the value to be a string in the CDK (https://docs.aws.amazon.com/cdk/api/latest/python/aws_cdk.aws_sam/CfnLayerVersion.html), but the spec allows it also be an S3 Location.string
| S3 Location ObjectThis is due to the SAM schema the CDK uses missing this additional type. This has now been fixed upstream (awslabs/goformation#339), but the PR to pull in this change into the CDK was closed (#12370). Can we get that PR reopened and merged?
Reproduction Steps
Create an
aws_sam.CfnLayerVersion
object. The content URI must be a string.What did you expect to happen?
I'd like to be able to specify an S3 bucket and key (in my case I'm using
aws_s3_assets.Asset
)What actually happened?
If you manually try to override this and provide your own s3 bucket/key you'll get a validation error as you'd expect because the schema doesn't support this.
Environment
This is 🐛 Bug Report
The text was updated successfully, but these errors were encountered: