Class S3OriginAccessControlProps
Properties for creating a S3 Origin Access Control resource.
Inherited Members
Namespace: Amazon.CDK.AWS.CloudFront
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class S3OriginAccessControlProps : IS3OriginAccessControlProps, IOriginAccessControlBaseProps
Syntax (vb)
Public Class S3OriginAccessControlProps Implements IS3OriginAccessControlProps, IOriginAccessControlBaseProps
Remarks
ExampleMetadata: infused
Examples
var myBucket = new Bucket(this, "myBucket");
var oac = new S3OriginAccessControl(this, "MyOAC", new S3OriginAccessControlProps {
Signing = Signing.SIGV4_NO_OVERRIDE
});
var s3Origin = S3BucketOrigin.WithOriginAccessControl(myBucket, new S3BucketOriginWithOACProps {
OriginAccessControl = oac
});
new Distribution(this, "myDist", new DistributionProps {
DefaultBehavior = new BehaviorOptions {
Origin = s3Origin
}
});
Synopsis
Constructors
| S3OriginAccessControlProps() | Properties for creating a S3 Origin Access Control resource. |
Properties
| Description | A description of the origin access control. |
| OriginAccessControlName | A name to identify the origin access control, with a maximum length of 64 characters. |
| Signing | Specifies which requests CloudFront signs and the signing protocol. |
Constructors
S3OriginAccessControlProps()
Properties for creating a S3 Origin Access Control resource.
public S3OriginAccessControlProps()
Remarks
ExampleMetadata: infused
Examples
var myBucket = new Bucket(this, "myBucket");
var oac = new S3OriginAccessControl(this, "MyOAC", new S3OriginAccessControlProps {
Signing = Signing.SIGV4_NO_OVERRIDE
});
var s3Origin = S3BucketOrigin.WithOriginAccessControl(myBucket, new S3BucketOriginWithOACProps {
OriginAccessControl = oac
});
new Distribution(this, "myDist", new DistributionProps {
DefaultBehavior = new BehaviorOptions {
Origin = s3Origin
}
});
Properties
Description
A description of the origin access control.
public string? Description { get; set; }
Property Value
Remarks
Default: - no description
OriginAccessControlName
A name to identify the origin access control, with a maximum length of 64 characters.
public string? OriginAccessControlName { get; set; }
Property Value
Remarks
Default: - a generated name
Signing
Specifies which requests CloudFront signs and the signing protocol.
public Signing? Signing { get; set; }