Show / Hide Table of Contents

Class EcsDeploymentConfig

A custom Deployment Configuration for an ECS Deployment Group.

Inheritance
object
Resource
BaseDeploymentConfig
EcsDeploymentConfig
Implements
IResource
IConstruct
IDependable
IEcsDeploymentConfig
IBaseDeploymentConfig
Inherited Members
BaseDeploymentConfig.FromDeploymentConfigName(Construct, string, string)
BaseDeploymentConfig.DeploymentConfigArn
BaseDeploymentConfig.DeploymentConfigName
Resource.IsOwnedResource(IConstruct)
Resource.IsResource(IConstruct)
Resource.ApplyRemovalPolicy(RemovalPolicy)
Resource.GeneratePhysicalName()
Resource.GetResourceArnAttribute(string, IArnComponents)
Resource.GetResourceNameAttribute(string)
Resource.Env
Resource.PhysicalName
Resource.Stack
Namespace: Amazon.CDK.AWS.CodeDeploy
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class EcsDeploymentConfig : BaseDeploymentConfig, IResource, IConstruct, IDependable, IEcsDeploymentConfig, IBaseDeploymentConfig
Syntax (vb)
Public Class EcsDeploymentConfig Inherits BaseDeploymentConfig Implements IResource, IConstruct, IDependable, IEcsDeploymentConfig, IBaseDeploymentConfig
Remarks

Resource: AWS::CodeDeploy::DeploymentConfig

ExampleMetadata: infused

Examples
FargateService service;
             ITargetGroup blueTargetGroup;
             ITargetGroup greenTargetGroup;
             IApplicationListener listener;
             IApplicationListener testListener;


             new EcsDeploymentGroup(this, "BlueGreenDG", new EcsDeploymentGroupProps {
                 AutoRollback = new AutoRollbackConfig {
                     // CodeDeploy will automatically roll back if the 8-hour approval period times out and the deployment stops
                     StoppedDeployment = true
                 },
                 Service = service,
                 BlueGreenDeploymentConfig = new EcsBlueGreenDeploymentConfig {
                     // The deployment will wait for approval for up to 8 hours before stopping the deployment
                     DeploymentApprovalWaitTime = Duration.Hours(8),
                     BlueTargetGroup = blueTargetGroup,
                     GreenTargetGroup = greenTargetGroup,
                     Listener = listener,
                     TestListener = testListener
                 },
                 DeploymentConfig = EcsDeploymentConfig.CANARY_10PERCENT_5MINUTES
             });

Synopsis

Constructors

EcsDeploymentConfig(Construct, string, IEcsDeploymentConfigProps?)

A custom Deployment Configuration for an ECS Deployment Group.

Properties

ALL_AT_ONCE

CodeDeploy predefined deployment configuration that shifts all traffic to the updated ECS task set at once.

CANARY_10PERCENT_15MINUTES

CodeDeploy predefined deployment configuration that shifts 10 percent of traffic in the first increment.

CANARY_10PERCENT_5MINUTES

CodeDeploy predefined deployment configuration that shifts 10 percent of traffic in the first increment.

LINEAR_10PERCENT_EVERY_1MINUTES

CodeDeploy predefined deployment configuration that shifts 10 percent of traffic every minute until all traffic is shifted.

LINEAR_10PERCENT_EVERY_3MINUTES

CodeDeploy predefined deployment configuration that shifts 10 percent of traffic every three minutes until all traffic is shifted.

PROPERTY_INJECTION_ID

Uniquely identifies this class.

Methods

FromEcsDeploymentConfigName(Construct, string, string)

Import a custom Deployment Configuration for an ECS Deployment Group defined outside the CDK.

Constructors

EcsDeploymentConfig(Construct, string, IEcsDeploymentConfigProps?)

A custom Deployment Configuration for an ECS Deployment Group.

public EcsDeploymentConfig(Construct scope, string id, IEcsDeploymentConfigProps? props = null)
Parameters
scope Construct
id string
props IEcsDeploymentConfigProps
Remarks

Resource: AWS::CodeDeploy::DeploymentConfig

