因为某些原因,我不知道为什么会出问题。
我已经创建了一个公共ECR存储库,并试图在我的AWS::Lambda::函数中的Code块下将该映像引用为Code。
SlackNotifierFunction:
Type: AWS::Lambda::Function
Properties:
FunctionName: !Join ["-", [!Ref Name, "slack", "notifier"]]
Role: !GetAtt LambdaRole.Arn
Code:
ImageUri: public.ecr.aws/g9c9m7n7/aws-cost-anomaly-slack-notifier:latest
Timeout: 1
MemorySize: 128
PackageType: Image
Architectures: ["arm64"]
Environment:
Variables:
LOG_LEVEL: INFO
SLACK_TOKEN: !Ref SlackToken
SLACK_CHANNEL: !Ref SlackChannelCloudFormation在创建Lambda函数时抛出以下错误。
源映像public.ecr.aws/g9c9m7n7/aws-cost-anomaly-slack-notifier:latest无效。提供有效的源映像(服务: Lambda,状态代码: 400,请求ID: 9150921d-4b35-44ae-a4eb-c137f2a779e9,扩展请求ID: null) (RequestToken: 616bb226-a46b-a46b-c959-aad09880b137,HandlerErrorCode: InvalidRequest)
这是ECR公共画廊链接:https://gallery.ecr.aws/g9c9m7n7/aws-cost-anomaly-slack-notifier
发布于 2021-11-16 23:17:37
从今天起,提供引用公共ECR库托管图像的图像uri似乎是不可能的。
https://stackoverflow.com/questions/69997144
复制相似问题