EcsDeploymentGroupProps Struct
Construction properties for EcsDeploymentGroup.
Example
ts
declare const myApplication: codedeploy.EcsApplication;
declare const cluster: ecs.Cluster;
declare const taskDefinition: ecs.FargateTaskDefinition;
declare const blueTargetGroup: elbv2.ITargetGroup;
declare const greenTargetGroup: elbv2.ITargetGroup;
declare const listener: elbv2.IApplicationListener;
const service = new ecs.FargateService(this, 'Service', {
cluster,
taskDefinition,
deploymentController: {
type: ecs.DeploymentControllerType.CODE_DEPLOY,
},
});
new codedeploy.EcsDeploymentGroup(this, 'BlueGreenDG', {
service,
blueGreenDeploymentConfig: {
blueTargetGroup,
greenTargetGroup,
listener,
},
deploymentConfig: codedeploy.EcsDeploymentConfig.CANARY_10PERCENT_5MINUTES,
});
Properties
alarmsIAlarmRef[]alarmstyping.List[IAlarmRef]alarmsList<IAlarmRef>AlarmsIAlarmRef[]Alarms*[]IAlarmRef= []#The CloudWatch alarms associated with this Deployment Group.
CodeDeploy will stop (and optionally roll back) a deployment if during it any of the alarms trigger.
Alarms can also be added after the Deployment Group is created using the #addAlarm method.
applicationIApplicationRefapplicationIApplicationRefapplicationIApplicationRefApplicationIApplicationRefApplicationIApplicationRef= One will be created for you.#The reference to the CodeDeploy ECS Application that this Deployment Group belongs to.
autoRollbackAutoRollbackConfigauto_rollbackAutoRollbackConfigautoRollbackAutoRollbackConfigAutoRollbackAutoRollbackConfigAutoRollbackAutoRollbackConfig= default AutoRollbackConfig.#The auto-rollback configuration for this Deployment Group.
blueGreenDeploymentConfigEcsBlueGreenDeploymentConfigblue_green_deployment_configEcsBlueGreenDeploymentConfigblueGreenDeploymentConfigEcsBlueGreenDeploymentConfigBlueGreenDeploymentConfigEcsBlueGreenDeploymentConfigBlueGreenDeploymentConfigEcsBlueGreenDeploymentConfigrequired#The configuration options for blue-green ECS deployments.
deploymentConfigIDeploymentConfigRefdeployment_configIDeploymentConfigRefdeploymentConfigIDeploymentConfigRefDeploymentConfigIDeploymentConfigRefDeploymentConfigIDeploymentConfigRef= EcsDeploymentConfig.ALL_AT_ONCE#The Deployment Configuration this Deployment Group uses.
deploymentGroupNamestringdeployment_group_namestrdeploymentGroupNameStringDeploymentGroupNamestringDeploymentGroupName*string= An auto-generated name will be u…#The physical, human-readable name of the CodeDeploy Deployment Group.
default
Default: An auto-generated name will be used.
ignoreAlarmConfigurationbooleanignore_alarm_configurationboolignoreAlarmConfigurationBooleanIgnoreAlarmConfigurationboolIgnoreAlarmConfiguration*bool= false#Whether to skip the step of checking CloudWatch alarms during the deployment process.
ignorePollAlarmsFailurebooleanignore_poll_alarms_failureboolignorePollAlarmsFailureBooleanIgnorePollAlarmsFailureboolIgnorePollAlarmsFailure*bool= false#Whether to continue a deployment even if fetching the alarm status from CloudWatch failed.
The service Role of this Deployment Group.
serviceIBaseServiceserviceIBaseServiceserviceIBaseServiceServiceIBaseServiceServiceIBaseServicerequired#The ECS service to deploy with this Deployment Group.