AWS中使用CloudFront分发API Gateway

首先需要准备一个Lambda function(Lambda->Functions)

还要准备一个证书,要覆盖子域名(AWS Certificate Manager->Certificates)。

1、API Gateway->Create API->REST API->Build->API endpoint type( Edge-optimized )->Create API

2、Resources->Create method->Method type(GET)->Integration type(Lambda function)->

Create method

3、Resources->/->GET(/ - GET - Method execution)->Test->结果正确否

4、Resources->Deploy API->Stage(*New Stage*)->Stage name(prod)

5、Stages->prod->/->GET->Invoke URL(https://xxxxxxxx.execute-api.us-east-1.amazonaws.com/prod/),复制地址能访问否

至此,API Gateway已创建完毕

6、CloudFront->Distributions->Create distribution->Origin domain(你的API Gateway)->Origin path - optional(/prod)-> Viewer protocol policy(HTTPS only)->Web Application Firewall (WAF)(Do not enable security protections)->Price class(Use only North America and Europe)->Alternate domain name (CNAME) - optional-> Add item(abc.yourdomain.com)->Custom SSL certificate *- optional->*Create distribution

7、CloudFront->Distributions->Domain name(xxxxxx.cloudfront.net)->复制备用

8、Route 53->Hosted zones->yourdomain.com->Create record->Record name(abc)->Record type(CNAME)->Value(复制备用的xxxxxx.cloudfront.net)->Create records

9、访问abc.yourdomain.com

10、nslookup abc.yourdomain.com

相关推荐
workflower1 天前
全球云计算产业发展态势-市场:云计算规模保持稳步增长,产业格局日趋明晰
人工智能·深度学习·机器学习·设计模式·机器人·云计算
wangjialelele1 天前
Spring Cloud 全体系学习笔记(REST、Nacos、Feign、Gateway)
java·spring boot·笔记·学习·spring·spring cloud·gateway
皮皮虾❀2 天前
阿里巴巴“千问办公”公测深度解析:企业级Agent如何重塑智能办公
人工智能·阿里云·云计算
翼龙云_cloud2 天前
阿里云国际代理商:Redis缓存实例配置和性能优化 从参数调优到持久化
运维·redis·阿里云·缓存·云计算
聚搜云——JuSouClouD2 天前
深圳阿里云代理商:K8s Pod OOM智能排查修复指南
阿里云·kubernetes·云计算
张毅2004-10-102 天前
docker详解:安装docker,docker架构,docker镜像、容器、网络、存储,容器监控,容器日志,综合实验
linux·运维·docker·云原生·云计算
小白考证进阶中2 天前
阿里云ACP取消约考完整流程 + 核心注意事项
运维·阿里云·云计算·阿里云acp·阿里云acp考试·阿里云acp备考·转行运维
数智化管理手记3 天前
元数据管理怎么做?企业级元数据治理如何落地实操?
大数据·重构·云计算
Dawn-bit3 天前
Linux 日志处理三剑客之 awk:取列、取行、过滤与统计计算
linux·运维·服务器·云计算·运维开发