SAM to deploy Image-Based Lambda

0

My Question: Can you create an ECR repository and an Image-backed lambda from a Dockerfile from my local via SAM without the need to build the image and upload it first outside of SAM? I was hoping I could define my Dockerfile, the relative file paths, and SAM would handle the rest.

Context: I want to use SAM to manage an ECR repository and the Docker image that will back a lambda function. I have attempted a combination of configurations in the SAM template including:

  • defining the ECR repository
  • using the Metadata to point to the Dockerfile that sits alongside the Lambda function (python)
  • Specifying the ImageURI
  • Specifying CodeURI

The error appears to be related to the fact that the image is not being added to ECR. Naturally, SAM rolls back the deploy, so I am trying to figure out where things are falling over.

profile picture
已提問 1 個月前檢視次數 122 次
沒有答案

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南