AWS::Serverless::Function RestApiId 指定不在該 cloudformation 的 API Gateway ID

0
  1. 我們在 cloudformation template yaml 中,已經設定了超過 500 個 resource(N 個 lambda 和 1 個 API Gateway )
  2. 因為超過 500 個 resource ,因此無法使用 sam deploy 到 AWS
  3. 我們會把 resource 拆開,至少拆成兩個 template ,而且 deploy 到各別的 cloudformation
  4. 但是希望這兩個 cloudformation 中的 lambda 共用同一個 API Gateway
  5. 實際作法在第一個 template yaml 中,設定 N 個 lambda 和一個 API Gateway(testApi) , N 個 lambda 的 Events->getEndpoint->Properties->RestApiId: !Ref testApi
  6. 問題,第二個 template yaml 中的 lambda, 該如何設定 RestApiId 可以指向 testApi 模板
asked a month ago1449 views
No Answers

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions