ContinuousDeploymentPolicyConfigProperty Struct
Contains the configuration for a continuous deployment policy.
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 continuousDeploymentPolicyConfigProperty: cloudfront.CfnContinuousDeploymentPolicy.ContinuousDeploymentPolicyConfigProperty = {
enabled: false,
stagingDistributionDnsNames: ['stagingDistributionDnsNames'],
// the properties below are optional
singleHeaderPolicyConfig: {
header: 'header',
value: 'value',
},
singleWeightPolicyConfig: {
weight: 123,
// the properties below are optional
sessionStickinessConfig: {
idleTtl: 123,
maximumTtl: 123,
},
},
trafficConfig: {
type: 'type',
// the properties below are optional
singleHeaderConfig: {
header: 'header',
value: 'value',
},
singleWeightConfig: {
weight: 123,
// the properties below are optional
sessionStickinessConfig: {
idleTtl: 123,
maximumTtl: 123,
},
},
},
type: 'type',
};
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
continuous_deployment_policy_config_property = cloudfront.CfnContinuousDeploymentPolicy.ContinuousDeploymentPolicyConfigProperty(
enabled=False,
staging_distribution_dns_names=["stagingDistributionDnsNames"],
# the properties below are optional
single_header_policy_config=cloudfront.CfnContinuousDeploymentPolicy.SingleHeaderPolicyConfigProperty(
header="header",
value="value"
),
single_weight_policy_config=cloudfront.CfnContinuousDeploymentPolicy.SingleWeightPolicyConfigProperty(
weight=123,
# the properties below are optional
session_stickiness_config=cloudfront.CfnContinuousDeploymentPolicy.SessionStickinessConfigProperty(
idle_ttl=123,
maximum_ttl=123
)
),
traffic_config=cloudfront.CfnContinuousDeploymentPolicy.TrafficConfigProperty(
type="type",
# the properties below are optional
single_header_config=cloudfront.CfnContinuousDeploymentPolicy.SingleHeaderConfigProperty(
header="header",
value="value"
),
single_weight_config=cloudfront.CfnContinuousDeploymentPolicy.SingleWeightConfigProperty(
weight=123,
# the properties below are optional
session_stickiness_config=cloudfront.CfnContinuousDeploymentPolicy.SessionStickinessConfigProperty(
idle_ttl=123,
maximum_ttl=123
)
)
),
type="type"
)
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.*;
ContinuousDeploymentPolicyConfigProperty continuousDeploymentPolicyConfigProperty = ContinuousDeploymentPolicyConfigProperty.builder()
.enabled(false)
.stagingDistributionDnsNames(List.of("stagingDistributionDnsNames"))
// the properties below are optional
.singleHeaderPolicyConfig(SingleHeaderPolicyConfigProperty.builder()
.header("header")
.value("value")
.build())
.singleWeightPolicyConfig(SingleWeightPolicyConfigProperty.builder()
.weight(123)
// the properties below are optional
.sessionStickinessConfig(SessionStickinessConfigProperty.builder()
.idleTtl(123)
.maximumTtl(123)
.build())
.build())
.trafficConfig(TrafficConfigProperty.builder()
.type("type")
// the properties below are optional
.singleHeaderConfig(SingleHeaderConfigProperty.builder()
.header("header")
.value("value")
.build())
.singleWeightConfig(SingleWeightConfigProperty.builder()
.weight(123)
// the properties below are optional
.sessionStickinessConfig(SessionStickinessConfigProperty.builder()
.idleTtl(123)
.maximumTtl(123)
.build())
.build())
.build())
.type("type")
.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 continuousDeploymentPolicyConfigProperty = new ContinuousDeploymentPolicyConfigProperty {
Enabled = false,
StagingDistributionDnsNames = new [] { "stagingDistributionDnsNames" },
// the properties below are optional
SingleHeaderPolicyConfig = new SingleHeaderPolicyConfigProperty {
Header = "header",
Value = "value"
},
SingleWeightPolicyConfig = new SingleWeightPolicyConfigProperty {
Weight = 123,
// the properties below are optional
SessionStickinessConfig = new SessionStickinessConfigProperty {
IdleTtl = 123,
MaximumTtl = 123
}
},
TrafficConfig = new TrafficConfigProperty {
Type = "type",
// the properties below are optional
SingleHeaderConfig = new SingleHeaderConfigProperty {
Header = "header",
Value = "value"
},
SingleWeightConfig = new SingleWeightConfigProperty {
Weight = 123,
// the properties below are optional
SessionStickinessConfig = new SessionStickinessConfigProperty {
IdleTtl = 123,
MaximumTtl = 123
}
}
},
Type = "type"
};
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"
continuousDeploymentPolicyConfigProperty := &ContinuousDeploymentPolicyConfigProperty{
Enabled: jsii.Boolean(false),
StagingDistributionDnsNames: []*string{
jsii.String("stagingDistributionDnsNames"),
},
// the properties below are optional
SingleHeaderPolicyConfig: &SingleHeaderPolicyConfigProperty{
Header: jsii.String("header"),
Value: jsii.String("value"),
},
SingleWeightPolicyConfig: &SingleWeightPolicyConfigProperty{
Weight: jsii.Number(123),
// the properties below are optional
SessionStickinessConfig: &SessionStickinessConfigProperty{
IdleTtl: jsii.Number(123),
MaximumTtl: jsii.Number(123),
},
},
TrafficConfig: &TrafficConfigProperty{
Type: jsii.String("type"),
// the properties below are optional
SingleHeaderConfig: &SingleHeaderConfigProperty{
Header: jsii.String("header"),
Value: jsii.String("value"),
},
SingleWeightConfig: &SingleWeightConfigProperty{
Weight: jsii.Number(123),
// the properties below are optional
SessionStickinessConfig: &SessionStickinessConfigProperty{
IdleTtl: jsii.Number(123),
MaximumTtl: jsii.Number(123),
},
},
},
Type: jsii.String("type"),
}
Properties
enabledboolean | IResolvableenabledtyping.Union[bool, IResolvable]enabledBooleanEnabledboolEnabledinterface{}required#A Boolean that indicates whether this continuous deployment policy is enabled (in effect).
When this value is true , this policy is enabled and in effect. When this value is false , this policy is not enabled and has no effect.
singleHeaderPolicyConfigoptionalIResolvable | CfnContinuousDeploymentPolicy.SingleHeaderPolicyConfigPropertysingle_header_policy_configoptionaltyping.Union[IResolvable, SingleHeaderPolicyConfigProperty]singleHeaderPolicyConfigoptionalIResolvableSingleHeaderPolicyConfigoptionalIResolvableSingleHeaderPolicyConfigoptionalinterface{}#This configuration determines which HTTP requests are sent to the staging distribution.
If the HTTP request contains a header and value that matches what you specify here, the request is sent to the staging distribution. Otherwise the request is sent to the primary distribution.
singleWeightPolicyConfigoptionalIResolvable | CfnContinuousDeploymentPolicy.SingleWeightPolicyConfigPropertysingle_weight_policy_configoptionaltyping.Union[IResolvable, SingleWeightPolicyConfigProperty]singleWeightPolicyConfigoptionalIResolvableSingleWeightPolicyConfigoptionalIResolvableSingleWeightPolicyConfigoptionalinterface{}#This configuration determines the percentage of HTTP requests that are sent to the staging distribution.
stagingDistributionDnsNamesstring[]staging_distribution_dns_namestyping.List[str]stagingDistributionDnsNamesList<String>StagingDistributionDnsNamesstring[]StagingDistributionDnsNames*[]*stringrequired#The CloudFront domain name of the staging distribution.
For example: d111111abcdef8.cloudfront.net .
trafficConfigoptionalIResolvable | CfnContinuousDeploymentPolicy.TrafficConfigPropertytraffic_configoptionaltyping.Union[IResolvable, TrafficConfigProperty]trafficConfigoptionalIResolvableTrafficConfigoptionalIResolvableTrafficConfigoptionalinterface{}#Contains the parameters for routing production traffic from your primary to staging distributions.
The type of traffic configuration.