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
This Action isn't compatible with SAM templates that use a local file path for the CodeUri property of a AWS::Serverless::Function resource.
The CodeUi property states
The function code's Amazon S3 URI, local file path, or FunctionCode object.
If an Amazon S3 URI or FunctionCode object is provided, the Amazon S3 object referenced must be a valid Lambda deployment package.
If a local file path is provided, for the code to be transformed properly the template must go through the workflow that includes the sam deploy or sam package command.
(emphasis added)
Attempting to use this Action with a Serverless transform template that contains a AWS::Serverless::Function resource using a local path for CodeUri results in CloudFormation producing this error during stack creation:
Transform AWS::Serverless-2016-10-31 failed with: Invalid Serverless Application Specification document.
Number of errors found: 1.
Resource with id [MyLambdaFunction] is invalid. 'CodeUri' is not a valid S3 Uri of the form 's3://bucket/key' with optional versionId query parameter.
In case anyone else runs into this issue, perform sam package and use --output-template-file to output the template to a file. Then pass that template file to this action.
This Action isn't compatible with SAM templates that use a local file path for the
CodeUri
property of aAWS::Serverless::Function
resource.The
CodeUi
property states(emphasis added)
Attempting to use this Action with a Serverless transform template that contains a
AWS::Serverless::Function
resource using a local path forCodeUri
results in CloudFormation producing this error during stack creation:Somewhat related to #32 and #33.
Since this requires SAM CLI to correctly deploy a stack, this functionality might instead belong in a separate
aws-sam-github-deploy
action.The text was updated successfully, but these errors were encountered: