{"id":604,"date":"2020-01-19T10:00:00","date_gmt":"2020-01-19T01:00:00","guid":{"rendered":"https:\/\/p-corporate-blog-cms.mmmcorp.co.jp\/blog\/2020\/01\/19\/lambda_at_edge_redirect"},"modified":"2020-01-19T10:00:00","modified_gmt":"2020-01-19T01:00:00","slug":"lambda_at_edge_redirect","status":"publish","type":"post","link":"https:\/\/p-corporate-blog-cms.mmmcorp.co.jp\/blog\/2020\/01\/19\/lambda_at_edge_redirect\/","title":{"rendered":"\u30b5\u30a4\u30c8\u30ea\u30cb\u30e5\u30fc\u30a2\u30eb\u6642\u306eURL\u30ea\u30c0\u30a4\u30ec\u30af\u30c8\u3092Lambda@Edge\u3067\u5b9f\u73fe\u3059\u308b"},"content":{"rendered":"

\u5f0a\u793e\u3067\u306f\u6628\u5e749\u6708\u306b\u30b3\u30fc\u30dd\u30ec\u30fc\u30c8\u30b5\u30a4\u30c8\u3092\u30ea\u30cb\u30e5\u30fc\u30a2\u30eb\u3057\u307e\u3057\u305f\u3002<\/p>\n

\u30ea\u30cb\u30e5\u30fc\u30a2\u30eb\u306e\u7d4c\u7def\u306a\u3069\u306b\u3064\u3044\u3066\u306fMMM\u306e\u30b5\u30a4\u30c8\u30ea\u30cb\u30e5\u30fc\u30a2\u30eb\u306e\u7d4c\u7def<\/a>\u306b\u66f8\u3044\u3066\u3042\u308b\u306e\u3067\u3059\u304c\u3001\u30ea\u30cb\u30e5\u30fc\u30a2\u30eb\u306b\u4f34\u3044\u30b3\u30f3\u30c6\u30f3\u30c4\u306e\u69cb\u6210\u304c\u5909\u66f4\u306b\u306a\u308b\u305f\u3081\u3001URL\u3082\u5909\u66f4\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3057\u305f\u3002<\/p>\n

URL\u306e\u5909\u66f4\u306f\u30b3\u30f3\u30c6\u30f3\u30c4\u306e\u5909\u66f4\u3092\u4f34\u3063\u305f\u30b5\u30a4\u30c8\u30ea\u30cb\u30e5\u30fc\u30a2\u30eb\u6642\u306b\u306f\u3057\u3070\u3057\u3070\u767a\u751f\u3057\u307e\u3059\u3002<\/p>\n

\u305d\u306e\u969b\u3001\u691c\u7d22\u30a8\u30f3\u30b8\u30f3\u306b\u3057\u3070\u3089\u304f\u65e7URL\u304c\u30a4\u30f3\u30c7\u30c3\u30af\u30b9\u3055\u308c\u3066\u3044\u305f\u308a\u3001\u65e7URL\u306e\u30d6\u30c3\u30af\u30de\u30fc\u30af\u304b\u3089\u76f4\u63a5\u30a2\u30af\u30bb\u30b9\u3055\u308c\u305f\u308a\u3059\u308b\u3053\u3068\u304c\u3042\u308b\u306e\u3067\u3001\u65b0URL\u3078\u30ea\u30c0\u30a4\u30ec\u30af\u30c8\u3059\u308b\u8a2d\u5b9a\u3092\u3057\u3066\u304a\u304d\u305f\u3044\u3067\u3059\u3002<\/p>\n

\u4eca\u56de\u306f\u3001\u30b5\u30a4\u30c8\u30b3\u30f3\u30c6\u30f3\u30c4\u306e\u30ea\u30cb\u30e5\u30fc\u30a2\u30eb\u6642\u306b\u95a2\u9023\u3059\u308bURL\u306b\u30ea\u30c0\u30a4\u30ec\u30af\u30c8 (\u8ee2\u9001) \u3059\u308b\u65b9\u6cd5\u306b\u3064\u3044\u3066\u66f8\u3044\u3066\u307f\u305f\u3044\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n

\u307e\u305a\u3001\u5927\u524d\u63d0\u3068\u3057\u3066\u65e7URL\u3068\u65b0URL\u306e\u30de\u30c3\u30d4\u30f3\u30b0\u304c\u5fc5\u8981\u3067\u3059\u3002\u4f8b\u3048\u3070<\/p>\n

\u65e7\u30b5\u30a4\u30c8URL: https:\/\/mmmcorp.co.jp\/solutions\/aws_lambda\/<\/a>
\n\u65b0\u30b5\u30a4\u30c8\u306b\u304a\u3051\u308b\u985e\u4f3c\u30b3\u30f3\u30c6\u30f3\u30c4\u306eURL:
https:\/\/mmmcorp.co.jp\/service\/serverlessarchitecture\/<\/a><\/p>\n

\u306e\u3088\u3046\u306a\u30de\u30c3\u30d4\u30f3\u30b0\u3092\u30a8\u30af\u30bb\u30eb\u306a\u3069\u3067\u6574\u7406\u3057\u3066\u304a\u304d\u307e\u3057\u3087\u3046\u3002<\/p>\n

\u305d\u306e\u4e0a\u3067\u306e\u6280\u8853\u7684\u306a\u8a71\u3068\u306a\u308a\u307e\u3059\u304c\u3001\u30ea\u30c0\u30a4\u30ec\u30af\u30c8\u306e\u4e00\u822c\u7684\u306a\u5bfe\u5fdc\u65b9\u6cd5\u3068\u3057\u3066\u306fWeb\u30b5\u30fc\u30d0\u30fc\u3067\u30ea\u30c0\u30a4\u30ec\u30af\u30c8\u3092\u304b\u3051\u308b\u3053\u3068\u304c\u591a\u3044\u304b\u3068\u601d\u3044\u307e\u3059\u3002Web\u30b5\u30fc\u30d0\u30fc\u304c\u4f8b\u3048\u3070Apache\u3067\u3042\u308c\u3070.htaccess\u30d5\u30a1\u30a4\u30eb\u306a\u3069\u3067\u8a2d\u5b9a\u3057\u307e\u3059\u3002<\/p>\n

\u3057\u304b\u3057\u3001\u65b0\u30b3\u30fc\u30dd\u30ec\u30fc\u30c8\u30b5\u30a4\u30c8\u306b\u304a\u3044\u3066\u306fAWS\u306eS3\u304a\u3088\u3073CloudFront\u3092\u5229\u7528\u3057\u3066\u9759\u7684\u306a\u30b3\u30f3\u30c6\u30f3\u30c4\u914d\u4fe1\u3092\u5b9f\u65bd\u3057\u3066\u3044\u307e\u3059\u3002\u9759\u7684\u30b3\u30f3\u30c6\u30f3\u30c4\u914d\u4fe1\u306f\u30b5\u30a4\u30c8\u30b9\u30d4\u30fc\u30c9\u5411\u4e0a\u30fb\u53ef\u7528\u6027\u5411\u4e0a\u30fb\u904b\u7528\u30b3\u30b9\u30c8\u524a\u6e1b\u306a\u3069\u30e1\u30ea\u30c3\u30c8\u304c\u975e\u5e38\u306b\u5927\u304d\u3044\u306e\u3067\u3059\u304c\u3001\u305d\u308c\u3060\u3051\u3067\u306fWeb\u30b5\u30fc\u30d0\u30fc\u3067\u306e\u8ee2\u9001\u304c\u3067\u304d\u306a\u3044\u3068\u3044\u3046\u554f\u984c\u304c\u3042\u308a\u307e\u3059\u3002\u305d\u3053\u3067\u3001\u672c\u30b1\u30fc\u30b9\u306b\u304a\u3044\u3066\u6709\u52b9\u306aLambda@Edge\u3092\u5229\u7528\u3057\u305f\u8ee2\u9001\u3092\u5b9f\u65bd\u3059\u308b\u3053\u3068\u306b\u3057\u307e\u3057\u305f\u3002<\/p>\n

Lambda@Edge\u3068\u306f<\/h1>\n

Lambda@Edge\u306e\u8aad\u307f\u65b9\u306f\u30e9\u30e0\u30c0\u30a2\u30c3\u30c8\u30a8\u30c3\u30b8\u3060\u3068\u601d\u3044\u307e\u3059\u3002(\u305f\u3060\u3001\u79c1\u306f\u30e9\u30e0\u30c0\u30a8\u30c3\u30b8\u3068\u547c\u3093\u3067\u3044\u307e\u3059\u3002)<\/p>\n

Lambda@Edge\u3068\u306fAWS\u306eCDN\u30b5\u30fc\u30d3\u30b9\u3067\u3042\u308bAmazon CloudFront\u306e\u6a5f\u80fd\u3067\u3001CloudFront\u306e\u30a8\u30c3\u30b8\u30ed\u30b1\u30fc\u30b7\u30e7\u30f3\u306b\u304a\u3044\u3066\u30a2\u30af\u30bb\u30b9\u306b\u5bfe\u3057\u3066\u4efb\u610f\u306e\u30d7\u30ed\u30b0\u30e9\u30e0 (AWS Lambda) \u3092\u5b9f\u884c\u3067\u304d\u308b\u4ed5\u7d44\u307f\u3067\u3059\u3002\u30b5\u30fc\u30d0\u30fc\u30ec\u30b9\u306a\u4ed5\u7d44\u307f\u3067\u3042\u308a\u3001\u81ea\u524d\u3067\u30b5\u30fc\u30d0\u30fc\u3092\u7528\u610f\u3059\u308b\u5fc5\u8981\u306f\u3042\u308a\u307e\u305b\u3093\u3002<\/p>\n

CloudFront\u306f\u9759\u7684\u306a\u30b3\u30f3\u30c6\u30f3\u30c4\u914d\u4fe1\u306e\u30b5\u30fc\u30d3\u30b9\u3067\u3042\u308a\u3001Web\u30b5\u30fc\u30d0\u30fc\u3067\u5b9f\u73fe\u3067\u304d\u308b\u52d5\u7684\u306a\u5236\u5fa1\u304c\u96e3\u3057\u3044\u306e\u3067\u3059\u304c\u3001Lambda@Edge\u306f\u305d\u306e\u554f\u984c\u3092\u89e3\u6c7a\u3067\u304d\u307e\u3059\u3002<\/p>\n

\u4eca\u56de\u306eURL\u306e\u30ea\u30c0\u30a4\u30ec\u30af\u30c8\u4ee5\u5916\u306b\u3082\u975e\u5e38\u306b\u69d8\u3005\u306a\u3053\u3068\u304c\u5b9f\u73fe\u3067\u304d\u307e\u3059\u3002<\/p>\n