3
2

More than 1 year has passed since last update.

Lambda Layersの設定 Layer設定するだけでrequestsが使える

Last updated at Posted at 2022-06-24

lambdaで必要なライブラリはzipであげないといけないんですが...

皆んながよく使うやつは、Layerってとこに設定すればよいんです

で、有志でこんなもが。
https://api.klayers.cloud//api/v2/p3.8/layers/latest/ap-northeast-1/html
https://api.klayers.cloud//api/v2/p3.9/layers/latest/ap-northeast-1/html

このARNをLayerに設定するだけ、すてき!

requestsの設定の仕方

コード の下

コードソース

コードのプロパティ

ランタイム設定

レイヤー
の右「レイヤーの追加」

  1. レイヤーソース > 「ARNを指定」を選択
  2. ARNを指定のテキストフィールドに
  3. ここから入れたいものをさがして、そのarn欄をコピペ
    https://api.klayers.cloud//api/v2/p3.8/layers/latest/ap-northeast-1/html
    https://api.klayers.cloud//api/v2/p3.9/layers/latest/ap-northeast-1/html
    今回は「requests」の latest の arn
    スクリーンショット 2022-06-24 11.33.19.png
  4. 「保存」

で設定完了!!
スクリーンショット 2022-06-24 11.40.19.png

3
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
3
2