After migrating a CloudFormation template to AWS SAM approach, when deploying template created with aws cloudformation package
, in CloudFormation I get error
Encountered unsupported property CodeUri
on all Lambda functions that are included in the template.
After investigation, it's clear that CodeUri property is not removed from the packaged template and AWS::Lambda::Function type doesn't support CodeUri property, although proper resources are uploaded to S3 as part of the package process (so package as such works).
Transform: 'AWS::Serverless-2016-10-31'
as per docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/… – Rudderhead