LegacyCustomOriginProperty Struct
A custom origin.
A custom origin is any origin that is not an Amazon S3 bucket, with one exception. An Amazon S3 bucket that is configured with static website hosting is a custom origin.
This property is legacy. We recommend that you use Origin instead.
| Source | |
|---|---|
| Type last changed |
Example
ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_cloudfront as cloudfront } from 'aws-cdk-lib';
const legacyCustomOriginProperty: cloudfront.CfnDistribution.LegacyCustomOriginProperty = {
dnsName: 'dnsName',
originProtocolPolicy: 'originProtocolPolicy',
originSslProtocols: ['originSslProtocols'],
// the properties below are optional
httpPort: 123,
httpsPort: 123,
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_cloudfront as cloudfront
legacy_custom_origin_property = cloudfront.CfnDistribution.LegacyCustomOriginProperty(
dns_name="dnsName",
origin_protocol_policy="originProtocolPolicy",
origin_ssl_protocols=["originSslProtocols"],
# the properties below are optional
http_port=123,
https_port=123
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.cloudfront.*;
LegacyCustomOriginProperty legacyCustomOriginProperty = LegacyCustomOriginProperty.builder()
.dnsName("dnsName")
.originProtocolPolicy("originProtocolPolicy")
.originSslProtocols(List.of("originSslProtocols"))
// the properties below are optional
.httpPort(123)
.httpsPort(123)
.build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.CloudFront;
var legacyCustomOriginProperty = new LegacyCustomOriginProperty {
DnsName = "dnsName",
OriginProtocolPolicy = "originProtocolPolicy",
OriginSslProtocols = new [] { "originSslProtocols" },
// the properties below are optional
HttpPort = 123,
HttpsPort = 123
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"
legacyCustomOriginProperty := &LegacyCustomOriginProperty{
DnsName: jsii.String("dnsName"),
OriginProtocolPolicy: jsii.String("originProtocolPolicy"),
OriginSslProtocols: []*string{
jsii.String("originSslProtocols"),
},
// the properties below are optional
HttpPort: jsii.Number(123),
HttpsPort: jsii.Number(123),
}
Properties
The domain name assigned to your CloudFront distribution.
httpPortoptionalnumberhttp_portoptionalint | floathttpPortoptionalNumberHttpPortoptionaldoubleHttpPortoptional*float64 = 80 #The HTTP port that CloudFront uses to connect to the origin.
Specify the HTTP port that the origin listens on.
httpsPortoptionalnumberhttps_portoptionalint | floathttpsPortoptionalNumberHttpsPortoptionaldoubleHttpsPortoptional*float64 = 443 #The HTTPS port that CloudFront uses to connect to the origin.
Specify the HTTPS port that the origin listens on.
originProtocolPolicystringorigin_protocol_policystroriginProtocolPolicyStringOriginProtocolPolicystringOriginProtocolPolicy*string required #Specifies the protocol (HTTP or HTTPS) that CloudFront uses to connect to the origin.
originSslProtocolsstring[]origin_ssl_protocolstyping.List[str]originSslProtocolsList<String>OriginSslProtocolsstring[]OriginSslProtocols*[]*string required #The minimum SSL/TLS protocol version that CloudFront uses when communicating with your origin server over HTTPs.
notes
For more information, see Minimum Origin SSL Protocol in the Amazon CloudFront Developer Guide .