pub struct DistributionConfig {
pub caller_reference: String,
pub aliases: Option<Aliases>,
pub default_root_object: Option<String>,
pub origins: Origins,
pub default_cache_behavior: DefaultCacheBehavior,
pub comment: String,
pub price_class: Option<String>,
pub enabled: bool,
pub viewer_certificate: Option<ViewerCertificate>,
}Expand description
A distribution configuration.
AWS API: cloudfront.v1.DistributionConfig
Reference: https://docs.aws.amazon.com/cloudfront/latest/APIReference/DistributionConfig
§Coverage
9 of 24 fields included. Omitted fields:
OriginGroups— not selected in manifestCacheBehaviors— not selected in manifestCustomErrorResponses— not selected in manifestLogging— not selected in manifestRestrictions— not selected in manifestWebACLId— not selected in manifestHttpVersion— not selected in manifestIsIPV6Enabled— not selected in manifestContinuousDeploymentPolicyId— not selected in manifestStaging— not selected in manifestAnycastIpListId— not selected in manifestTenantConfig— not selected in manifestConnectionMode— not selected in manifestViewerMtlsConfig— not selected in manifestConnectionFunctionAssociation— not selected in manifest
Fields§
§caller_reference: StringA unique value (for example, a date-time stamp) that ensures that the request can’t be replayed. If the value of CallerReference is new (regardless of the content of the DistributionConfig object), CloudFront creates a new distribution. If CallerReference is a value that you already sent in a previous request to create a distribution, CloudFront returns a DistributionAlreadyExists error.
aliases: Option<Aliases>This field only supports standard distributions. You can’t specify this field for multi- tenant distributions. For more information, see Unsupported features for SaaS Manager for Amazon CloudFront in the Amazon CloudFront Developer Guide. A complex type that contains information about CNAMEs (alternate domain names), if any, for this distribution.
default_root_object: Option<String>When a viewer requests the root URL for your distribution, the default root object is the object that you want CloudFront to request from your origin. For example, if your root URL is https://www.example.com, you can specify CloudFront to return the index.html file as the default root object. You can specify a default root object so that viewers see a specific file or object, instead of another object in your distribution (for example, https://www.example.com/product-description.html). A default root object avoids exposing the contents of your distribution. You can specify the object name or a path to the object name (for example, index.html or exampleFolderName/index.html). Your string can’t begin with a forward slash (/). Only specify the object name or the path to the object. If you don’t want to specify a default root object when you create a distribution, include an empty DefaultRootObject element. To delete the default root object from an existing distribution, update the distribution configuration and include an empty DefaultRootObject element. To replace the default root object, update the distribution configuration and specify the new object. For more information about the default root object, see Specify a default root object in the Amazon CloudFront Developer Guide.
origins: OriginsA complex type that contains information about origins for this distribution.
default_cache_behavior: DefaultCacheBehaviorA complex type that describes the default cache behavior if you don’t specify a CacheBehavior element or if files don’t match any of the values of PathPattern in CacheBehavior elements. You must create exactly one default cache behavior.
comment: StringA comment to describe the distribution. The comment cannot be longer than 128 characters.
price_class: Option<String>This field only supports standard distributions. You can’t specify this field for multi- tenant distributions. For more information, see Unsupported features for SaaS Manager for Amazon CloudFront in the Amazon CloudFront Developer Guide. The price class that corresponds with the maximum price that you want to pay for CloudFront service. If you specify PriceClass_All, CloudFront responds to requests for your objects from all CloudFront edge locations. If you specify a price class other than PriceClass_All, CloudFront serves your objects from the CloudFront edge location that has the lowest latency among the edge locations in your price class. Viewers who are in or near regions that are excluded from your specified price class may encounter slower performance. For more information about price classes, see Choosing the Price Class for a CloudFront Distribution in the Amazon CloudFront Developer Guide. For information about CloudFront pricing, including how price classes (such as Price Class 100) map to CloudFront regions, see Amazon CloudFront Pricing.
enabled: boolFrom this field, you can enable or disable the selected distribution.
viewer_certificate: Option<ViewerCertificate>A complex type that determines the distribution’s SSL/TLS configuration for communicating with viewers.
Trait Implementations§
Source§impl Clone for DistributionConfig
impl Clone for DistributionConfig
Source§fn clone(&self) -> DistributionConfig
fn clone(&self) -> DistributionConfig
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more