Class CloudFrontToOaiToS3.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CloudFrontToOaiToS3>
- Enclosing class:
CloudFrontToOaiToS3
CloudFrontToOaiToS3.-
Method Summary
Modifier and TypeMethodDescriptionbucketProps(software.amazon.awscdk.services.s3.BucketProps bucketProps) Optional user provided props to override the default props for the S3 Content Bucket.build()cloudFrontDistributionProps(Object cloudFrontDistributionProps) Optional user provided props to override the default props.cloudFrontLoggingBucketAccessLogBucketProps(software.amazon.awscdk.services.s3.BucketProps cloudFrontLoggingBucketAccessLogBucketProps) Optional user provided props to override the default props for the CloudFront Log Bucket Access Log bucket.cloudFrontLoggingBucketProps(software.amazon.awscdk.services.s3.BucketProps cloudFrontLoggingBucketProps) Optional user provided props to override the default props for the CloudFront Log Bucket.static CloudFrontToOaiToS3.BuilderexistingBucketObj(software.amazon.awscdk.services.s3.IBucket existingBucketObj) Existing instance of S3 Content Bucket object, providing both this andbucketPropswill cause an error.insertHttpSecurityHeaders(Boolean insertHttpSecurityHeaders) Optional user provided props to turn on/off the automatic injection of best practice HTTP security headers in all responses from cloudfront.logCloudFrontAccessLog(Boolean logCloudFrontAccessLog) Optional - Whether to maintain access logs for the CloudFront Logging bucket.loggingBucketProps(software.amazon.awscdk.services.s3.BucketProps loggingBucketProps) Optional user provided props to override the default props for the S3 Content Bucket Access Log Bucket.logS3AccessLogs(Boolean logS3AccessLogs) Optional - Whether to maintain access logs for the S3 Content bucket.originPath(String originPath) Optional user provided props to provide an originPath that CloudFront appends to the origin domain name when CloudFront requests content from the origin.responseHeadersPolicyProps(software.amazon.awscdk.services.cloudfront.ResponseHeadersPolicyProps responseHeadersPolicyProps) Optional user provided configuration that cloudfront applies to all http responses.
-
Method Details
-
create
- Parameters:
scope-- represents the scope for all the resources.
id-- this is a a scope-unique id.
- Returns:
- a new instance of
CloudFrontToOaiToS3.Builder.
-
bucketProps
public CloudFrontToOaiToS3.Builder bucketProps(software.amazon.awscdk.services.s3.BucketProps bucketProps) Optional user provided props to override the default props for the S3 Content Bucket.Default: - Default props are used
- Parameters:
bucketProps- Optional user provided props to override the default props for the S3 Content Bucket. This parameter is required.- Returns:
this
-
cloudFrontDistributionProps
Optional user provided props to override the default props.Default: - Default props are used
- Parameters:
cloudFrontDistributionProps- Optional user provided props to override the default props. This parameter is required.- Returns:
this
-
cloudFrontLoggingBucketAccessLogBucketProps
public CloudFrontToOaiToS3.Builder cloudFrontLoggingBucketAccessLogBucketProps(software.amazon.awscdk.services.s3.BucketProps cloudFrontLoggingBucketAccessLogBucketProps) Optional user provided props to override the default props for the CloudFront Log Bucket Access Log bucket.Providing both this and
existingcloudFrontLoggingBucketAccessLogBucketwill cause an errorDefault: - Default props are used
- Parameters:
cloudFrontLoggingBucketAccessLogBucketProps- Optional user provided props to override the default props for the CloudFront Log Bucket Access Log bucket. This parameter is required.- Returns:
this
-
cloudFrontLoggingBucketProps
public CloudFrontToOaiToS3.Builder cloudFrontLoggingBucketProps(software.amazon.awscdk.services.s3.BucketProps cloudFrontLoggingBucketProps) Optional user provided props to override the default props for the CloudFront Log Bucket.Default: - Default props are used
- Parameters:
cloudFrontLoggingBucketProps- Optional user provided props to override the default props for the CloudFront Log Bucket. This parameter is required.- Returns:
this
-
existingBucketObj
public CloudFrontToOaiToS3.Builder existingBucketObj(software.amazon.awscdk.services.s3.IBucket existingBucketObj) Existing instance of S3 Content Bucket object, providing both this andbucketPropswill cause an error.Default: - None
- Parameters:
existingBucketObj- Existing instance of S3 Content Bucket object, providing both this andbucketPropswill cause an error. This parameter is required.- Returns:
this
-
insertHttpSecurityHeaders
Optional user provided props to turn on/off the automatic injection of best practice HTTP security headers in all responses from cloudfront.Turning this on will inject default headers and is mutually exclusive with passing custom security headers via the responseHeadersPolicyProps parameter.
Default: - true
- Parameters:
insertHttpSecurityHeaders- Optional user provided props to turn on/off the automatic injection of best practice HTTP security headers in all responses from cloudfront. This parameter is required.- Returns:
this
-
logCloudFrontAccessLog
Optional - Whether to maintain access logs for the CloudFront Logging bucket.Specifying false for this while providing info about the log bucket will cause an error.
Default: - true
- Parameters:
logCloudFrontAccessLog- Optional - Whether to maintain access logs for the CloudFront Logging bucket. This parameter is required.- Returns:
this
-
loggingBucketProps
public CloudFrontToOaiToS3.Builder loggingBucketProps(software.amazon.awscdk.services.s3.BucketProps loggingBucketProps) Optional user provided props to override the default props for the S3 Content Bucket Access Log Bucket.Default: - Default props are used
- Parameters:
loggingBucketProps- Optional user provided props to override the default props for the S3 Content Bucket Access Log Bucket. This parameter is required.- Returns:
this
-
logS3AccessLogs
Optional - Whether to maintain access logs for the S3 Content bucket.Default: - true
- Parameters:
logS3AccessLogs- Optional - Whether to maintain access logs for the S3 Content bucket. This parameter is required.- Returns:
this
-
originPath
Optional user provided props to provide an originPath that CloudFront appends to the origin domain name when CloudFront requests content from the origin.The string should start with a
/, for example/production.Default: = '/'
- Parameters:
originPath- Optional user provided props to provide an originPath that CloudFront appends to the origin domain name when CloudFront requests content from the origin. This parameter is required.- Returns:
this
-
responseHeadersPolicyProps
public CloudFrontToOaiToS3.Builder responseHeadersPolicyProps(software.amazon.awscdk.services.cloudfront.ResponseHeadersPolicyProps responseHeadersPolicyProps) Optional user provided configuration that cloudfront applies to all http responses.Can be used to pass a custom ResponseSecurityHeadersBehavior, ResponseCustomHeadersBehavior or ResponseHeadersCorsBehavior to the cloudfront distribution.
Passing a custom ResponseSecurityHeadersBehavior is mutually exclusive with turning on the default security headers via
insertHttpSecurityHeadersprop. Will throw an error if bothinsertHttpSecurityHeadersis set totrueand ResponseSecurityHeadersBehavior is passed.Default: - undefined
- Parameters:
responseHeadersPolicyProps- Optional user provided configuration that cloudfront applies to all http responses. This parameter is required.- Returns:
this
-
build
- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<CloudFrontToOaiToS3>- Returns:
- a newly built instance of
CloudFrontToOaiToS3.
-