AWS CloudFront distribution origin S3 bucket.
Project description
AWS Secure CloudFront Origin Bucket (for CDK v2)
An AWS CDK construct library to create secure S3 buckets for CloudFront origin.
[!WARNING] v2.1.0: remove origin access identity(oai) support
Install
TypeScript
install by npm
npm install @gammarers/aws-secure-cloudfront-origin-bucket
install by yarn
yarn add @gammarers/aws-secure-cloudfront-origin-bucket
install by pnpm
pnpm add @gammarers/aws-secure-cloudfront-origin-bucket
install by bun
bun add @gammarers/aws-secure-cloudfront-origin-bucket
Python
pip install gammarers.aws-secure-cloudfront-origin-bucket
C# / .NET
dotnet add package gammarers.CDK.AWS.SecureCloudFrontOriginBucket
Example
for OAC(Origin Access Control)
import { SecureCloudFrontOriginBucket, SecureCloudFrontOriginType } from '@gammarers/aws-secure-cloudfront-origin-bucket';
const originBucket = new SecureCloudFrontOriginBucket(stack, 'SecureCloudFrontOriginBucket', {
bucketName: 'example-origin-bucket',
});
const distribution = new cloudfront.Distribution(this, 'Distribution', {
defaultRootObject: 'index.html',
defaultBehavior: {
origin: origins.S3BucketOrigin.withOriginAccessControl(originBucket),
},
});
License
This project is licensed under the Apache-2.0 License.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file gammarers_aws_secure_cloudfront_origin_bucket-2.1.2.tar.gz
.
File metadata
- Download URL: gammarers_aws_secure_cloudfront_origin_bucket-2.1.2.tar.gz
- Upload date:
- Size: 52.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 76fddc241134ebb98acced856bf8c970b78046c7ea9fa052ceb1325d38d10e14 |
|
MD5 | 4739d128ac520c39e24bb02b0294de88 |
|
BLAKE2b-256 | a59c419a67118bbf8ecf79db6132c3c5a0d30b6399a7e6ca1acfa24cd04e3ddf |
File details
Details for the file gammarers.aws_secure_cloudfront_origin_bucket-2.1.2-py3-none-any.whl
.
File metadata
- Download URL: gammarers.aws_secure_cloudfront_origin_bucket-2.1.2-py3-none-any.whl
- Upload date:
- Size: 50.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 15e7b84df1d6ff4809f54db4c8886dfe4f83dd6b53771d233cbc70e1a56f79f4 |
|
MD5 | cfc8cc789d9e5a957fa48ad20d313a07 |
|
BLAKE2b-256 | bec8aa159b38693fc8c5ef3f4a23e97af9a3416b249b27abe9ca870ecaafe9c2 |