[![NPM version](https://badge.fury.io/js/cdk-cloudfront-plus.svg)](https://badge.fury.io/js/cdk-cloudfront-plus)
[![PyPI version](https://badge.fury.io/py/cdk-cloudfront-plus.svg)](https://badge.fury.io/py/cdk-cloudfront-plus)
![Release](https://github.com/pahud/cdk-cloudfront-plus/workflows/Release/badge.svg?branch=main)
# cdk-cloudfront-plus
CDK constructs library that allows you to build [AWS CloudFront Extensions](https://github.com/awslabs/aws-cloudfront-extensions) in **JavaScript**, **TypeScript** or **Python**.
# Sample
```python
# Example automatically generated without compilation. See https://github.com/aws/jsii/issues/826
import cdk_cloudfront_plus as cfplus
app = cdk.App()
stack = cdk.Stack(app, "demo-stack")
# prepare the `modify resonse header` extension
modify_resp_header = extensions.ModifyResponseHeader(stack, "ModifyResp")
# prepare the `anti-hotlinking` extension
anti_hotlinking = extensions.AntiHotlinking(stack, "AntiHotlink",
referer=["example.com", "exa?ple.*"
]
)
# create the cloudfront distribution with extension(s)
Distribution(stack, "dist",
default_behavior={
"origin": origins.HttpOrigin("aws.amazon.com"),
"edge_lambdas": [modify_resp_header, anti_hotlinking
]
}
)
```
# Available Extensions in AWS CDK
| Extension Name | Category | Solution ID | Function/Folder Name | Status | Contributor |
| -------------- | ---------- | ------------- | --------------------------------------- | ---| --- |
| [Access Origin by geolocation](https://github.com/pahud/cdk-cloudfront-plus/issues/41) | Origin Selection | SO8118 | cf-access-origin-by-geolocation | Completed | @pahud PR#52 |
| [Redirect by geolocation](https://github.com/pahud/cdk-cloudfront-plus/issues/11) | Origin Selection | SO8135 | cf-redirect-by-geolocation | Completed | @minche-tsai PR#50 |
| [Convert Query String](https://github.com/pahud/cdk-cloudfront-plus/issues/23) | Override Request | SO8113 | cf-convert-query-string | Completed | @HsiehShuJeng PR#53 |
| [OAuth2 Authentication](https://github.com/pahud/cdk-cloudfront-plus/issues/17) | Authentication | SO8131 | cf-authentication-by-oauth2 | Completed | @dwchiang PR#59 |
| [Cognito Redirect](https://github.com/pahud/cdk-cloudfront-plus/issues/16) | Authentication | SO8132 | cf-authentication-by-cognito-redirect | WIP(BabooPan) | - |
| [Global Data Ingestion](https://github.com/pahud/cdk-cloudfront-plus/issues/14) | Logging | SO8133 | cf-global-data-ingestion | Completed | @titanjer PR#62 |
| [HTTP 302 from Origin](https://github.com/pahud/cdk-cloudfront-plus/issues/12) | URL Redirect | SO8103 | cf-http302-from-origin | Completed | @RicoToothless PR#71 |
| [Default Directory Index for Amazon S3 Origin](https://github.com/pahud/cdk-cloudfront-plus/issues/9) | URL Redirect | SO8134 | cf-default-dir-index | Completed | @guan840912 PR#21 |
| [Modify Response Header](https://github.com/awslabs/aws-cloudfront-extensions/tree/main/edge/nodejs/modify-response-header) | Header Rewrite | SO8105 | cf-modify-response-header | Completed | @pahud PR#45 |
| [Custom Error Page](https://github.com/pahud/cdk-cloudfront-plus/pull/46)| Header Rewrite | SO8136 | cf-custom-error-page | Completed | @BabooPan PR#46 |
| [Anti Hotlinking](https://github.com/awslabs/aws-cloudfront-extensions/tree/main/edge/nodejs/anti-hotlinking) | Security | SO8126 | cf-anti-hotlinking | Completed | @pahud PR#2 |
| [Add Security Headers](https://github.com/awslabs/aws-cloudfront-extensions/tree/main/edge/nodejs/add-security-headers) | Security | SO8102 | cf-add-security-headers | Completed | @pahud PR#7 |
| [Failover to alternative origin](https://github.com/awslabs/aws-cloudfront-extensions/tree/main/edge/nodejs/multiple-origin-IP-retry) | Origin Selection | SO8120 | cf-multiple-origin-ip-retry | Completed | @guan840912 PR#58 |
| [Normalize Query String](https://github.com/pahud/cdk-cloudfront-plus/pull/64) | Override Request | SO8112 | cf-normalize-query-string | Completed | @benkajaja PR#64 |
没有合适的资源?快使用搜索试试~ 我知道了~
温馨提示
资源分类:Python库 所属语言:Python 资源全名:cdk-cloudfront-plus-0.3.88.tar.gz 资源来源:官方 安装方法:https://lanzao.blog.csdn.net/article/details/101784059
资源推荐
资源详情
资源评论
收起资源包目录
cdk-cloudfront-plus-0.3.88.tar.gz (16个子文件)
cdk-cloudfront-plus-0.3.88
MANIFEST.in 23B
PKG-INFO 5KB
pyproject.toml 106B
LICENSE 11KB
src
cdk_cloudfront_plus.egg-info
PKG-INFO 5KB
requires.txt 521B
SOURCES.txt 464B
top_level.txt 20B
dependency_links.txt 1B
cdk_cloudfront_plus
py.typed 1B
_jsii
cdk-cloudfront-plus@0.3.88.jsii.tgz 3.08MB
__init__.py 797B
__init__.py 78KB
setup.cfg 38B
setup.py 2KB
README.md 4KB
共 16 条
- 1
资源评论
挣扎的蓝藻
- 粉丝: 14w+
- 资源: 15万+
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
最新资源
- 1732669747878.jpg
- 8613985ec49eb8f757ae6439e879bb2a_holmes_logindex
- 使用Spring Boot处理大文件上传有哪些技巧?
- GRE隧道是Openwrt系统的常用功能之一,在两台Openwrt设备之间建立GRE隧道,可通过两台设备在公网上建立一个虚拟局域网
- 机器学习领域中的Iris数据集探索与分析技术解析及建模流程
- 本科毕业设计-Java Web学院的实验课选课及实验室管理系统.zip
- MySQL在Linux安装和集群搭建-一主一备
- Python中检查文件是否存在的几种方法
- 02b97e6de561b351e3db753f4abedc7b.rar
- java JDK11版本安装包
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功