ExampleMetadata: infused

Examples
FargateService service;
             ITargetGroup blueTargetGroup;
             ITargetGroup greenTargetGroup;
             IApplicationListener listener;
             IApplicationListener testListener;


             new EcsDeploymentGroup(this, "BlueGreenDG", new EcsDeploymentGroupProps {
                 AutoRollback = new AutoRollbackConfig {
                     // CodeDeploy will automatically roll back if the 8-hour approval period times out and the deployment stops
                     StoppedDeployment = true
                 },
                 Service = service,
                 BlueGreenDeploymentConfig = new EcsBlueGreenDeploymentConfig {
                     // The deployment will wait for approval for up to 8 hours before stopping the deployment
                     DeploymentApprovalWaitTime = Duration.Hours(8),
                     BlueTargetGroup = blueTargetGroup,
                     GreenTargetGroup = greenTargetGroup,
                     Listener = listener,
                     TestListener = testListener
                 },
                 DeploymentConfig = EcsDeploymentConfig.CANARY_10PERCENT_5MINUTES
             });

Properties

ALL_AT_ONCE

CodeDeploy predefined deployment configuration that shifts all traffic to the updated ECS task set at once.

public static IEcsDeploymentConfig ALL_AT_ONCE { get; }
Property Value

IEcsDeploymentConfig

Remarks

Resource: AWS::CodeDeploy::DeploymentConfig

ExampleMetadata: infused

CANARY_10PERCENT_15MINUTES

CodeDeploy predefined deployment configuration that shifts 10 percent of traffic in the first increment.

public static IEcsDeploymentConfig CANARY_10PERCENT_15MINUTES { get; }
Property Value

IEcsDeploymentConfig

Remarks

The remaining 90 percent is deployed 15 minutes later.

CANARY_10PERCENT_5MINUTES

CodeDeploy predefined deployment configuration that shifts 10 percent of traffic in the first increment.

public static IEcsDeploymentConfig CANARY_10PERCENT_5MINUTES { get; }
Property Value

IEcsDeploymentConfig

Remarks

The remaining 90 percent is deployed five minutes later.

LINEAR_10PERCENT_EVERY_1MINUTES

CodeDeploy predefined deployment configuration that shifts 10 percent of traffic every minute until all traffic is shifted.

public static IEcsDeploymentConfig LINEAR_10PERCENT_EVERY_1MINUTES { get; }
Property Value

IEcsDeploymentConfig

Remarks

Resource: AWS::CodeDeploy::DeploymentConfig

ExampleMetadata: infused

LINEAR_10PERCENT_EVERY_3MINUTES

CodeDeploy predefined deployment configuration that shifts 10 percent of traffic every three minutes until all traffic is shifted.

public static IEcsDeploymentConfig LINEAR_10PERCENT_EVERY_3MINUTES { get; }
Property Value

IEcsDeploymentConfig

Remarks

Resource: AWS::CodeDeploy::DeploymentConfig

ExampleMetadata: infused

PROPERTY_INJECTION_ID

Uniquely identifies this class.

public static string PROPERTY_INJECTION_ID { get; }
Property Value

string

Remarks

Resource: AWS::CodeDeploy::DeploymentConfig

ExampleMetadata: infused

Methods

FromEcsDeploymentConfigName(Construct, string, string)

Import a custom Deployment Configuration for an ECS Deployment Group defined outside the CDK.

public static IEcsDeploymentConfig FromEcsDeploymentConfigName(Construct scope, string id, string ecsDeploymentConfigName)
Parameters
scope Construct

the parent Construct for this new Construct.

id string

the logical ID of this new Construct.

ecsDeploymentConfigName string

the name of the referenced custom Deployment Configuration.

Returns

IEcsDeploymentConfig

a Construct representing a reference to an existing custom Deployment Configuration

Remarks

Resource: AWS::CodeDeploy::DeploymentConfig

ExampleMetadata: infused

Implements

IResource
Constructs.IConstruct
Constructs.IDependable
IEcsDeploymentConfig
IBaseDeploymentConfig
Back to top Generated by DocFX