LAMBDA deployment to different env based on version

0

Hello,

We are have dev and stage api gateway url in same aws account, would like to deploy to different version of lambda in these two environment.

dev https://********.execute-api.ap-southeast-2.amazonaws.com/dev

Stage https://*********.execute-api.ap-southeast-2.amazonaws.com/stage

Can you say how to achieve this in aws codepipeline (cloudformation). Let me know if you required more info.

1回答
0

Hi,

given you have both API and lambda in same account you could use Lambda aliases (https://docs.aws.amazon.com/lambda/latest/dg/configuration-aliases.html).

You can :

  • create two aliases for your lambda, DevAlias and StageAlias
  • Associate same or different Lambda version to them
  • Associate the lambda aliases as lambda integrations with the API Gateway.

I would look into Code Deploy abilities to perform Canary deployment for Lambda aliases. Some references:

Hope it helps

profile picture
エキスパート
回答済み 1年前

ログインしていません。 ログイン 回答を投稿する。

優れた回答とは、質問に明確に答え、建設的なフィードバックを提供し、質問者の専門分野におけるスキルの向上を促すものです。

質問に答えるためのガイドライン

関連するコンテンツ