awscodedeploy

package
v2.141.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 8, 2024 License: Apache-2.0 Imports: 14 Imported by: 1

README

AWS CodeDeploy Construct Library

Table of Contents

Introduction

AWS CodeDeploy is a deployment service that automates application deployments to Amazon EC2 instances, on-premises instances, serverless Lambda functions, or Amazon ECS services.

The CDK currently supports Amazon EC2, on-premise, AWS Lambda, and Amazon ECS applications.

EC2/on-premise Applications

To create a new CodeDeploy Application that deploys to EC2/on-premise instances:

application := codedeploy.NewServerApplication(this, jsii.String("CodeDeployApplication"), &ServerApplicationProps{
	ApplicationName: jsii.String("MyApplication"),
})

To import an already existing Application:

application := codedeploy.ServerApplication_FromServerApplicationName(this, jsii.String("ExistingCodeDeployApplication"), jsii.String("MyExistingApplication"))

EC2/on-premise Deployment Groups

To create a new CodeDeploy Deployment Group that deploys to EC2/on-premise instances:

import autoscaling "github.com/aws/aws-cdk-go/awscdk"
import cloudwatch "github.com/aws/aws-cdk-go/awscdk"

var application serverApplication
var asg autoScalingGroup
var alarm alarm

deploymentGroup := codedeploy.NewServerDeploymentGroup(this, jsii.String("CodeDeployDeploymentGroup"), &ServerDeploymentGroupProps{
	Application: Application,
	DeploymentGroupName: jsii.String("MyDeploymentGroup"),
	AutoScalingGroups: []iAutoScalingGroup{
		asg,
	},
	// adds User Data that installs the CodeDeploy agent on your auto-scaling groups hosts
	// default: true
	InstallAgent: jsii.Boolean(true),
	// adds EC2 instances matching tags
	Ec2InstanceTags: codedeploy.NewInstanceTagSet(map[string][]*string{
		// any instance with tags satisfying
		// key1=v1 or key1=v2 or key2 (any value) or value v3 (any key)
		// will match this group
		"key1": []*string{
			jsii.String("v1"),
			jsii.String("v2"),
		},
		"key2": []*string{
		},
		"": []*string{
			jsii.String("v3"),
		},
	}),
	// adds on-premise instances matching tags
	OnPremiseInstanceTags: codedeploy.NewInstanceTagSet(map[string][]*string{
		"key1": []*string{
			jsii.String("v1"),
			jsii.String("v2"),
		},
	}, map[string][]*string{
		"key2": []*string{
			jsii.String("v3"),
		},
	}),
	// CloudWatch alarms
	Alarms: []iAlarm{
		alarm,
	},
	// whether to ignore failure to fetch the status of alarms from CloudWatch
	// default: false
	IgnorePollAlarmsFailure: jsii.Boolean(false),
	// whether to skip the step of checking CloudWatch alarms during the deployment process
	// default: false
	IgnoreAlarmConfiguration: jsii.Boolean(false),
	// auto-rollback configuration
	AutoRollback: &AutoRollbackConfig{
		FailedDeployment: jsii.Boolean(true),
		 // default: true
		StoppedDeployment: jsii.Boolean(true),
		 // default: false
		DeploymentInAlarm: jsii.Boolean(true),
	},
})

All properties are optional - if you don't provide an Application, one will be automatically created.

To import an already existing Deployment Group:

var application serverApplication

deploymentGroup := codedeploy.ServerDeploymentGroup_FromServerDeploymentGroupAttributes(this, jsii.String("ExistingCodeDeployDeploymentGroup"), &ServerDeploymentGroupAttributes{
	Application: Application,
	DeploymentGroupName: jsii.String("MyExistingDeploymentGroup"),
})
Load balancers

You can specify a load balancer with the loadBalancer property when creating a Deployment Group.

LoadBalancer is an abstract class with static factory methods that allow you to create instances of it from various sources.

With Classic Elastic Load Balancer, you provide it directly:

import elb "github.com/aws/aws-cdk-go/awscdk"

var lb loadBalancer

lb.AddListener(&LoadBalancerListener{
	ExternalPort: jsii.Number(80),
})

deploymentGroup := codedeploy.NewServerDeploymentGroup(this, jsii.String("DeploymentGroup"), &ServerDeploymentGroupProps{
	LoadBalancer: codedeploy.LoadBalancer_Classic(lb),
})

With Application Load Balancer or Network Load Balancer, you provide a Target Group as the load balancer:

var alb applicationLoadBalancer

listener := alb.AddListener(jsii.String("Listener"), &BaseApplicationListenerProps{
	Port: jsii.Number(80),
})
targetGroup := listener.AddTargets(jsii.String("Fleet"), &AddApplicationTargetsProps{
	Port: jsii.Number(80),
})

deploymentGroup := codedeploy.NewServerDeploymentGroup(this, jsii.String("DeploymentGroup"), &ServerDeploymentGroupProps{
	LoadBalancer: codedeploy.LoadBalancer_Application(targetGroup),
})

The loadBalancer property has been deprecated. To provide multiple Elastic Load Balancers as target groups use the loadBalancers parameter:

import elb "github.com/aws/aws-cdk-go/awscdk"
import elb2 "github.com/aws/aws-cdk-go/awscdk"

var clb loadBalancer
var alb applicationLoadBalancer
var nlb networkLoadBalancer


albListener := alb.AddListener(jsii.String("ALBListener"), &BaseApplicationListenerProps{
	Port: jsii.Number(80),
})
albTargetGroup := albListener.AddTargets(jsii.String("ALBFleet"), &AddApplicationTargetsProps{
	Port: jsii.Number(80),
})

nlbListener := nlb.AddListener(jsii.String("NLBListener"), &BaseNetworkListenerProps{
	Port: jsii.Number(80),
})
nlbTargetGroup := nlbListener.AddTargets(jsii.String("NLBFleet"), &AddNetworkTargetsProps{
	Port: jsii.Number(80),
})

deploymentGroup := codedeploy.NewServerDeploymentGroup(this, jsii.String("DeploymentGroup"), &ServerDeploymentGroupProps{
	LoadBalancers: []loadBalancer{
		codedeploy.*loadBalancer_Classic(clb),
		codedeploy.*loadBalancer_Application(albTargetGroup),
		codedeploy.*loadBalancer_Network(nlbTargetGroup),
	},
})

EC2/on-premise Deployment Configurations

You can also pass a Deployment Configuration when creating the Deployment Group:

deploymentGroup := codedeploy.NewServerDeploymentGroup(this, jsii.String("CodeDeployDeploymentGroup"), &ServerDeploymentGroupProps{
	DeploymentConfig: codedeploy.ServerDeploymentConfig_ALL_AT_ONCE(),
})

The default Deployment Configuration is ServerDeploymentConfig.ONE_AT_A_TIME.

You can also create a custom Deployment Configuration:

deploymentConfig := codedeploy.NewServerDeploymentConfig(this, jsii.String("DeploymentConfiguration"), &ServerDeploymentConfigProps{
	DeploymentConfigName: jsii.String("MyDeploymentConfiguration"),
	 // optional property
	// one of these is required, but both cannot be specified at the same time
	MinimumHealthyHosts: codedeploy.MinimumHealthyHosts_Count(jsii.Number(2)),
})

Or import an existing one:

deploymentConfig := codedeploy.ServerDeploymentConfig_FromServerDeploymentConfigName(this, jsii.String("ExistingDeploymentConfiguration"), jsii.String("MyExistingDeploymentConfiguration"))

Lambda Applications

To create a new CodeDeploy Application that deploys to a Lambda function:

application := codedeploy.NewLambdaApplication(this, jsii.String("CodeDeployApplication"), &LambdaApplicationProps{
	ApplicationName: jsii.String("MyApplication"),
})

To import an already existing Application:

application := codedeploy.LambdaApplication_FromLambdaApplicationName(this, jsii.String("ExistingCodeDeployApplication"), jsii.String("MyExistingApplication"))

Lambda Deployment Groups

To enable traffic shifting deployments for Lambda functions, CodeDeploy uses Lambda Aliases, which can balance incoming traffic between two different versions of your function. Before deployment, the alias sends 100% of invokes to the version used in production. When you publish a new version of the function to your stack, CodeDeploy will send a small percentage of traffic to the new version, monitor, and validate before shifting 100% of traffic to the new version.

To create a new CodeDeploy Deployment Group that deploys to a Lambda function:

var myApplication lambdaApplication
var func function

version := func.currentVersion
version1Alias := lambda.NewAlias(this, jsii.String("alias"), &AliasProps{
	AliasName: jsii.String("prod"),
	Version: Version,
})

deploymentGroup := codedeploy.NewLambdaDeploymentGroup(this, jsii.String("BlueGreenDeployment"), &LambdaDeploymentGroupProps{
	Application: myApplication,
	 // optional property: one will be created for you if not provided
	Alias: version1Alias,
	DeploymentConfig: codedeploy.LambdaDeploymentConfig_LINEAR_10PERCENT_EVERY_1MINUTE(),
})

In order to deploy a new version of this function:

  1. Reference the version with the latest changes const version = func.currentVersion.
  2. Re-deploy the stack (this will trigger a deployment).
  3. Monitor the CodeDeploy deployment as traffic shifts between the versions.
Lambda Deployment Rollbacks and Alarms

CodeDeploy will roll back if the deployment fails. You can optionally trigger a rollback when one or more alarms are in a failed state:

import "github.com/aws/aws-cdk-go/awscdk"

var alias alias

// or add alarms to an existing group
var blueGreenAlias alias

alarm := cloudwatch.NewAlarm(this, jsii.String("Errors"), &AlarmProps{
	ComparisonOperator: cloudwatch.ComparisonOperator_GREATER_THAN_THRESHOLD,
	Threshold: jsii.Number(1),
	EvaluationPeriods: jsii.Number(1),
	Metric: alias.metricErrors(),
})
deploymentGroup := codedeploy.NewLambdaDeploymentGroup(this, jsii.String("BlueGreenDeployment"), &LambdaDeploymentGroupProps{
	Alias: Alias,
	DeploymentConfig: codedeploy.LambdaDeploymentConfig_LINEAR_10PERCENT_EVERY_1MINUTE(),
	Alarms: []iAlarm{
		alarm,
	},
})
deploymentGroup.AddAlarm(cloudwatch.NewAlarm(this, jsii.String("BlueGreenErrors"), &AlarmProps{
	ComparisonOperator: cloudwatch.ComparisonOperator_GREATER_THAN_THRESHOLD,
	Threshold: jsii.Number(1),
	EvaluationPeriods: jsii.Number(1),
	Metric: blueGreenAlias.metricErrors(),
}))
Pre and Post Hooks

CodeDeploy allows you to run an arbitrary Lambda function before traffic shifting actually starts (PreTraffic Hook) and after it completes (PostTraffic Hook). With either hook, you have the opportunity to run logic that determines whether the deployment must succeed or fail. For example, with PreTraffic hook you could run integration tests against the newly created Lambda version (but not serving traffic). With PostTraffic hook, you could run end-to-end validation checks.

var warmUpUserCache function
var endToEndValidation function
var alias alias


// pass a hook whe creating the deployment group
deploymentGroup := codedeploy.NewLambdaDeploymentGroup(this, jsii.String("BlueGreenDeployment"), &LambdaDeploymentGroupProps{
	Alias: alias,
	DeploymentConfig: codedeploy.LambdaDeploymentConfig_LINEAR_10PERCENT_EVERY_1MINUTE(),
	PreHook: warmUpUserCache,
})

// or configure one on an existing deployment group
deploymentGroup.AddPostHook(endToEndValidation)
Import an existing Lambda Deployment Group

To import an already existing Deployment Group:

var application lambdaApplication

deploymentGroup := codedeploy.LambdaDeploymentGroup_FromLambdaDeploymentGroupAttributes(this, jsii.String("ExistingCodeDeployDeploymentGroup"), &LambdaDeploymentGroupAttributes{
	Application: Application,
	DeploymentGroupName: jsii.String("MyExistingDeploymentGroup"),
})

Lambda Deployment Configurations

CodeDeploy for Lambda comes with predefined configurations for traffic shifting. The predefined configurations are available as LambdaDeploymentConfig constants.

var application lambdaApplication
var alias alias
config := codedeploy.LambdaDeploymentConfig_CANARY_10PERCENT_30MINUTES()
deploymentGroup := codedeploy.NewLambdaDeploymentGroup(this, jsii.String("BlueGreenDeployment"), &LambdaDeploymentGroupProps{
	Application: Application,
	Alias: Alias,
	DeploymentConfig: config,
})

If you want to specify your own strategy, you can do so with the LambdaDeploymentConfig construct, letting you specify precisely how fast a new function version is deployed.

var application lambdaApplication
var alias alias
config := codedeploy.NewLambdaDeploymentConfig(this, jsii.String("CustomConfig"), &LambdaDeploymentConfigProps{
	TrafficRouting: codedeploy.NewTimeBasedCanaryTrafficRouting(&TimeBasedCanaryTrafficRoutingProps{
		Interval: awscdk.Duration_Minutes(jsii.Number(15)),
		Percentage: jsii.Number(5),
	}),
})
deploymentGroup := codedeploy.NewLambdaDeploymentGroup(this, jsii.String("BlueGreenDeployment"), &LambdaDeploymentGroupProps{
	Application: Application,
	Alias: Alias,
	DeploymentConfig: config,
})

You can specify a custom name for your deployment config, but if you do you will not be able to update the interval/percentage through CDK.

config := codedeploy.NewLambdaDeploymentConfig(this, jsii.String("CustomConfig"), &LambdaDeploymentConfigProps{
	TrafficRouting: codedeploy.NewTimeBasedCanaryTrafficRouting(&TimeBasedCanaryTrafficRoutingProps{
		Interval: awscdk.Duration_Minutes(jsii.Number(15)),
		Percentage: jsii.Number(5),
	}),
	DeploymentConfigName: jsii.String("MyDeploymentConfig"),
})

To import an already existing Deployment Config:

deploymentConfig := codedeploy.LambdaDeploymentConfig_FromLambdaDeploymentConfigName(this, jsii.String("ExistingDeploymentConfiguration"), jsii.String("MyExistingDeploymentConfiguration"))

ECS Applications

To create a new CodeDeploy Application that deploys an ECS service:

application := codedeploy.NewEcsApplication(this, jsii.String("CodeDeployApplication"), &EcsApplicationProps{
	ApplicationName: jsii.String("MyApplication"),
})

To import an already existing Application:

application := codedeploy.EcsApplication_FromEcsApplicationName(this, jsii.String("ExistingCodeDeployApplication"), jsii.String("MyExistingApplication"))

ECS Deployment Groups

CodeDeploy can be used to deploy to load-balanced ECS services. CodeDeploy performs ECS blue-green deployments by managing ECS task sets and load balancer target groups. During a blue-green deployment, one task set and target group runs the original version of your ECS task definition ('blue') and another task set and target group runs the new version of your ECS task definition ('green').

CodeDeploy orchestrates traffic shifting during ECS blue-green deployments by using a load balancer listener to balance incoming traffic between the 'blue' and 'green' task sets/target groups running two different versions of your ECS task definition. Before deployment, the load balancer listener sends 100% of requests to the 'blue' target group. When you publish a new version of the task definition and start a CodeDeploy deployment, CodeDeploy can send a small percentage of traffic to the new 'green' task set behind the 'green' target group, monitor, and validate before shifting 100% of traffic to the new version.

To create a new CodeDeploy Deployment Group that deploys to an ECS service:

var myApplication ecsApplication
var cluster cluster
var taskDefinition fargateTaskDefinition
var blueTargetGroup iTargetGroup
var greenTargetGroup iTargetGroup
var listener iApplicationListener


service := ecs.NewFargateService(this, jsii.String("Service"), &FargateServiceProps{
	Cluster: Cluster,
	TaskDefinition: TaskDefinition,
	DeploymentController: &DeploymentController{
		Type: ecs.DeploymentControllerType_CODE_DEPLOY,
	},
})

codedeploy.NewEcsDeploymentGroup(this, jsii.String("BlueGreenDG"), &EcsDeploymentGroupProps{
	Service: Service,
	BlueGreenDeploymentConfig: &EcsBlueGreenDeploymentConfig{
		BlueTargetGroup: *BlueTargetGroup,
		GreenTargetGroup: *GreenTargetGroup,
		Listener: *Listener,
	},
	DeploymentConfig: codedeploy.EcsDeploymentConfig_CANARY_10PERCENT_5MINUTES(),
})

In order to deploy a new task definition version to the ECS service, deploy the changes directly through CodeDeploy using the CodeDeploy APIs or console. When the CODE_DEPLOY deployment controller is used, the ECS service cannot be deployed with a new task definition version through CloudFormation.

For more information on the behavior of CodeDeploy blue-green deployments for ECS, see What happens during an Amazon ECS deployment in the CodeDeploy user guide.

Note: If you wish to deploy updates to your ECS service through CDK and CloudFormation instead of directly through CodeDeploy, using the CfnCodeDeployBlueGreenHook construct is the recommended approach instead of using the EcsDeploymentGroup construct. For a comparison of ECS blue-green deployments through CodeDeploy (using EcsDeploymentGroup) and through CloudFormation (using CfnCodeDeployBlueGreenHook), see Create an Amazon ECS blue/green deployment through AWS CloudFormation in the CloudFormation user guide.

ECS Deployment Rollbacks and Alarms

CodeDeploy will automatically roll back if a deployment fails. You can optionally trigger an automatic rollback when one or more alarms are in a failed state during a deployment, or if the deployment stops.

In this example, CodeDeploy will monitor and roll back on alarms set for the number of unhealthy ECS tasks in each of the blue and green target groups, as well as alarms set for the number HTTP 5xx responses seen in each of the blue and green target groups.

import "github.com/aws/aws-cdk-go/awscdk"

var service fargateService
var blueTargetGroup applicationTargetGroup
var greenTargetGroup applicationTargetGroup
var listener iApplicationListener


// Alarm on the number of unhealthy ECS tasks in each target group
blueUnhealthyHosts := cloudwatch.NewAlarm(this, jsii.String("BlueUnhealthyHosts"), &AlarmProps{
	AlarmName: jsii.String(awscdk.stack_Of(this).stackName + "-Unhealthy-Hosts-Blue"),
	Metric: blueTargetGroup.MetricUnhealthyHostCount(),
	Threshold: jsii.Number(1),
	EvaluationPeriods: jsii.Number(2),
})

greenUnhealthyHosts := cloudwatch.NewAlarm(this, jsii.String("GreenUnhealthyHosts"), &AlarmProps{
	AlarmName: jsii.String(awscdk.stack_Of(this).stackName + "-Unhealthy-Hosts-Green"),
	Metric: greenTargetGroup.*MetricUnhealthyHostCount(),
	Threshold: jsii.Number(1),
	EvaluationPeriods: jsii.Number(2),
})

// Alarm on the number of HTTP 5xx responses returned by each target group
blueApiFailure := cloudwatch.NewAlarm(this, jsii.String("Blue5xx"), &AlarmProps{
	AlarmName: jsii.String(awscdk.stack_Of(this).stackName + "-Http-5xx-Blue"),
	Metric: blueTargetGroup.MetricHttpCodeTarget(elbv2.HttpCodeTarget_TARGET_5XX_COUNT, &MetricOptions{
		Period: awscdk.Duration_Minutes(jsii.Number(1)),
	}),
	Threshold: jsii.Number(1),
	EvaluationPeriods: jsii.Number(1),
})

greenApiFailure := cloudwatch.NewAlarm(this, jsii.String("Green5xx"), &AlarmProps{
	AlarmName: jsii.String(awscdk.stack_Of(this).stackName + "-Http-5xx-Green"),
	Metric: greenTargetGroup.*MetricHttpCodeTarget(elbv2.HttpCodeTarget_TARGET_5XX_COUNT, &MetricOptions{
		Period: awscdk.Duration_*Minutes(jsii.Number(1)),
	}),
	Threshold: jsii.Number(1),
	EvaluationPeriods: jsii.Number(1),
})

codedeploy.NewEcsDeploymentGroup(this, jsii.String("BlueGreenDG"), &EcsDeploymentGroupProps{
	// CodeDeploy will monitor these alarms during a deployment and automatically roll back
	Alarms: []iAlarm{
		blueUnhealthyHosts,
		greenUnhealthyHosts,
		blueApiFailure,
		greenApiFailure,
	},
	AutoRollback: &AutoRollbackConfig{
		// CodeDeploy will automatically roll back if a deployment is stopped
		StoppedDeployment: jsii.Boolean(true),
	},
	Service: Service,
	BlueGreenDeploymentConfig: &EcsBlueGreenDeploymentConfig{
		BlueTargetGroup: *BlueTargetGroup,
		GreenTargetGroup: *GreenTargetGroup,
		Listener: *Listener,
	},
	DeploymentConfig: codedeploy.EcsDeploymentConfig_CANARY_10PERCENT_5MINUTES(),
})
Deployment validation and manual deployment approval

CodeDeploy blue-green deployments provide an opportunity to validate the new task definition version running on the 'green' ECS task set prior to shifting any production traffic to the new version. A second 'test' listener serving traffic on a different port be added to the load balancer. For example, the test listener can serve test traffic on port 9001 while the main listener serves production traffic on port 443. During a blue-green deployment, CodeDeploy can then shift 100% of test traffic over to the 'green' task set/target group prior to shifting any production traffic during the deployment.

var myApplication ecsApplication
var service fargateService
var blueTargetGroup iTargetGroup
var greenTargetGroup iTargetGroup
var listener iApplicationListener
var testListener iApplicationListener


codedeploy.NewEcsDeploymentGroup(this, jsii.String("BlueGreenDG"), &EcsDeploymentGroupProps{
	Service: Service,
	BlueGreenDeploymentConfig: &EcsBlueGreenDeploymentConfig{
		BlueTargetGroup: *BlueTargetGroup,
		GreenTargetGroup: *GreenTargetGroup,
		Listener: *Listener,
		TestListener: *TestListener,
	},
	DeploymentConfig: codedeploy.EcsDeploymentConfig_CANARY_10PERCENT_5MINUTES(),
})

Automated validation steps can run during the CodeDeploy deployment after shifting test traffic and before shifting production traffic. CodeDeploy supports registering Lambda functions as lifecycle hooks for an ECS deployment. These Lambda functions can run automated validation steps against the test traffic port, for example in response to the AfterAllowTestTraffic lifecycle hook. For more information about how to specify the Lambda functions to run for each CodeDeploy lifecycle hook in an ECS deployment, see the AppSpec 'hooks' for an Amazon ECS deployment section in the CodeDeploy user guide.

After provisioning the 'green' ECS task set and re-routing test traffic during a blue-green deployment, CodeDeploy can wait for approval before continuing the deployment and re-routing production traffic. During this approval wait time, you can complete additional validation steps prior to exposing the new 'green' task set to production traffic, such as manual testing through the test listener port or running automated integration test suites.

To approve the deployment, validation steps use the CodeDeploy [ContinueDeployment API(https://docs.aws.amazon.com/codedeploy/latest/APIReference/API_ContinueDeployment.html). If the ContinueDeployment API is not called within the approval wait time period, CodeDeploy will stop the deployment and can automatically roll back the deployment.

var service fargateService
var blueTargetGroup iTargetGroup
var greenTargetGroup iTargetGroup
var listener iApplicationListener
var testListener iApplicationListener


codedeploy.NewEcsDeploymentGroup(this, jsii.String("BlueGreenDG"), &EcsDeploymentGroupProps{
	AutoRollback: &AutoRollbackConfig{
		// CodeDeploy will automatically roll back if the 8-hour approval period times out and the deployment stops
		StoppedDeployment: jsii.Boolean(true),
	},
	Service: Service,
	BlueGreenDeploymentConfig: &EcsBlueGreenDeploymentConfig{
		// The deployment will wait for approval for up to 8 hours before stopping the deployment
		DeploymentApprovalWaitTime: awscdk.Duration_Hours(jsii.Number(8)),
		BlueTargetGroup: *BlueTargetGroup,
		GreenTargetGroup: *GreenTargetGroup,
		Listener: *Listener,
		TestListener: *TestListener,
	},
	DeploymentConfig: codedeploy.EcsDeploymentConfig_CANARY_10PERCENT_5MINUTES(),
})
Deployment bake time

You can specify how long CodeDeploy waits before it terminates the original 'blue' ECS task set when a blue-green deployment is complete in order to let the deployment "bake" a while. During this bake time, CodeDeploy will continue to monitor any CloudWatch alarms specified for the deployment group and will automatically roll back if those alarms go into a failed state.

import "github.com/aws/aws-cdk-go/awscdk"

var service fargateService
var blueTargetGroup iTargetGroup
var greenTargetGroup iTargetGroup
var listener iApplicationListener
var blueUnhealthyHosts alarm
var greenUnhealthyHosts alarm
var blueApiFailure alarm
var greenApiFailure alarm


codedeploy.NewEcsDeploymentGroup(this, jsii.String("BlueGreenDG"), &EcsDeploymentGroupProps{
	Service: Service,
	BlueGreenDeploymentConfig: &EcsBlueGreenDeploymentConfig{
		BlueTargetGroup: *BlueTargetGroup,
		GreenTargetGroup: *GreenTargetGroup,
		Listener: *Listener,
		// CodeDeploy will wait for 30 minutes after completing the blue-green deployment before it terminates the blue tasks
		TerminationWaitTime: awscdk.Duration_Minutes(jsii.Number(30)),
	},
	// CodeDeploy will continue to monitor these alarms during the 30-minute bake time and will automatically
	// roll back if they go into a failed state at any point during the deployment.
	Alarms: []iAlarm{
		blueUnhealthyHosts,
		greenUnhealthyHosts,
		blueApiFailure,
		greenApiFailure,
	},
	DeploymentConfig: codedeploy.EcsDeploymentConfig_CANARY_10PERCENT_5MINUTES(),
})
Import an existing ECS Deployment Group

To import an already existing Deployment Group:

var application ecsApplication

deploymentGroup := codedeploy.EcsDeploymentGroup_FromEcsDeploymentGroupAttributes(this, jsii.String("ExistingCodeDeployDeploymentGroup"), &EcsDeploymentGroupAttributes{
	Application: Application,
	DeploymentGroupName: jsii.String("MyExistingDeploymentGroup"),
})

ECS Deployment Configurations

CodeDeploy for ECS comes with predefined configurations for traffic shifting. The predefined configurations are available as LambdaDeploymentConfig constants.

config := codedeploy.EcsDeploymentConfig_CANARY_10PERCENT_5MINUTES()

If you want to specify your own strategy, you can do so with the EcsDeploymentConfig construct, letting you specify precisely how fast an ECS service is deployed.

codedeploy.NewEcsDeploymentConfig(this, jsii.String("CustomConfig"), &EcsDeploymentConfigProps{
	TrafficRouting: codedeploy.NewTimeBasedCanaryTrafficRouting(&TimeBasedCanaryTrafficRoutingProps{
		Interval: awscdk.Duration_Minutes(jsii.Number(15)),
		Percentage: jsii.Number(5),
	}),
})

You can specify a custom name for your deployment config, but if you do you will not be able to update the interval/percentage through CDK.

config := codedeploy.NewEcsDeploymentConfig(this, jsii.String("CustomConfig"), &EcsDeploymentConfigProps{
	TrafficRouting: codedeploy.NewTimeBasedCanaryTrafficRouting(&TimeBasedCanaryTrafficRoutingProps{
		Interval: awscdk.Duration_Minutes(jsii.Number(15)),
		Percentage: jsii.Number(5),
	}),
	DeploymentConfigName: jsii.String("MyDeploymentConfig"),
})

Or import an existing one:

deploymentConfig := codedeploy.EcsDeploymentConfig_FromEcsDeploymentConfigName(this, jsii.String("ExistingDeploymentConfiguration"), jsii.String("MyExistingDeploymentConfiguration"))

ECS Deployments

An experimental construct is available on the Construct Hub called @cdklabs/cdk-ecs-codedeploy that manages ECS CodeDeploy deployments.

var deploymentGroup iEcsDeploymentGroup
var taskDefinition iTaskDefinition


NewEcsDeployment(map[string]interface{}{
	"deploymentGroup": deploymentGroup,
	"targetService": map[string]interface{}{
		"taskDefinition": taskDefinition,
		"containerName": jsii.String("mycontainer"),
		"containerPort": jsii.Number(80),
	},
})

The deployment will use the AutoRollbackConfig for the EcsDeploymentGroup unless it is overridden in the deployment:

var deploymentGroup iEcsDeploymentGroup
var taskDefinition iTaskDefinition


NewEcsDeployment(map[string]interface{}{
	"deploymentGroup": deploymentGroup,
	"targetService": map[string]interface{}{
		"taskDefinition": taskDefinition,
		"containerName": jsii.String("mycontainer"),
		"containerPort": jsii.Number(80),
	},
	"autoRollback": map[string]*bool{
		"failedDeployment": jsii.Boolean(true),
		"deploymentInAlarm": jsii.Boolean(true),
		"stoppedDeployment": jsii.Boolean(false),
	},
})

By default, the CodeDeploy Deployment will timeout after 30 minutes. The timeout value can be overridden:

var deploymentGroup iEcsDeploymentGroup
var taskDefinition iTaskDefinition


NewEcsDeployment(map[string]interface{}{
	"deploymentGroup": deploymentGroup,
	"targetService": map[string]interface{}{
		"taskDefinition": taskDefinition,
		"containerName": jsii.String("mycontainer"),
		"containerPort": jsii.Number(80),
	},
	"timeout": awscdk.Duration_minutes(jsii.Number(60)),
})

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BaseDeploymentConfig_IsConstruct added in v2.45.0

func BaseDeploymentConfig_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`.

func BaseDeploymentConfig_IsOwnedResource added in v2.45.0

func BaseDeploymentConfig_IsOwnedResource(construct constructs.IConstruct) *bool

Returns true if the construct was created by CDK, and false otherwise.

func BaseDeploymentConfig_IsResource added in v2.45.0

func BaseDeploymentConfig_IsResource(construct constructs.IConstruct) *bool

Check whether the given construct is a Resource.

func CfnApplication_CFN_RESOURCE_TYPE_NAME

func CfnApplication_CFN_RESOURCE_TYPE_NAME() *string

func CfnApplication_IsCfnElement

func CfnApplication_IsCfnElement(x interface{}) *bool

Returns `true` if a construct is a stack element (i.e. part of the synthesized cloudformation template).

Uses duck-typing instead of `instanceof` to allow stack elements from different versions of this library to be included in the same stack.

Returns: The construct as a stack element or undefined if it is not a stack element.

func CfnApplication_IsCfnResource

func CfnApplication_IsCfnResource(x interface{}) *bool

Check whether the given object is a CfnResource.

func CfnApplication_IsConstruct

func CfnApplication_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`.

func CfnDeploymentConfig_CFN_RESOURCE_TYPE_NAME

func CfnDeploymentConfig_CFN_RESOURCE_TYPE_NAME() *string

func CfnDeploymentConfig_IsCfnElement

func CfnDeploymentConfig_IsCfnElement(x interface{}) *bool

Returns `true` if a construct is a stack element (i.e. part of the synthesized cloudformation template).

Uses duck-typing instead of `instanceof` to allow stack elements from different versions of this library to be included in the same stack.

Returns: The construct as a stack element or undefined if it is not a stack element.

func CfnDeploymentConfig_IsCfnResource

func CfnDeploymentConfig_IsCfnResource(x interface{}) *bool

Check whether the given object is a CfnResource.

func CfnDeploymentConfig_IsConstruct

func CfnDeploymentConfig_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`.

func CfnDeploymentGroup_CFN_RESOURCE_TYPE_NAME

func CfnDeploymentGroup_CFN_RESOURCE_TYPE_NAME() *string

func CfnDeploymentGroup_IsCfnElement

func CfnDeploymentGroup_IsCfnElement(x interface{}) *bool

Returns `true` if a construct is a stack element (i.e. part of the synthesized cloudformation template).

Uses duck-typing instead of `instanceof` to allow stack elements from different versions of this library to be included in the same stack.

Returns: The construct as a stack element or undefined if it is not a stack element.

func CfnDeploymentGroup_IsCfnResource

func CfnDeploymentGroup_IsCfnResource(x interface{}) *bool

Check whether the given object is a CfnResource.

func CfnDeploymentGroup_IsConstruct

func CfnDeploymentGroup_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`.

func CustomLambdaDeploymentConfig_IsConstruct

func CustomLambdaDeploymentConfig_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`. Deprecated: CloudFormation now supports Lambda deployment configurations without custom resources. Use `LambdaDeploymentConfig`.

func CustomLambdaDeploymentConfig_IsOwnedResource added in v2.32.0

func CustomLambdaDeploymentConfig_IsOwnedResource(construct constructs.IConstruct) *bool

Returns true if the construct was created by CDK, and false otherwise. Deprecated: CloudFormation now supports Lambda deployment configurations without custom resources. Use `LambdaDeploymentConfig`.

func CustomLambdaDeploymentConfig_IsResource

func CustomLambdaDeploymentConfig_IsResource(construct constructs.IConstruct) *bool

Check whether the given construct is a Resource. Deprecated: CloudFormation now supports Lambda deployment configurations without custom resources. Use `LambdaDeploymentConfig`.

func EcsApplication_IsConstruct

func EcsApplication_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`.

func EcsApplication_IsOwnedResource added in v2.32.0

func EcsApplication_IsOwnedResource(construct constructs.IConstruct) *bool

Returns true if the construct was created by CDK, and false otherwise.

func EcsApplication_IsResource

func EcsApplication_IsResource(construct constructs.IConstruct) *bool

Check whether the given construct is a Resource.

func EcsDeploymentConfig_IsConstruct added in v2.45.0

func EcsDeploymentConfig_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`.

func EcsDeploymentConfig_IsOwnedResource added in v2.45.0

func EcsDeploymentConfig_IsOwnedResource(construct constructs.IConstruct) *bool

Returns true if the construct was created by CDK, and false otherwise.

func EcsDeploymentConfig_IsResource added in v2.45.0

func EcsDeploymentConfig_IsResource(construct constructs.IConstruct) *bool

Check whether the given construct is a Resource.

func EcsDeploymentGroup_IsConstruct added in v2.50.0

func EcsDeploymentGroup_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`.

func EcsDeploymentGroup_IsOwnedResource added in v2.50.0

func EcsDeploymentGroup_IsOwnedResource(construct constructs.IConstruct) *bool

Returns true if the construct was created by CDK, and false otherwise.

func EcsDeploymentGroup_IsResource added in v2.50.0

func EcsDeploymentGroup_IsResource(construct constructs.IConstruct) *bool

Check whether the given construct is a Resource.

func LambdaApplication_IsConstruct

func LambdaApplication_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`.

func LambdaApplication_IsOwnedResource added in v2.32.0

func LambdaApplication_IsOwnedResource(construct constructs.IConstruct) *bool

Returns true if the construct was created by CDK, and false otherwise.

func LambdaApplication_IsResource

func LambdaApplication_IsResource(construct constructs.IConstruct) *bool

Check whether the given construct is a Resource.

func LambdaDeploymentConfig_IsConstruct added in v2.45.0

func LambdaDeploymentConfig_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`.

func LambdaDeploymentConfig_IsOwnedResource added in v2.45.0

func LambdaDeploymentConfig_IsOwnedResource(construct constructs.IConstruct) *bool

Returns true if the construct was created by CDK, and false otherwise.

func LambdaDeploymentConfig_IsResource added in v2.45.0

func LambdaDeploymentConfig_IsResource(construct constructs.IConstruct) *bool

Check whether the given construct is a Resource.

func LambdaDeploymentGroup_IsConstruct

func LambdaDeploymentGroup_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`.

func LambdaDeploymentGroup_IsOwnedResource added in v2.32.0

func LambdaDeploymentGroup_IsOwnedResource(construct constructs.IConstruct) *bool

Returns true if the construct was created by CDK, and false otherwise.

func LambdaDeploymentGroup_IsResource

func LambdaDeploymentGroup_IsResource(construct constructs.IConstruct) *bool

Check whether the given construct is a Resource.

func NewAllAtOnceTrafficRouting_Override added in v2.45.0

func NewAllAtOnceTrafficRouting_Override(a AllAtOnceTrafficRouting)

func NewBaseDeploymentConfig_Override added in v2.45.0

func NewBaseDeploymentConfig_Override(b BaseDeploymentConfig, scope constructs.Construct, id *string, props *BaseDeploymentConfigProps)

func NewCfnApplication_Override

func NewCfnApplication_Override(c CfnApplication, scope constructs.Construct, id *string, props *CfnApplicationProps)

func NewCfnDeploymentConfig_Override

func NewCfnDeploymentConfig_Override(c CfnDeploymentConfig, scope constructs.Construct, id *string, props *CfnDeploymentConfigProps)

func NewCfnDeploymentGroup_Override

func NewCfnDeploymentGroup_Override(c CfnDeploymentGroup, scope constructs.Construct, id *string, props *CfnDeploymentGroupProps)

func NewCustomLambdaDeploymentConfig_Override deprecated

func NewCustomLambdaDeploymentConfig_Override(c CustomLambdaDeploymentConfig, scope constructs.Construct, id *string, props *CustomLambdaDeploymentConfigProps)

Deprecated: CloudFormation now supports Lambda deployment configurations without custom resources. Use `LambdaDeploymentConfig`.

func NewEcsApplication_Override

func NewEcsApplication_Override(e EcsApplication, scope constructs.Construct, id *string, props *EcsApplicationProps)

func NewEcsDeploymentConfig_Override added in v2.45.0

func NewEcsDeploymentConfig_Override(e EcsDeploymentConfig, scope constructs.Construct, id *string, props *EcsDeploymentConfigProps)

func NewEcsDeploymentGroup_Override added in v2.50.0

func NewEcsDeploymentGroup_Override(e EcsDeploymentGroup, scope constructs.Construct, id *string, props *EcsDeploymentGroupProps)

func NewInstanceTagSet_Override

func NewInstanceTagSet_Override(i InstanceTagSet, instanceTagGroups ...*map[string]*[]*string)

func NewLambdaApplication_Override

func NewLambdaApplication_Override(l LambdaApplication, scope constructs.Construct, id *string, props *LambdaApplicationProps)

func NewLambdaDeploymentConfig_Override added in v2.45.0

func NewLambdaDeploymentConfig_Override(l LambdaDeploymentConfig, scope constructs.Construct, id *string, props *LambdaDeploymentConfigProps)

func NewLambdaDeploymentGroup_Override

func NewLambdaDeploymentGroup_Override(l LambdaDeploymentGroup, scope constructs.Construct, id *string, props *LambdaDeploymentGroupProps)

func NewLoadBalancer_Override

func NewLoadBalancer_Override(l LoadBalancer)

func NewServerApplication_Override

func NewServerApplication_Override(s ServerApplication, scope constructs.Construct, id *string, props *ServerApplicationProps)

func NewServerDeploymentConfig_Override

func NewServerDeploymentConfig_Override(s ServerDeploymentConfig, scope constructs.Construct, id *string, props *ServerDeploymentConfigProps)

func NewServerDeploymentGroup_Override

func NewServerDeploymentGroup_Override(s ServerDeploymentGroup, scope constructs.Construct, id *string, props *ServerDeploymentGroupProps)

func NewTimeBasedCanaryTrafficRouting_Override added in v2.45.0

func NewTimeBasedCanaryTrafficRouting_Override(t TimeBasedCanaryTrafficRouting, props *TimeBasedCanaryTrafficRoutingProps)

func NewTimeBasedLinearTrafficRouting_Override added in v2.45.0

func NewTimeBasedLinearTrafficRouting_Override(t TimeBasedLinearTrafficRouting, props *TimeBasedLinearTrafficRoutingProps)

func NewTrafficRouting_Override added in v2.45.0

func NewTrafficRouting_Override(t TrafficRouting)

func ServerApplication_IsConstruct

func ServerApplication_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`.

func ServerApplication_IsOwnedResource added in v2.32.0

func ServerApplication_IsOwnedResource(construct constructs.IConstruct) *bool

Returns true if the construct was created by CDK, and false otherwise.

func ServerApplication_IsResource

func ServerApplication_IsResource(construct constructs.IConstruct) *bool

Check whether the given construct is a Resource.

func ServerDeploymentConfig_IsConstruct

func ServerDeploymentConfig_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`.

func ServerDeploymentConfig_IsOwnedResource added in v2.32.0

func ServerDeploymentConfig_IsOwnedResource(construct constructs.IConstruct) *bool

Returns true if the construct was created by CDK, and false otherwise.

func ServerDeploymentConfig_IsResource

func ServerDeploymentConfig_IsResource(construct constructs.IConstruct) *bool

Check whether the given construct is a Resource.

func ServerDeploymentGroup_IsConstruct

func ServerDeploymentGroup_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`.

func ServerDeploymentGroup_IsOwnedResource added in v2.32.0

func ServerDeploymentGroup_IsOwnedResource(construct constructs.IConstruct) *bool

Returns true if the construct was created by CDK, and false otherwise.

func ServerDeploymentGroup_IsResource

func ServerDeploymentGroup_IsResource(construct constructs.IConstruct) *bool

Check whether the given construct is a Resource.

Types

type AllAtOnceTrafficRouting added in v2.45.0

type AllAtOnceTrafficRouting interface {
	TrafficRouting
	// Return a TrafficRoutingConfig of type `AllAtOnce`.
	Bind(_scope constructs.Construct) *TrafficRoutingConfig
}

Define a traffic routing config of type 'AllAtOnce'.

Example:

// 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"

allAtOnceTrafficRouting := awscdk.Aws_codedeploy.AllAtOnceTrafficRouting_AllAtOnce()

func NewAllAtOnceTrafficRouting added in v2.45.0

func NewAllAtOnceTrafficRouting() AllAtOnceTrafficRouting

type AutoRollbackConfig

type AutoRollbackConfig struct {
	// Whether to automatically roll back a deployment during which one of the configured CloudWatch alarms for this Deployment Group went off.
	// Default: true if you've provided any Alarms with the `alarms` property, false otherwise.
	//
	DeploymentInAlarm *bool `field:"optional" json:"deploymentInAlarm" yaml:"deploymentInAlarm"`
	// Whether to automatically roll back a deployment that fails.
	// Default: true.
	//
	FailedDeployment *bool `field:"optional" json:"failedDeployment" yaml:"failedDeployment"`
	// Whether to automatically roll back a deployment that was manually stopped.
	// Default: false.
	//
	StoppedDeployment *bool `field:"optional" json:"stoppedDeployment" yaml:"stoppedDeployment"`
}

The configuration for automatically rolling back deployments in a given Deployment Group.

Example:

import autoscaling "github.com/aws/aws-cdk-go/awscdk"
import cloudwatch "github.com/aws/aws-cdk-go/awscdk"

var application serverApplication
var asg autoScalingGroup
var alarm alarm

deploymentGroup := codedeploy.NewServerDeploymentGroup(this, jsii.String("CodeDeployDeploymentGroup"), &ServerDeploymentGroupProps{
	Application: Application,
	DeploymentGroupName: jsii.String("MyDeploymentGroup"),
	AutoScalingGroups: []iAutoScalingGroup{
		asg,
	},
	// adds User Data that installs the CodeDeploy agent on your auto-scaling groups hosts
	// default: true
	InstallAgent: jsii.Boolean(true),
	// adds EC2 instances matching tags
	Ec2InstanceTags: codedeploy.NewInstanceTagSet(map[string][]*string{
		// any instance with tags satisfying
		// key1=v1 or key1=v2 or key2 (any value) or value v3 (any key)
		// will match this group
		"key1": []*string{
			jsii.String("v1"),
			jsii.String("v2"),
		},
		"key2": []*string{
		},
		"": []*string{
			jsii.String("v3"),
		},
	}),
	// adds on-premise instances matching tags
	OnPremiseInstanceTags: codedeploy.NewInstanceTagSet(map[string][]*string{
		"key1": []*string{
			jsii.String("v1"),
			jsii.String("v2"),
		},
	}, map[string][]*string{
		"key2": []*string{
			jsii.String("v3"),
		},
	}),
	// CloudWatch alarms
	Alarms: []iAlarm{
		alarm,
	},
	// whether to ignore failure to fetch the status of alarms from CloudWatch
	// default: false
	IgnorePollAlarmsFailure: jsii.Boolean(false),
	// whether to skip the step of checking CloudWatch alarms during the deployment process
	// default: false
	IgnoreAlarmConfiguration: jsii.Boolean(false),
	// auto-rollback configuration
	AutoRollback: &AutoRollbackConfig{
		FailedDeployment: jsii.Boolean(true),
		 // default: true
		StoppedDeployment: jsii.Boolean(true),
		 // default: false
		DeploymentInAlarm: jsii.Boolean(true),
	},
})

type BaseDeploymentConfig added in v2.45.0

type BaseDeploymentConfig interface {
	awscdk.Resource
	IBaseDeploymentConfig
	// The arn of the deployment config.
	DeploymentConfigArn() *string
	// The name of the deployment config.
	DeploymentConfigName() *string
	// The environment this resource belongs to.
	//
	// For resources that are created and managed by the CDK
	// (generally, those created by creating new class instances like Role, Bucket, etc.),
	// this is always the same as the environment of the stack they belong to;
	// however, for imported resources
	// (those obtained from static methods like fromRoleArn, fromBucketName, etc.),
	// that might be different than the stack they were imported into.
	Env() *awscdk.ResourceEnvironment
	// The tree node.
	Node() constructs.Node
	// Returns a string-encoded token that resolves to the physical name that should be passed to the CloudFormation resource.
	//
	// This value will resolve to one of the following:
	// - a concrete value (e.g. `"my-awesome-bucket"`)
	// - `undefined`, when a name should be generated by CloudFormation
	// - a concrete name generated automatically during synthesis, in
	//   cross-environment scenarios.
	PhysicalName() *string
	// The stack in which this resource is defined.
	Stack() awscdk.Stack
	// Apply the given removal policy to this resource.
	//
	// The Removal Policy controls what happens to this resource when it stops
	// being managed by CloudFormation, either because you've removed it from the
	// CDK application or because you've made a change that requires the resource
	// to be replaced.
	//
	// The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS
	// account for data recovery and cleanup later (`RemovalPolicy.RETAIN`).
	ApplyRemovalPolicy(policy awscdk.RemovalPolicy)
	GeneratePhysicalName() *string
	// Returns an environment-sensitive token that should be used for the resource's "ARN" attribute (e.g. `bucket.bucketArn`).
	//
	// Normally, this token will resolve to `arnAttr`, but if the resource is
	// referenced across environments, `arnComponents` will be used to synthesize
	// a concrete ARN with the resource's physical name. Make sure to reference
	// `this.physicalName` in `arnComponents`.
	GetResourceArnAttribute(arnAttr *string, arnComponents *awscdk.ArnComponents) *string
	// Returns an environment-sensitive token that should be used for the resource's "name" attribute (e.g. `bucket.bucketName`).
	//
	// Normally, this token will resolve to `nameAttr`, but if the resource is
	// referenced across environments, it will be resolved to `this.physicalName`,
	// which will be a concrete name.
	GetResourceNameAttribute(nameAttr *string) *string
	// Returns a string representation of this construct.
	ToString() *string
}

The base class for ServerDeploymentConfig, EcsDeploymentConfig, and LambdaDeploymentConfig deployment configurations.

type BaseDeploymentConfigOptions added in v2.45.0

type BaseDeploymentConfigOptions struct {
	// The physical, human-readable name of the Deployment Configuration.
	// Default: - automatically generated name.
	//
	DeploymentConfigName *string `field:"optional" json:"deploymentConfigName" yaml:"deploymentConfigName"`
}

Construction properties of `BaseDeploymentConfig`.

Example:

// 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"

baseDeploymentConfigOptions := &BaseDeploymentConfigOptions{
	DeploymentConfigName: jsii.String("deploymentConfigName"),
}

type BaseDeploymentConfigProps added in v2.45.0

type BaseDeploymentConfigProps struct {
	// The physical, human-readable name of the Deployment Configuration.
	// Default: - automatically generated name.
	//
	DeploymentConfigName *string `field:"optional" json:"deploymentConfigName" yaml:"deploymentConfigName"`
	// The destination compute platform for the deployment.
	// Default: ComputePlatform.Server
	//
	ComputePlatform ComputePlatform `field:"optional" json:"computePlatform" yaml:"computePlatform"`
	// Minimum number of healthy hosts.
	// Default: None.
	//
	MinimumHealthyHosts MinimumHealthyHosts `field:"optional" json:"minimumHealthyHosts" yaml:"minimumHealthyHosts"`
	// The configuration that specifies how traffic is shifted during a deployment.
	//
	// Only applicable to ECS and Lambda deployments, and must not be specified for Server deployments.
	// Default: None.
	//
	TrafficRouting TrafficRouting `field:"optional" json:"trafficRouting" yaml:"trafficRouting"`
}

Complete base deployment config properties that are required to be supplied by the implementation of the BaseDeploymentConfig class.

Example:

// 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"

var minimumHealthyHosts minimumHealthyHosts
var trafficRouting trafficRouting

baseDeploymentConfigProps := &BaseDeploymentConfigProps{
	ComputePlatform: awscdk.Aws_codedeploy.ComputePlatform_SERVER,
	DeploymentConfigName: jsii.String("deploymentConfigName"),
	MinimumHealthyHosts: minimumHealthyHosts,
	TrafficRouting: trafficRouting,
}

type BaseTrafficShiftingConfigProps added in v2.45.0

type BaseTrafficShiftingConfigProps struct {
	// The amount of time between traffic shifts.
	Interval awscdk.Duration `field:"required" json:"interval" yaml:"interval"`
	// The percentage to increase traffic on each traffic shift.
	Percentage *float64 `field:"required" json:"percentage" yaml:"percentage"`
}

Common properties of traffic shifting routing configurations.

Example:

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import cdk "github.com/aws/aws-cdk-go/awscdk"
import "github.com/aws/aws-cdk-go/awscdk"

baseTrafficShiftingConfigProps := &BaseTrafficShiftingConfigProps{
	Interval: cdk.Duration_Minutes(jsii.Number(30)),
	Percentage: jsii.Number(123),
}

type CanaryTrafficRoutingConfig added in v2.45.0

type CanaryTrafficRoutingConfig struct {
	// The number of minutes between the first and second traffic shifts of a `TimeBasedCanary` deployment.
	CanaryInterval *float64 `field:"required" json:"canaryInterval" yaml:"canaryInterval"`
	// The percentage of traffic to shift in the first increment of a `TimeBasedCanary` deployment.
	CanaryPercentage *float64 `field:"required" json:"canaryPercentage" yaml:"canaryPercentage"`
}

Represents the configuration specific to canary traffic shifting.

Example:

// 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"

canaryTrafficRoutingConfig := &CanaryTrafficRoutingConfig{
	CanaryInterval: jsii.Number(123),
	CanaryPercentage: jsii.Number(123),
}

type CfnApplication

type CfnApplication interface {
	awscdk.CfnResource
	awscdk.IInspectable
	awscdk.ITaggable
	// A name for the application.
	ApplicationName() *string
	SetApplicationName(val *string)
	// Options for this resource, such as condition, update policy etc.
	CfnOptions() awscdk.ICfnResourceOptions
	CfnProperties() *map[string]interface{}
	// AWS resource type.
	CfnResourceType() *string
	// The compute platform that CodeDeploy deploys the application to.
	ComputePlatform() *string
	SetComputePlatform(val *string)
	// Returns: the stack trace of the point where this Resource was created from, sourced
	// from the +metadata+ entry typed +aws:cdk:logicalId+, and with the bottom-most
	// node +internal+ entries filtered.
	CreationStack() *[]*string
	// The logical ID for this CloudFormation stack element.
	//
	// The logical ID of the element
	// is calculated from the path of the resource node in the construct tree.
	//
	// To override this value, use `overrideLogicalId(newLogicalId)`.
	//
	// Returns: the logical ID as a stringified token. This value will only get
	// resolved during synthesis.
	LogicalId() *string
	// The tree node.
	Node() constructs.Node
	// Return a string that will be resolved to a CloudFormation `{ Ref }` for this element.
	//
	// If, by any chance, the intrinsic reference of a resource is not a string, you could
	// coerce it to an IResolvable through `Lazy.any({ produce: resource.ref })`.
	Ref() *string
	// The stack in which this element is defined.
	//
	// CfnElements must be defined within a stack scope (directly or indirectly).
	Stack() awscdk.Stack
	// Tag Manager which manages the tags for this resource.
	Tags() awscdk.TagManager
	// The metadata that you apply to CodeDeploy applications to help you organize and categorize them.
	TagsRaw() *[]*awscdk.CfnTag
	SetTagsRaw(val *[]*awscdk.CfnTag)
	// Deprecated.
	// Deprecated: use `updatedProperties`
	//
	// Return properties modified after initiation
	//
	// Resources that expose mutable properties should override this function to
	// collect and return the properties object for this resource.
	UpdatedProperites() *map[string]interface{}
	// Return properties modified after initiation.
	//
	// Resources that expose mutable properties should override this function to
	// collect and return the properties object for this resource.
	UpdatedProperties() *map[string]interface{}
	// Syntactic sugar for `addOverride(path, undefined)`.
	AddDeletionOverride(path *string)
	// Indicates that this resource depends on another resource and cannot be provisioned unless the other resource has been successfully provisioned.
	//
	// This can be used for resources across stacks (or nested stack) boundaries
	// and the dependency will automatically be transferred to the relevant scope.
	AddDependency(target awscdk.CfnResource)
	// Indicates that this resource depends on another resource and cannot be provisioned unless the other resource has been successfully provisioned.
	// Deprecated: use addDependency.
	AddDependsOn(target awscdk.CfnResource)
	// Add a value to the CloudFormation Resource Metadata.
	// See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/metadata-section-structure.html
	//
	// Note that this is a different set of metadata from CDK node metadata; this
	// metadata ends up in the stack template under the resource, whereas CDK
	// node metadata ends up in the Cloud Assembly.
	//
	AddMetadata(key *string, value interface{})
	// Adds an override to the synthesized CloudFormation resource.
	//
	// To add a
	// property override, either use `addPropertyOverride` or prefix `path` with
	// "Properties." (i.e. `Properties.TopicName`).
	//
	// If the override is nested, separate each nested level using a dot (.) in the path parameter.
	// If there is an array as part of the nesting, specify the index in the path.
	//
	// To include a literal `.` in the property name, prefix with a `\`. In most
	// programming languages you will need to write this as `"\\."` because the
	// `\` itself will need to be escaped.
	//
	// For example,
	// “`typescript
	// cfnResource.addOverride('Properties.GlobalSecondaryIndexes.0.Projection.NonKeyAttributes', ['myattribute']);
	// cfnResource.addOverride('Properties.GlobalSecondaryIndexes.1.ProjectionType', 'INCLUDE');
	// “`
	// would add the overrides
	// “`json
	// "Properties": {
	//   "GlobalSecondaryIndexes": [
	//     {
	//       "Projection": {
	//         "NonKeyAttributes": [ "myattribute" ]
	//         ...
	//       }
	//       ...
	//     },
	//     {
	//       "ProjectionType": "INCLUDE"
	//       ...
	//     },
	//   ]
	//   ...
	// }
	// “`
	//
	// The `value` argument to `addOverride` will not be processed or translated
	// in any way. Pass raw JSON values in here with the correct capitalization
	// for CloudFormation. If you pass CDK classes or structs, they will be
	// rendered with lowercased key names, and CloudFormation will reject the
	// template.
	AddOverride(path *string, value interface{})
	// Adds an override that deletes the value of a property from the resource definition.
	AddPropertyDeletionOverride(propertyPath *string)
	// Adds an override to a resource property.
	//
	// Syntactic sugar for `addOverride("Properties.<...>", value)`.
	AddPropertyOverride(propertyPath *string, value interface{})
	// Sets the deletion policy of the resource based on the removal policy specified.
	//
	// The Removal Policy controls what happens to this resource when it stops
	// being managed by CloudFormation, either because you've removed it from the
	// CDK application or because you've made a change that requires the resource
	// to be replaced.
	//
	// The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS
	// account for data recovery and cleanup later (`RemovalPolicy.RETAIN`). In some
	// cases, a snapshot can be taken of the resource prior to deletion
	// (`RemovalPolicy.SNAPSHOT`). A list of resources that support this policy
	// can be found in the following link:.
	// See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-attribute-deletionpolicy.html#aws-attribute-deletionpolicy-options
	//
	ApplyRemovalPolicy(policy awscdk.RemovalPolicy, options *awscdk.RemovalPolicyOptions)
	// Returns a token for an runtime attribute of this resource.
	//
	// Ideally, use generated attribute accessors (e.g. `resource.arn`), but this can be used for future compatibility
	// in case there is no generated attribute.
	GetAtt(attributeName *string, typeHint awscdk.ResolutionTypeHint) awscdk.Reference
	// Retrieve a value value from the CloudFormation Resource Metadata.
	// See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/metadata-section-structure.html
	//
	// Note that this is a different set of metadata from CDK node metadata; this
	// metadata ends up in the stack template under the resource, whereas CDK
	// node metadata ends up in the Cloud Assembly.
	//
	GetMetadata(key *string) interface{}
	// Examines the CloudFormation resource and discloses attributes.
	Inspect(inspector awscdk.TreeInspector)
	// Retrieves an array of resources this resource depends on.
	//
	// This assembles dependencies on resources across stacks (including nested stacks)
	// automatically.
	ObtainDependencies() *[]interface{}
	// Get a shallow copy of dependencies between this resource and other resources in the same stack.
	ObtainResourceDependencies() *[]awscdk.CfnResource
	// Overrides the auto-generated logical ID with a specific ID.
	OverrideLogicalId(newLogicalId *string)
	// Indicates that this resource no longer depends on another resource.
	//
	// This can be used for resources across stacks (including nested stacks)
	// and the dependency will automatically be removed from the relevant scope.
	RemoveDependency(target awscdk.CfnResource)
	RenderProperties(props *map[string]interface{}) *map[string]interface{}
	// Replaces one dependency with another.
	ReplaceDependency(target awscdk.CfnResource, newTarget awscdk.CfnResource)
	// Can be overridden by subclasses to determine if this resource will be rendered into the cloudformation template.
	//
	// Returns: `true` if the resource should be included or `false` is the resource
	// should be omitted.
	ShouldSynthesize() *bool
	// Returns a string representation of this construct.
	//
	// Returns: a string representation of this resource.
	ToString() *string
	ValidateProperties(_properties interface{})
}

The `AWS::CodeDeploy::Application` resource creates an AWS CodeDeploy application.

In CodeDeploy , an application is a name that functions as a container to ensure that the correct combination of revision, deployment configuration, and deployment group are referenced during a deployment. You can use the `AWS::CodeDeploy::DeploymentGroup` resource to associate the application with a CodeDeploy deployment group. For more information, see [CodeDeploy Deployments](https://docs.aws.amazon.com/codedeploy/latest/userguide/deployment-steps.html) in the *AWS CodeDeploy User Guide* .

Example:

// 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"

cfnApplication := awscdk.Aws_codedeploy.NewCfnApplication(this, jsii.String("MyCfnApplication"), &CfnApplicationProps{
	ApplicationName: jsii.String("applicationName"),
	ComputePlatform: jsii.String("computePlatform"),
	Tags: []cfnTag{
		&cfnTag{
			Key: jsii.String("key"),
			Value: jsii.String("value"),
		},
	},
})

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-application.html

func NewCfnApplication

func NewCfnApplication(scope constructs.Construct, id *string, props *CfnApplicationProps) CfnApplication

type CfnApplicationProps

type CfnApplicationProps struct {
	// A name for the application.
	//
	// If you don't specify a name, AWS CloudFormation generates a unique physical ID and uses that ID for the application name. For more information, see [Name Type](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-name.html) .
	//
	// > Updates to `ApplicationName` are not supported.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-application.html#cfn-codedeploy-application-applicationname
	//
	ApplicationName *string `field:"optional" json:"applicationName" yaml:"applicationName"`
	// The compute platform that CodeDeploy deploys the application to.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-application.html#cfn-codedeploy-application-computeplatform
	//
	ComputePlatform *string `field:"optional" json:"computePlatform" yaml:"computePlatform"`
	// The metadata that you apply to CodeDeploy applications to help you organize and categorize them.
	//
	// Each tag consists of a key and an optional value, both of which you define.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-application.html#cfn-codedeploy-application-tags
	//
	Tags *[]*awscdk.CfnTag `field:"optional" json:"tags" yaml:"tags"`
}

Properties for defining a `CfnApplication`.

Example:

// 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"

cfnApplicationProps := &CfnApplicationProps{
	ApplicationName: jsii.String("applicationName"),
	ComputePlatform: jsii.String("computePlatform"),
	Tags: []cfnTag{
		&cfnTag{
			Key: jsii.String("key"),
			Value: jsii.String("value"),
		},
	},
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-application.html

type CfnDeploymentConfig

type CfnDeploymentConfig interface {
	awscdk.CfnResource
	awscdk.IInspectable
	// Options for this resource, such as condition, update policy etc.
	CfnOptions() awscdk.ICfnResourceOptions
	CfnProperties() *map[string]interface{}
	// AWS resource type.
	CfnResourceType() *string
	// The destination platform type for the deployment ( `Lambda` , `Server` , or `ECS` ).
	ComputePlatform() *string
	SetComputePlatform(val *string)
	// Returns: the stack trace of the point where this Resource was created from, sourced
	// from the +metadata+ entry typed +aws:cdk:logicalId+, and with the bottom-most
	// node +internal+ entries filtered.
	CreationStack() *[]*string
	// A name for the deployment configuration.
	DeploymentConfigName() *string
	SetDeploymentConfigName(val *string)
	// The logical ID for this CloudFormation stack element.
	//
	// The logical ID of the element
	// is calculated from the path of the resource node in the construct tree.
	//
	// To override this value, use `overrideLogicalId(newLogicalId)`.
	//
	// Returns: the logical ID as a stringified token. This value will only get
	// resolved during synthesis.
	LogicalId() *string
	// The minimum number of healthy instances that should be available at any time during the deployment.
	MinimumHealthyHosts() interface{}
	SetMinimumHealthyHosts(val interface{})
	// The tree node.
	Node() constructs.Node
	// Return a string that will be resolved to a CloudFormation `{ Ref }` for this element.
	//
	// If, by any chance, the intrinsic reference of a resource is not a string, you could
	// coerce it to an IResolvable through `Lazy.any({ produce: resource.ref })`.
	Ref() *string
	// The stack in which this element is defined.
	//
	// CfnElements must be defined within a stack scope (directly or indirectly).
	Stack() awscdk.Stack
	// The configuration that specifies how the deployment traffic is routed.
	TrafficRoutingConfig() interface{}
	SetTrafficRoutingConfig(val interface{})
	// Deprecated.
	// Deprecated: use `updatedProperties`
	//
	// Return properties modified after initiation
	//
	// Resources that expose mutable properties should override this function to
	// collect and return the properties object for this resource.
	UpdatedProperites() *map[string]interface{}
	// Return properties modified after initiation.
	//
	// Resources that expose mutable properties should override this function to
	// collect and return the properties object for this resource.
	UpdatedProperties() *map[string]interface{}
	// Configure the `ZonalConfig` object if you want AWS CodeDeploy to deploy your application to one [Availability Zone](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-regions-availability-zones.html#concepts-availability-zones) at a time, within an AWS Region.
	ZonalConfig() interface{}
	SetZonalConfig(val interface{})
	// Syntactic sugar for `addOverride(path, undefined)`.
	AddDeletionOverride(path *string)
	// Indicates that this resource depends on another resource and cannot be provisioned unless the other resource has been successfully provisioned.
	//
	// This can be used for resources across stacks (or nested stack) boundaries
	// and the dependency will automatically be transferred to the relevant scope.
	AddDependency(target awscdk.CfnResource)
	// Indicates that this resource depends on another resource and cannot be provisioned unless the other resource has been successfully provisioned.
	// Deprecated: use addDependency.
	AddDependsOn(target awscdk.CfnResource)
	// Add a value to the CloudFormation Resource Metadata.
	// See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/metadata-section-structure.html
	//
	// Note that this is a different set of metadata from CDK node metadata; this
	// metadata ends up in the stack template under the resource, whereas CDK
	// node metadata ends up in the Cloud Assembly.
	//
	AddMetadata(key *string, value interface{})
	// Adds an override to the synthesized CloudFormation resource.
	//
	// To add a
	// property override, either use `addPropertyOverride` or prefix `path` with
	// "Properties." (i.e. `Properties.TopicName`).
	//
	// If the override is nested, separate each nested level using a dot (.) in the path parameter.
	// If there is an array as part of the nesting, specify the index in the path.
	//
	// To include a literal `.` in the property name, prefix with a `\`. In most
	// programming languages you will need to write this as `"\\."` because the
	// `\` itself will need to be escaped.
	//
	// For example,
	// “`typescript
	// cfnResource.addOverride('Properties.GlobalSecondaryIndexes.0.Projection.NonKeyAttributes', ['myattribute']);
	// cfnResource.addOverride('Properties.GlobalSecondaryIndexes.1.ProjectionType', 'INCLUDE');
	// “`
	// would add the overrides
	// “`json
	// "Properties": {
	//   "GlobalSecondaryIndexes": [
	//     {
	//       "Projection": {
	//         "NonKeyAttributes": [ "myattribute" ]
	//         ...
	//       }
	//       ...
	//     },
	//     {
	//       "ProjectionType": "INCLUDE"
	//       ...
	//     },
	//   ]
	//   ...
	// }
	// “`
	//
	// The `value` argument to `addOverride` will not be processed or translated
	// in any way. Pass raw JSON values in here with the correct capitalization
	// for CloudFormation. If you pass CDK classes or structs, they will be
	// rendered with lowercased key names, and CloudFormation will reject the
	// template.
	AddOverride(path *string, value interface{})
	// Adds an override that deletes the value of a property from the resource definition.
	AddPropertyDeletionOverride(propertyPath *string)
	// Adds an override to a resource property.
	//
	// Syntactic sugar for `addOverride("Properties.<...>", value)`.
	AddPropertyOverride(propertyPath *string, value interface{})
	// Sets the deletion policy of the resource based on the removal policy specified.
	//
	// The Removal Policy controls what happens to this resource when it stops
	// being managed by CloudFormation, either because you've removed it from the
	// CDK application or because you've made a change that requires the resource
	// to be replaced.
	//
	// The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS
	// account for data recovery and cleanup later (`RemovalPolicy.RETAIN`). In some
	// cases, a snapshot can be taken of the resource prior to deletion
	// (`RemovalPolicy.SNAPSHOT`). A list of resources that support this policy
	// can be found in the following link:.
	// See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-attribute-deletionpolicy.html#aws-attribute-deletionpolicy-options
	//
	ApplyRemovalPolicy(policy awscdk.RemovalPolicy, options *awscdk.RemovalPolicyOptions)
	// Returns a token for an runtime attribute of this resource.
	//
	// Ideally, use generated attribute accessors (e.g. `resource.arn`), but this can be used for future compatibility
	// in case there is no generated attribute.
	GetAtt(attributeName *string, typeHint awscdk.ResolutionTypeHint) awscdk.Reference
	// Retrieve a value value from the CloudFormation Resource Metadata.
	// See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/metadata-section-structure.html
	//
	// Note that this is a different set of metadata from CDK node metadata; this
	// metadata ends up in the stack template under the resource, whereas CDK
	// node metadata ends up in the Cloud Assembly.
	//
	GetMetadata(key *string) interface{}
	// Examines the CloudFormation resource and discloses attributes.
	Inspect(inspector awscdk.TreeInspector)
	// Retrieves an array of resources this resource depends on.
	//
	// This assembles dependencies on resources across stacks (including nested stacks)
	// automatically.
	ObtainDependencies() *[]interface{}
	// Get a shallow copy of dependencies between this resource and other resources in the same stack.
	ObtainResourceDependencies() *[]awscdk.CfnResource
	// Overrides the auto-generated logical ID with a specific ID.
	OverrideLogicalId(newLogicalId *string)
	// Indicates that this resource no longer depends on another resource.
	//
	// This can be used for resources across stacks (including nested stacks)
	// and the dependency will automatically be removed from the relevant scope.
	RemoveDependency(target awscdk.CfnResource)
	RenderProperties(props *map[string]interface{}) *map[string]interface{}
	// Replaces one dependency with another.
	ReplaceDependency(target awscdk.CfnResource, newTarget awscdk.CfnResource)
	// Can be overridden by subclasses to determine if this resource will be rendered into the cloudformation template.
	//
	// Returns: `true` if the resource should be included or `false` is the resource
	// should be omitted.
	ShouldSynthesize() *bool
	// Returns a string representation of this construct.
	//
	// Returns: a string representation of this resource.
	ToString() *string
	ValidateProperties(_properties interface{})
}

The `AWS::CodeDeploy::DeploymentConfig` resource creates a set of deployment rules, deployment success conditions, and deployment failure conditions that AWS CodeDeploy uses during a deployment.

The deployment configuration specifies the number or percentage of instances that must remain available at any time during a deployment.

Example:

// 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"

cfnDeploymentConfig := awscdk.Aws_codedeploy.NewCfnDeploymentConfig(this, jsii.String("MyCfnDeploymentConfig"), &CfnDeploymentConfigProps{
	ComputePlatform: jsii.String("computePlatform"),
	DeploymentConfigName: jsii.String("deploymentConfigName"),
	MinimumHealthyHosts: &MinimumHealthyHostsProperty{
		Type: jsii.String("type"),
		Value: jsii.Number(123),
	},
	TrafficRoutingConfig: &TrafficRoutingConfigProperty{
		Type: jsii.String("type"),

		// the properties below are optional
		TimeBasedCanary: &TimeBasedCanaryProperty{
			CanaryInterval: jsii.Number(123),
			CanaryPercentage: jsii.Number(123),
		},
		TimeBasedLinear: &TimeBasedLinearProperty{
			LinearInterval: jsii.Number(123),
			LinearPercentage: jsii.Number(123),
		},
	},
	ZonalConfig: &ZonalConfigProperty{
		FirstZoneMonitorDurationInSeconds: jsii.Number(123),
		MinimumHealthyHostsPerZone: &MinimumHealthyHostsPerZoneProperty{
			Type: jsii.String("type"),
			Value: jsii.Number(123),
		},
		MonitorDurationInSeconds: jsii.Number(123),
	},
})

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentconfig.html

func NewCfnDeploymentConfig

func NewCfnDeploymentConfig(scope constructs.Construct, id *string, props *CfnDeploymentConfigProps) CfnDeploymentConfig

type CfnDeploymentConfigProps

type CfnDeploymentConfigProps struct {
	// The destination platform type for the deployment ( `Lambda` , `Server` , or `ECS` ).
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentconfig.html#cfn-codedeploy-deploymentconfig-computeplatform
	//
	ComputePlatform *string `field:"optional" json:"computePlatform" yaml:"computePlatform"`
	// A name for the deployment configuration.
	//
	// If you don't specify a name, AWS CloudFormation generates a unique physical ID and uses that ID for the deployment configuration name. For more information, see [Name Type](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-name.html) .
	//
	// > If you specify a name, you cannot perform updates that require replacement of this resource. You can perform updates that require no or some interruption. If you must replace the resource, specify a new name.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentconfig.html#cfn-codedeploy-deploymentconfig-deploymentconfigname
	//
	DeploymentConfigName *string `field:"optional" json:"deploymentConfigName" yaml:"deploymentConfigName"`
	// The minimum number of healthy instances that should be available at any time during the deployment.
	//
	// There are two parameters expected in the input: type and value.
	//
	// The type parameter takes either of the following values:
	//
	// - HOST_COUNT: The value parameter represents the minimum number of healthy instances as an absolute value.
	// - FLEET_PERCENT: The value parameter represents the minimum number of healthy instances as a percentage of the total number of instances in the deployment. If you specify FLEET_PERCENT, at the start of the deployment, AWS CodeDeploy converts the percentage to the equivalent number of instance and rounds up fractional instances.
	//
	// The value parameter takes an integer.
	//
	// For example, to set a minimum of 95% healthy instance, specify a type of FLEET_PERCENT and a value of 95.
	//
	// For more information about instance health, see [CodeDeploy Instance Health](https://docs.aws.amazon.com/codedeploy/latest/userguide/instances-health.html) in the AWS CodeDeploy User Guide.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentconfig.html#cfn-codedeploy-deploymentconfig-minimumhealthyhosts
	//
	MinimumHealthyHosts interface{} `field:"optional" json:"minimumHealthyHosts" yaml:"minimumHealthyHosts"`
	// The configuration that specifies how the deployment traffic is routed.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentconfig.html#cfn-codedeploy-deploymentconfig-trafficroutingconfig
	//
	TrafficRoutingConfig interface{} `field:"optional" json:"trafficRoutingConfig" yaml:"trafficRoutingConfig"`
	// Configure the `ZonalConfig` object if you want AWS CodeDeploy to deploy your application to one [Availability Zone](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-regions-availability-zones.html#concepts-availability-zones) at a time, within an AWS Region.
	//
	// For more information about the zonal configuration feature, see [zonal configuration](https://docs.aws.amazon.com/codedeploy/latest/userguide/deployment-configurations-create.html#zonal-config) in the *CodeDeploy User Guide* .
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentconfig.html#cfn-codedeploy-deploymentconfig-zonalconfig
	//
	ZonalConfig interface{} `field:"optional" json:"zonalConfig" yaml:"zonalConfig"`
}

Properties for defining a `CfnDeploymentConfig`.

Example:

// 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"

cfnDeploymentConfigProps := &CfnDeploymentConfigProps{
	ComputePlatform: jsii.String("computePlatform"),
	DeploymentConfigName: jsii.String("deploymentConfigName"),
	MinimumHealthyHosts: &MinimumHealthyHostsProperty{
		Type: jsii.String("type"),
		Value: jsii.Number(123),
	},
	TrafficRoutingConfig: &TrafficRoutingConfigProperty{
		Type: jsii.String("type"),

		// the properties below are optional
		TimeBasedCanary: &TimeBasedCanaryProperty{
			CanaryInterval: jsii.Number(123),
			CanaryPercentage: jsii.Number(123),
		},
		TimeBasedLinear: &TimeBasedLinearProperty{
			LinearInterval: jsii.Number(123),
			LinearPercentage: jsii.Number(123),
		},
	},
	ZonalConfig: &ZonalConfigProperty{
		FirstZoneMonitorDurationInSeconds: jsii.Number(123),
		MinimumHealthyHostsPerZone: &MinimumHealthyHostsPerZoneProperty{
			Type: jsii.String("type"),
			Value: jsii.Number(123),
		},
		MonitorDurationInSeconds: jsii.Number(123),
	},
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentconfig.html

type CfnDeploymentConfig_MinimumHealthyHostsPerZoneProperty added in v2.115.0

type CfnDeploymentConfig_MinimumHealthyHostsPerZoneProperty struct {
	// The `type` associated with the `MinimumHealthyHostsPerZone` option.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentconfig-minimumhealthyhostsperzone.html#cfn-codedeploy-deploymentconfig-minimumhealthyhostsperzone-type
	//
	Type *string `field:"required" json:"type" yaml:"type"`
	// The `value` associated with the `MinimumHealthyHostsPerZone` option.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentconfig-minimumhealthyhostsperzone.html#cfn-codedeploy-deploymentconfig-minimumhealthyhostsperzone-value
	//
	Value *float64 `field:"required" json:"value" yaml:"value"`
}

Information about the minimum number of healthy instances per Availability Zone.

Example:

// 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"

minimumHealthyHostsPerZoneProperty := &MinimumHealthyHostsPerZoneProperty{
	Type: jsii.String("type"),
	Value: jsii.Number(123),
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentconfig-minimumhealthyhostsperzone.html

type CfnDeploymentConfig_MinimumHealthyHostsProperty

type CfnDeploymentConfig_MinimumHealthyHostsProperty struct {
	// The minimum healthy instance type:.
	//
	// - HOST_COUNT: The minimum number of healthy instance as an absolute value.
	// - FLEET_PERCENT: The minimum number of healthy instance as a percentage of the total number of instance in the deployment.
	//
	// In an example of nine instance, if a HOST_COUNT of six is specified, deploy to up to three instances at a time. The deployment is successful if six or more instances are deployed to successfully. Otherwise, the deployment fails. If a FLEET_PERCENT of 40 is specified, deploy to up to five instance at a time. The deployment is successful if four or more instance are deployed to successfully. Otherwise, the deployment fails.
	//
	// > In a call to `GetDeploymentConfig` , CodeDeployDefault.OneAtATime returns a minimum healthy instance type of MOST_CONCURRENCY and a value of 1. This means a deployment to only one instance at a time. (You cannot set the type to MOST_CONCURRENCY, only to HOST_COUNT or FLEET_PERCENT.) In addition, with CodeDeployDefault.OneAtATime, AWS CodeDeploy attempts to ensure that all instances but one are kept in a healthy state during the deployment. Although this allows one instance at a time to be taken offline for a new deployment, it also means that if the deployment to the last instance fails, the overall deployment is still successful.
	//
	// For more information, see [AWS CodeDeploy Instance Health](https://docs.aws.amazon.com//codedeploy/latest/userguide/instances-health.html) in the *AWS CodeDeploy User Guide* .
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentconfig-minimumhealthyhosts.html#cfn-codedeploy-deploymentconfig-minimumhealthyhosts-type
	//
	Type *string `field:"required" json:"type" yaml:"type"`
	// The minimum healthy instance value.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentconfig-minimumhealthyhosts.html#cfn-codedeploy-deploymentconfig-minimumhealthyhosts-value
	//
	Value *float64 `field:"required" json:"value" yaml:"value"`
}

`MinimumHealthyHosts` is a property of the [DeploymentConfig](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentconfig.html) resource that defines how many instances must remain healthy during an AWS CodeDeploy deployment.

Example:

// 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"

minimumHealthyHostsProperty := &MinimumHealthyHostsProperty{
	Type: jsii.String("type"),
	Value: jsii.Number(123),
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentconfig-minimumhealthyhosts.html

type CfnDeploymentConfig_TimeBasedCanaryProperty

type CfnDeploymentConfig_TimeBasedCanaryProperty struct {
	// The number of minutes between the first and second traffic shifts of a `TimeBasedCanary` deployment.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentconfig-timebasedcanary.html#cfn-codedeploy-deploymentconfig-timebasedcanary-canaryinterval
	//
	CanaryInterval *float64 `field:"required" json:"canaryInterval" yaml:"canaryInterval"`
	// The percentage of traffic to shift in the first increment of a `TimeBasedCanary` deployment.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentconfig-timebasedcanary.html#cfn-codedeploy-deploymentconfig-timebasedcanary-canarypercentage
	//
	CanaryPercentage *float64 `field:"required" json:"canaryPercentage" yaml:"canaryPercentage"`
}

A configuration that shifts traffic from one version of a Lambda function or Amazon ECS task set to another in two increments.

The original and target Lambda function versions or ECS task sets are specified in the deployment's AppSpec file.

Example:

// 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"

timeBasedCanaryProperty := &TimeBasedCanaryProperty{
	CanaryInterval: jsii.Number(123),
	CanaryPercentage: jsii.Number(123),
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentconfig-timebasedcanary.html

type CfnDeploymentConfig_TimeBasedLinearProperty

type CfnDeploymentConfig_TimeBasedLinearProperty struct {
	// The number of minutes between each incremental traffic shift of a `TimeBasedLinear` deployment.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentconfig-timebasedlinear.html#cfn-codedeploy-deploymentconfig-timebasedlinear-linearinterval
	//
	LinearInterval *float64 `field:"required" json:"linearInterval" yaml:"linearInterval"`
	// The percentage of traffic that is shifted at the start of each increment of a `TimeBasedLinear` deployment.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentconfig-timebasedlinear.html#cfn-codedeploy-deploymentconfig-timebasedlinear-linearpercentage
	//
	LinearPercentage *float64 `field:"required" json:"linearPercentage" yaml:"linearPercentage"`
}

A configuration that shifts traffic from one version of a Lambda function or ECS task set to another in equal increments, with an equal number of minutes between each increment.

The original and target Lambda function versions or ECS task sets are specified in the deployment's AppSpec file.

Example:

// 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"

timeBasedLinearProperty := &TimeBasedLinearProperty{
	LinearInterval: jsii.Number(123),
	LinearPercentage: jsii.Number(123),
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentconfig-timebasedlinear.html

type CfnDeploymentConfig_TrafficRoutingConfigProperty

type CfnDeploymentConfig_TrafficRoutingConfigProperty struct {
	// The type of traffic shifting ( `TimeBasedCanary` or `TimeBasedLinear` ) used by a deployment configuration.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentconfig-trafficroutingconfig.html#cfn-codedeploy-deploymentconfig-trafficroutingconfig-type
	//
	Type *string `field:"required" json:"type" yaml:"type"`
	// A configuration that shifts traffic from one version of a Lambda function or ECS task set to another in two increments.
	//
	// The original and target Lambda function versions or ECS task sets are specified in the deployment's AppSpec file.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentconfig-trafficroutingconfig.html#cfn-codedeploy-deploymentconfig-trafficroutingconfig-timebasedcanary
	//
	TimeBasedCanary interface{} `field:"optional" json:"timeBasedCanary" yaml:"timeBasedCanary"`
	// A configuration that shifts traffic from one version of a Lambda function or Amazon ECS task set to another in equal increments, with an equal number of minutes between each increment.
	//
	// The original and target Lambda function versions or Amazon ECS task sets are specified in the deployment's AppSpec file.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentconfig-trafficroutingconfig.html#cfn-codedeploy-deploymentconfig-trafficroutingconfig-timebasedlinear
	//
	TimeBasedLinear interface{} `field:"optional" json:"timeBasedLinear" yaml:"timeBasedLinear"`
}

The configuration that specifies how traffic is shifted from one version of a Lambda function to another version during an AWS Lambda deployment, or from one Amazon ECS task set to another during an Amazon ECS deployment.

Example:

// 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"

trafficRoutingConfigProperty := &TrafficRoutingConfigProperty{
	Type: jsii.String("type"),

	// the properties below are optional
	TimeBasedCanary: &TimeBasedCanaryProperty{
		CanaryInterval: jsii.Number(123),
		CanaryPercentage: jsii.Number(123),
	},
	TimeBasedLinear: &TimeBasedLinearProperty{
		LinearInterval: jsii.Number(123),
		LinearPercentage: jsii.Number(123),
	},
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentconfig-trafficroutingconfig.html

type CfnDeploymentConfig_ZonalConfigProperty added in v2.115.0

type CfnDeploymentConfig_ZonalConfigProperty struct {
	// The period of time, in seconds, that CodeDeploy must wait after completing a deployment to the *first* Availability Zone.
	//
	// CodeDeploy will wait this amount of time before starting a deployment to the second Availability Zone. You might set this option if you want to allow extra bake time for the first Availability Zone. If you don't specify a value for `firstZoneMonitorDurationInSeconds` , then CodeDeploy uses the `monitorDurationInSeconds` value for the first Availability Zone.
	//
	// For more information about the zonal configuration feature, see [zonal configuration](https://docs.aws.amazon.com/codedeploy/latest/userguide/deployment-configurations-create.html#zonal-config) in the *CodeDeploy User Guide* .
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentconfig-zonalconfig.html#cfn-codedeploy-deploymentconfig-zonalconfig-firstzonemonitordurationinseconds
	//
	FirstZoneMonitorDurationInSeconds *float64 `field:"optional" json:"firstZoneMonitorDurationInSeconds" yaml:"firstZoneMonitorDurationInSeconds"`
	// The number or percentage of instances that must remain available per Availability Zone during a deployment.
	//
	// This option works in conjunction with the `MinimumHealthyHosts` option. For more information, see [About the minimum number of healthy hosts per Availability Zone](https://docs.aws.amazon.com//codedeploy/latest/userguide/instances-health.html#minimum-healthy-hosts-az) in the *CodeDeploy User Guide* .
	//
	// If you don't specify the `minimumHealthyHostsPerZone` option, then CodeDeploy uses a default value of `0` percent.
	//
	// For more information about the zonal configuration feature, see [zonal configuration](https://docs.aws.amazon.com/codedeploy/latest/userguide/deployment-configurations-create.html#zonal-config) in the *CodeDeploy User Guide* .
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentconfig-zonalconfig.html#cfn-codedeploy-deploymentconfig-zonalconfig-minimumhealthyhostsperzone
	//
	MinimumHealthyHostsPerZone interface{} `field:"optional" json:"minimumHealthyHostsPerZone" yaml:"minimumHealthyHostsPerZone"`
	// The period of time, in seconds, that CodeDeploy must wait after completing a deployment to an Availability Zone.
	//
	// CodeDeploy will wait this amount of time before starting a deployment to the next Availability Zone. Consider adding a monitor duration to give the deployment some time to prove itself (or 'bake') in one Availability Zone before it is released in the next zone. If you don't specify a `monitorDurationInSeconds` , CodeDeploy starts deploying to the next Availability Zone immediately.
	//
	// For more information about the zonal configuration feature, see [zonal configuration](https://docs.aws.amazon.com/codedeploy/latest/userguide/deployment-configurations-create.html#zonal-config) in the *CodeDeploy User Guide* .
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentconfig-zonalconfig.html#cfn-codedeploy-deploymentconfig-zonalconfig-monitordurationinseconds
	//
	MonitorDurationInSeconds *float64 `field:"optional" json:"monitorDurationInSeconds" yaml:"monitorDurationInSeconds"`
}

Configure the `ZonalConfig` object if you want AWS CodeDeploy to deploy your application to one [Availability Zone](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-regions-availability-zones.html#concepts-availability-zones) at a time, within an AWS Region. By deploying to one Availability Zone at a time, you can expose your deployment to a progressively larger audience as confidence in the deployment's performance and viability grows. If you don't configure the `ZonalConfig` object, CodeDeploy deploys your application to a random selection of hosts across a Region.

For more information about the zonal configuration feature, see [zonal configuration](https://docs.aws.amazon.com/codedeploy/latest/userguide/deployment-configurations-create.html#zonal-config) in the *CodeDeploy User Guide* .

Example:

// 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"

zonalConfigProperty := &ZonalConfigProperty{
	FirstZoneMonitorDurationInSeconds: jsii.Number(123),
	MinimumHealthyHostsPerZone: &MinimumHealthyHostsPerZoneProperty{
		Type: jsii.String("type"),
		Value: jsii.Number(123),
	},
	MonitorDurationInSeconds: jsii.Number(123),
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentconfig-zonalconfig.html

type CfnDeploymentGroup

type CfnDeploymentGroup interface {
	awscdk.CfnResource
	awscdk.IInspectable
	awscdk.ITaggable
	// Information about the Amazon CloudWatch alarms that are associated with the deployment group.
	AlarmConfiguration() interface{}
	SetAlarmConfiguration(val interface{})
	// The name of an existing CodeDeploy application to associate this deployment group with.
	ApplicationName() *string
	SetApplicationName(val *string)
	AttrId() *string
	// Information about the automatic rollback configuration that is associated with the deployment group.
	AutoRollbackConfiguration() interface{}
	SetAutoRollbackConfiguration(val interface{})
	// A list of associated Auto Scaling groups that CodeDeploy automatically deploys revisions to when new instances are created.
	AutoScalingGroups() *[]*string
	SetAutoScalingGroups(val *[]*string)
	// Information about blue/green deployment options for a deployment group.
	BlueGreenDeploymentConfiguration() interface{}
	SetBlueGreenDeploymentConfiguration(val interface{})
	// Options for this resource, such as condition, update policy etc.
	CfnOptions() awscdk.ICfnResourceOptions
	CfnProperties() *map[string]interface{}
	// AWS resource type.
	CfnResourceType() *string
	// Returns: the stack trace of the point where this Resource was created from, sourced
	// from the +metadata+ entry typed +aws:cdk:logicalId+, and with the bottom-most
	// node +internal+ entries filtered.
	CreationStack() *[]*string
	// The application revision to deploy to this deployment group.
	Deployment() interface{}
	SetDeployment(val interface{})
	// A deployment configuration name or a predefined configuration name.
	DeploymentConfigName() *string
	SetDeploymentConfigName(val *string)
	// A name for the deployment group.
	DeploymentGroupName() *string
	SetDeploymentGroupName(val *string)
	// Attributes that determine the type of deployment to run and whether to route deployment traffic behind a load balancer.
	DeploymentStyle() interface{}
	SetDeploymentStyle(val interface{})
	// The Amazon EC2 tags that are already applied to Amazon EC2 instances that you want to include in the deployment group.
	Ec2TagFilters() interface{}
	SetEc2TagFilters(val interface{})
	// Information about groups of tags applied to Amazon EC2 instances.
	Ec2TagSet() interface{}
	SetEc2TagSet(val interface{})
	// The target Amazon ECS services in the deployment group.
	EcsServices() interface{}
	SetEcsServices(val interface{})
	// Information about the load balancer to use in a deployment.
	LoadBalancerInfo() interface{}
	SetLoadBalancerInfo(val interface{})
	// The logical ID for this CloudFormation stack element.
	//
	// The logical ID of the element
	// is calculated from the path of the resource node in the construct tree.
	//
	// To override this value, use `overrideLogicalId(newLogicalId)`.
	//
	// Returns: the logical ID as a stringified token. This value will only get
	// resolved during synthesis.
	LogicalId() *string
	// The tree node.
	Node() constructs.Node
	// The on-premises instance tags already applied to on-premises instances that you want to include in the deployment group.
	OnPremisesInstanceTagFilters() interface{}
	SetOnPremisesInstanceTagFilters(val interface{})
	// Information about groups of tags applied to on-premises instances.
	OnPremisesTagSet() interface{}
	SetOnPremisesTagSet(val interface{})
	// Indicates what happens when new Amazon EC2 instances are launched mid-deployment and do not receive the deployed application revision.
	OutdatedInstancesStrategy() *string
	SetOutdatedInstancesStrategy(val *string)
	// Return a string that will be resolved to a CloudFormation `{ Ref }` for this element.
	//
	// If, by any chance, the intrinsic reference of a resource is not a string, you could
	// coerce it to an IResolvable through `Lazy.any({ produce: resource.ref })`.
	Ref() *string
	// A service role Amazon Resource Name (ARN) that grants CodeDeploy permission to make calls to AWS services on your behalf.
	ServiceRoleArn() *string
	SetServiceRoleArn(val *string)
	// The stack in which this element is defined.
	//
	// CfnElements must be defined within a stack scope (directly or indirectly).
	Stack() awscdk.Stack
	// Tag Manager which manages the tags for this resource.
	Tags() awscdk.TagManager
	// The metadata that you apply to CodeDeploy deployment groups to help you organize and categorize them.
	TagsRaw() *[]*awscdk.CfnTag
	SetTagsRaw(val *[]*awscdk.CfnTag)
	// Indicates whether the deployment group was configured to have CodeDeploy install a termination hook into an Auto Scaling group.
	TerminationHookEnabled() interface{}
	SetTerminationHookEnabled(val interface{})
	// Information about triggers associated with the deployment group.
	TriggerConfigurations() interface{}
	SetTriggerConfigurations(val interface{})
	// Deprecated.
	// Deprecated: use `updatedProperties`
	//
	// Return properties modified after initiation
	//
	// Resources that expose mutable properties should override this function to
	// collect and return the properties object for this resource.
	UpdatedProperites() *map[string]interface{}
	// Return properties modified after initiation.
	//
	// Resources that expose mutable properties should override this function to
	// collect and return the properties object for this resource.
	UpdatedProperties() *map[string]interface{}
	// Syntactic sugar for `addOverride(path, undefined)`.
	AddDeletionOverride(path *string)
	// Indicates that this resource depends on another resource and cannot be provisioned unless the other resource has been successfully provisioned.
	//
	// This can be used for resources across stacks (or nested stack) boundaries
	// and the dependency will automatically be transferred to the relevant scope.
	AddDependency(target awscdk.CfnResource)
	// Indicates that this resource depends on another resource and cannot be provisioned unless the other resource has been successfully provisioned.
	// Deprecated: use addDependency.
	AddDependsOn(target awscdk.CfnResource)
	// Add a value to the CloudFormation Resource Metadata.
	// See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/metadata-section-structure.html
	//
	// Note that this is a different set of metadata from CDK node metadata; this
	// metadata ends up in the stack template under the resource, whereas CDK
	// node metadata ends up in the Cloud Assembly.
	//
	AddMetadata(key *string, value interface{})
	// Adds an override to the synthesized CloudFormation resource.
	//
	// To add a
	// property override, either use `addPropertyOverride` or prefix `path` with
	// "Properties." (i.e. `Properties.TopicName`).
	//
	// If the override is nested, separate each nested level using a dot (.) in the path parameter.
	// If there is an array as part of the nesting, specify the index in the path.
	//
	// To include a literal `.` in the property name, prefix with a `\`. In most
	// programming languages you will need to write this as `"\\."` because the
	// `\` itself will need to be escaped.
	//
	// For example,
	// “`typescript
	// cfnResource.addOverride('Properties.GlobalSecondaryIndexes.0.Projection.NonKeyAttributes', ['myattribute']);
	// cfnResource.addOverride('Properties.GlobalSecondaryIndexes.1.ProjectionType', 'INCLUDE');
	// “`
	// would add the overrides
	// “`json
	// "Properties": {
	//   "GlobalSecondaryIndexes": [
	//     {
	//       "Projection": {
	//         "NonKeyAttributes": [ "myattribute" ]
	//         ...
	//       }
	//       ...
	//     },
	//     {
	//       "ProjectionType": "INCLUDE"
	//       ...
	//     },
	//   ]
	//   ...
	// }
	// “`
	//
	// The `value` argument to `addOverride` will not be processed or translated
	// in any way. Pass raw JSON values in here with the correct capitalization
	// for CloudFormation. If you pass CDK classes or structs, they will be
	// rendered with lowercased key names, and CloudFormation will reject the
	// template.
	AddOverride(path *string, value interface{})
	// Adds an override that deletes the value of a property from the resource definition.
	AddPropertyDeletionOverride(propertyPath *string)
	// Adds an override to a resource property.
	//
	// Syntactic sugar for `addOverride("Properties.<...>", value)`.
	AddPropertyOverride(propertyPath *string, value interface{})
	// Sets the deletion policy of the resource based on the removal policy specified.
	//
	// The Removal Policy controls what happens to this resource when it stops
	// being managed by CloudFormation, either because you've removed it from the
	// CDK application or because you've made a change that requires the resource
	// to be replaced.
	//
	// The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS
	// account for data recovery and cleanup later (`RemovalPolicy.RETAIN`). In some
	// cases, a snapshot can be taken of the resource prior to deletion
	// (`RemovalPolicy.SNAPSHOT`). A list of resources that support this policy
	// can be found in the following link:.
	// See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-attribute-deletionpolicy.html#aws-attribute-deletionpolicy-options
	//
	ApplyRemovalPolicy(policy awscdk.RemovalPolicy, options *awscdk.RemovalPolicyOptions)
	// Returns a token for an runtime attribute of this resource.
	//
	// Ideally, use generated attribute accessors (e.g. `resource.arn`), but this can be used for future compatibility
	// in case there is no generated attribute.
	GetAtt(attributeName *string, typeHint awscdk.ResolutionTypeHint) awscdk.Reference
	// Retrieve a value value from the CloudFormation Resource Metadata.
	// See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/metadata-section-structure.html
	//
	// Note that this is a different set of metadata from CDK node metadata; this
	// metadata ends up in the stack template under the resource, whereas CDK
	// node metadata ends up in the Cloud Assembly.
	//
	GetMetadata(key *string) interface{}
	// Examines the CloudFormation resource and discloses attributes.
	Inspect(inspector awscdk.TreeInspector)
	// Retrieves an array of resources this resource depends on.
	//
	// This assembles dependencies on resources across stacks (including nested stacks)
	// automatically.
	ObtainDependencies() *[]interface{}
	// Get a shallow copy of dependencies between this resource and other resources in the same stack.
	ObtainResourceDependencies() *[]awscdk.CfnResource
	// Overrides the auto-generated logical ID with a specific ID.
	OverrideLogicalId(newLogicalId *string)
	// Indicates that this resource no longer depends on another resource.
	//
	// This can be used for resources across stacks (including nested stacks)
	// and the dependency will automatically be removed from the relevant scope.
	RemoveDependency(target awscdk.CfnResource)
	RenderProperties(props *map[string]interface{}) *map[string]interface{}
	// Replaces one dependency with another.
	ReplaceDependency(target awscdk.CfnResource, newTarget awscdk.CfnResource)
	// Can be overridden by subclasses to determine if this resource will be rendered into the cloudformation template.
	//
	// Returns: `true` if the resource should be included or `false` is the resource
	// should be omitted.
	ShouldSynthesize() *bool
	// Returns a string representation of this construct.
	//
	// Returns: a string representation of this resource.
	ToString() *string
	ValidateProperties(_properties interface{})
}

The `AWS::CodeDeploy::DeploymentGroup` resource creates an AWS CodeDeploy deployment group that specifies which instances your application revisions are deployed to, along with other deployment options.

For more information, see [CreateDeploymentGroup](https://docs.aws.amazon.com/codedeploy/latest/APIReference/API_CreateDeploymentGroup.html) in the *CodeDeploy API Reference* .

> Amazon ECS blue/green deployments through CodeDeploy do not use the `AWS::CodeDeploy::DeploymentGroup` resource. To perform Amazon ECS blue/green deployments, use the `AWS::CodeDeploy::BlueGreen` hook. See [Perform Amazon ECS blue/green deployments through CodeDeploy using AWS CloudFormation](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/blue-green.html) for more information.

Example:

// 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"

cfnDeploymentGroup := awscdk.Aws_codedeploy.NewCfnDeploymentGroup(this, jsii.String("MyCfnDeploymentGroup"), &CfnDeploymentGroupProps{
	ApplicationName: jsii.String("applicationName"),
	ServiceRoleArn: jsii.String("serviceRoleArn"),

	// the properties below are optional
	AlarmConfiguration: &AlarmConfigurationProperty{
		Alarms: []interface{}{
			&AlarmProperty{
				Name: jsii.String("name"),
			},
		},
		Enabled: jsii.Boolean(false),
		IgnorePollAlarmFailure: jsii.Boolean(false),
	},
	AutoRollbackConfiguration: &AutoRollbackConfigurationProperty{
		Enabled: jsii.Boolean(false),
		Events: []*string{
			jsii.String("events"),
		},
	},
	AutoScalingGroups: []*string{
		jsii.String("autoScalingGroups"),
	},
	BlueGreenDeploymentConfiguration: &BlueGreenDeploymentConfigurationProperty{
		DeploymentReadyOption: &DeploymentReadyOptionProperty{
			ActionOnTimeout: jsii.String("actionOnTimeout"),
			WaitTimeInMinutes: jsii.Number(123),
		},
		GreenFleetProvisioningOption: &GreenFleetProvisioningOptionProperty{
			Action: jsii.String("action"),
		},
		TerminateBlueInstancesOnDeploymentSuccess: &BlueInstanceTerminationOptionProperty{
			Action: jsii.String("action"),
			TerminationWaitTimeInMinutes: jsii.Number(123),
		},
	},
	Deployment: &DeploymentProperty{
		Revision: &RevisionLocationProperty{
			GitHubLocation: &GitHubLocationProperty{
				CommitId: jsii.String("commitId"),
				Repository: jsii.String("repository"),
			},
			RevisionType: jsii.String("revisionType"),
			S3Location: &S3LocationProperty{
				Bucket: jsii.String("bucket"),
				Key: jsii.String("key"),

				// the properties below are optional
				BundleType: jsii.String("bundleType"),
				ETag: jsii.String("eTag"),
				Version: jsii.String("version"),
			},
		},

		// the properties below are optional
		Description: jsii.String("description"),
		IgnoreApplicationStopFailures: jsii.Boolean(false),
	},
	DeploymentConfigName: jsii.String("deploymentConfigName"),
	DeploymentGroupName: jsii.String("deploymentGroupName"),
	DeploymentStyle: &DeploymentStyleProperty{
		DeploymentOption: jsii.String("deploymentOption"),
		DeploymentType: jsii.String("deploymentType"),
	},
	Ec2TagFilters: []interface{}{
		&EC2TagFilterProperty{
			Key: jsii.String("key"),
			Type: jsii.String("type"),
			Value: jsii.String("value"),
		},
	},
	Ec2TagSet: &EC2TagSetProperty{
		Ec2TagSetList: []interface{}{
			&EC2TagSetListObjectProperty{
				Ec2TagGroup: []interface{}{
					&EC2TagFilterProperty{
						Key: jsii.String("key"),
						Type: jsii.String("type"),
						Value: jsii.String("value"),
					},
				},
			},
		},
	},
	EcsServices: []interface{}{
		&ECSServiceProperty{
			ClusterName: jsii.String("clusterName"),
			ServiceName: jsii.String("serviceName"),
		},
	},
	LoadBalancerInfo: &LoadBalancerInfoProperty{
		ElbInfoList: []interface{}{
			&ELBInfoProperty{
				Name: jsii.String("name"),
			},
		},
		TargetGroupInfoList: []interface{}{
			&TargetGroupInfoProperty{
				Name: jsii.String("name"),
			},
		},
		TargetGroupPairInfoList: []interface{}{
			&TargetGroupPairInfoProperty{
				ProdTrafficRoute: &TrafficRouteProperty{
					ListenerArns: []*string{
						jsii.String("listenerArns"),
					},
				},
				TargetGroups: []interface{}{
					&TargetGroupInfoProperty{
						Name: jsii.String("name"),
					},
				},
				TestTrafficRoute: &TrafficRouteProperty{
					ListenerArns: []*string{
						jsii.String("listenerArns"),
					},
				},
			},
		},
	},
	OnPremisesInstanceTagFilters: []interface{}{
		&TagFilterProperty{
			Key: jsii.String("key"),
			Type: jsii.String("type"),
			Value: jsii.String("value"),
		},
	},
	OnPremisesTagSet: &OnPremisesTagSetProperty{
		OnPremisesTagSetList: []interface{}{
			&OnPremisesTagSetListObjectProperty{
				OnPremisesTagGroup: []interface{}{
					&TagFilterProperty{
						Key: jsii.String("key"),
						Type: jsii.String("type"),
						Value: jsii.String("value"),
					},
				},
			},
		},
	},
	OutdatedInstancesStrategy: jsii.String("outdatedInstancesStrategy"),
	Tags: []cfnTag{
		&cfnTag{
			Key: jsii.String("key"),
			Value: jsii.String("value"),
		},
	},
	TerminationHookEnabled: jsii.Boolean(false),
	TriggerConfigurations: []interface{}{
		&TriggerConfigProperty{
			TriggerEvents: []*string{
				jsii.String("triggerEvents"),
			},
			TriggerName: jsii.String("triggerName"),
			TriggerTargetArn: jsii.String("triggerTargetArn"),
		},
	},
})

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html

func NewCfnDeploymentGroup

func NewCfnDeploymentGroup(scope constructs.Construct, id *string, props *CfnDeploymentGroupProps) CfnDeploymentGroup

type CfnDeploymentGroupProps

type CfnDeploymentGroupProps struct {
	// The name of an existing CodeDeploy application to associate this deployment group with.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html#cfn-codedeploy-deploymentgroup-applicationname
	//
	ApplicationName *string `field:"required" json:"applicationName" yaml:"applicationName"`
	// A service role Amazon Resource Name (ARN) that grants CodeDeploy permission to make calls to AWS services on your behalf.
	//
	// For more information, see [Create a Service Role for AWS CodeDeploy](https://docs.aws.amazon.com/codedeploy/latest/userguide/getting-started-create-service-role.html) in the *AWS CodeDeploy User Guide* .
	//
	// > In some cases, you might need to add a dependency on the service role's policy. For more information, see IAM role policy in [DependsOn Attribute](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-attribute-dependson.html) .
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html#cfn-codedeploy-deploymentgroup-servicerolearn
	//
	ServiceRoleArn *string `field:"required" json:"serviceRoleArn" yaml:"serviceRoleArn"`
	// Information about the Amazon CloudWatch alarms that are associated with the deployment group.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html#cfn-codedeploy-deploymentgroup-alarmconfiguration
	//
	AlarmConfiguration interface{} `field:"optional" json:"alarmConfiguration" yaml:"alarmConfiguration"`
	// Information about the automatic rollback configuration that is associated with the deployment group.
	//
	// If you specify this property, don't specify the `Deployment` property.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html#cfn-codedeploy-deploymentgroup-autorollbackconfiguration
	//
	AutoRollbackConfiguration interface{} `field:"optional" json:"autoRollbackConfiguration" yaml:"autoRollbackConfiguration"`
	// A list of associated Auto Scaling groups that CodeDeploy automatically deploys revisions to when new instances are created.
	//
	// Duplicates are not allowed.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html#cfn-codedeploy-deploymentgroup-autoscalinggroups
	//
	AutoScalingGroups *[]*string `field:"optional" json:"autoScalingGroups" yaml:"autoScalingGroups"`
	// Information about blue/green deployment options for a deployment group.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html#cfn-codedeploy-deploymentgroup-bluegreendeploymentconfiguration
	//
	BlueGreenDeploymentConfiguration interface{} `field:"optional" json:"blueGreenDeploymentConfiguration" yaml:"blueGreenDeploymentConfiguration"`
	// The application revision to deploy to this deployment group.
	//
	// If you specify this property, your target application revision is deployed as soon as the provisioning process is complete. If you specify this property, don't specify the `AutoRollbackConfiguration` property.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html#cfn-codedeploy-deploymentgroup-deployment
	//
	Deployment interface{} `field:"optional" json:"deployment" yaml:"deployment"`
	// A deployment configuration name or a predefined configuration name.
	//
	// With predefined configurations, you can deploy application revisions to one instance at a time ( `CodeDeployDefault.OneAtATime` ), half of the instances at a time ( `CodeDeployDefault.HalfAtATime` ), or all the instances at once ( `CodeDeployDefault.AllAtOnce` ). For more information and valid values, see [Working with Deployment Configurations](https://docs.aws.amazon.com/codedeploy/latest/userguide/deployment-configurations.html) in the *AWS CodeDeploy User Guide* .
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html#cfn-codedeploy-deploymentgroup-deploymentconfigname
	//
	DeploymentConfigName *string `field:"optional" json:"deploymentConfigName" yaml:"deploymentConfigName"`
	// A name for the deployment group.
	//
	// If you don't specify a name, AWS CloudFormation generates a unique physical ID and uses that ID for the deployment group name. For more information, see [Name Type](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-name.html) .
	//
	// > If you specify a name, you cannot perform updates that require replacement of this resource. You can perform updates that require no or some interruption. If you must replace the resource, specify a new name.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html#cfn-codedeploy-deploymentgroup-deploymentgroupname
	//
	DeploymentGroupName *string `field:"optional" json:"deploymentGroupName" yaml:"deploymentGroupName"`
	// Attributes that determine the type of deployment to run and whether to route deployment traffic behind a load balancer.
	//
	// If you specify this property with a blue/green deployment type, don't specify the `AutoScalingGroups` , `LoadBalancerInfo` , or `Deployment` properties.
	//
	// > For blue/green deployments, AWS CloudFormation supports deployments on Lambda compute platforms only. You can perform Amazon ECS blue/green deployments using `AWS::CodeDeploy::BlueGreen` hook. See [Perform Amazon ECS blue/green deployments through CodeDeploy using AWS CloudFormation](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/blue-green.html) for more information.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html#cfn-codedeploy-deploymentgroup-deploymentstyle
	//
	DeploymentStyle interface{} `field:"optional" json:"deploymentStyle" yaml:"deploymentStyle"`
	// The Amazon EC2 tags that are already applied to Amazon EC2 instances that you want to include in the deployment group.
	//
	// CodeDeploy includes all Amazon EC2 instances identified by any of the tags you specify in this deployment group. Duplicates are not allowed.
	//
	// You can specify `EC2TagFilters` or `Ec2TagSet` , but not both.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html#cfn-codedeploy-deploymentgroup-ec2tagfilters
	//
	Ec2TagFilters interface{} `field:"optional" json:"ec2TagFilters" yaml:"ec2TagFilters"`
	// Information about groups of tags applied to Amazon EC2 instances.
	//
	// The deployment group includes only Amazon EC2 instances identified by all the tag groups. Cannot be used in the same call as `ec2TagFilter` .
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html#cfn-codedeploy-deploymentgroup-ec2tagset
	//
	Ec2TagSet interface{} `field:"optional" json:"ec2TagSet" yaml:"ec2TagSet"`
	// The target Amazon ECS services in the deployment group.
	//
	// This applies only to deployment groups that use the Amazon ECS compute platform. A target Amazon ECS service is specified as an Amazon ECS cluster and service name pair using the format `<clustername>:<servicename>` .
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html#cfn-codedeploy-deploymentgroup-ecsservices
	//
	EcsServices interface{} `field:"optional" json:"ecsServices" yaml:"ecsServices"`
	// Information about the load balancer to use in a deployment.
	//
	// For more information, see [Integrating CodeDeploy with Elastic Load Balancing](https://docs.aws.amazon.com/codedeploy/latest/userguide/integrations-aws-elastic-load-balancing.html) in the *AWS CodeDeploy User Guide* .
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html#cfn-codedeploy-deploymentgroup-loadbalancerinfo
	//
	LoadBalancerInfo interface{} `field:"optional" json:"loadBalancerInfo" yaml:"loadBalancerInfo"`
	// The on-premises instance tags already applied to on-premises instances that you want to include in the deployment group.
	//
	// CodeDeploy includes all on-premises instances identified by any of the tags you specify in this deployment group. To register on-premises instances with CodeDeploy , see [Working with On-Premises Instances for CodeDeploy](https://docs.aws.amazon.com/codedeploy/latest/userguide/instances-on-premises.html) in the *AWS CodeDeploy User Guide* . Duplicates are not allowed.
	//
	// You can specify `OnPremisesInstanceTagFilters` or `OnPremisesInstanceTagSet` , but not both.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html#cfn-codedeploy-deploymentgroup-onpremisesinstancetagfilters
	//
	OnPremisesInstanceTagFilters interface{} `field:"optional" json:"onPremisesInstanceTagFilters" yaml:"onPremisesInstanceTagFilters"`
	// Information about groups of tags applied to on-premises instances.
	//
	// The deployment group includes only on-premises instances identified by all the tag groups.
	//
	// You can specify `OnPremisesInstanceTagFilters` or `OnPremisesInstanceTagSet` , but not both.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html#cfn-codedeploy-deploymentgroup-onpremisestagset
	//
	OnPremisesTagSet interface{} `field:"optional" json:"onPremisesTagSet" yaml:"onPremisesTagSet"`
	// Indicates what happens when new Amazon EC2 instances are launched mid-deployment and do not receive the deployed application revision.
	//
	// If this option is set to `UPDATE` or is unspecified, CodeDeploy initiates one or more 'auto-update outdated instances' deployments to apply the deployed application revision to the new Amazon EC2 instances.
	//
	// If this option is set to `IGNORE` , CodeDeploy does not initiate a deployment to update the new Amazon EC2 instances. This may result in instances having different revisions.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html#cfn-codedeploy-deploymentgroup-outdatedinstancesstrategy
	//
	OutdatedInstancesStrategy *string `field:"optional" json:"outdatedInstancesStrategy" yaml:"outdatedInstancesStrategy"`
	// The metadata that you apply to CodeDeploy deployment groups to help you organize and categorize them.
	//
	// Each tag consists of a key and an optional value, both of which you define.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html#cfn-codedeploy-deploymentgroup-tags
	//
	Tags *[]*awscdk.CfnTag `field:"optional" json:"tags" yaml:"tags"`
	// Indicates whether the deployment group was configured to have CodeDeploy install a termination hook into an Auto Scaling group.
	//
	// For more information about the termination hook, see [How Amazon EC2 Auto Scaling works with CodeDeploy](https://docs.aws.amazon.com//codedeploy/latest/userguide/integrations-aws-auto-scaling.html#integrations-aws-auto-scaling-behaviors) in the *AWS CodeDeploy User Guide* .
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html#cfn-codedeploy-deploymentgroup-terminationhookenabled
	//
	TerminationHookEnabled interface{} `field:"optional" json:"terminationHookEnabled" yaml:"terminationHookEnabled"`
	// Information about triggers associated with the deployment group.
	//
	// Duplicates are not allowed.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html#cfn-codedeploy-deploymentgroup-triggerconfigurations
	//
	TriggerConfigurations interface{} `field:"optional" json:"triggerConfigurations" yaml:"triggerConfigurations"`
}

Properties for defining a `CfnDeploymentGroup`.

Example:

// 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"

cfnDeploymentGroupProps := &CfnDeploymentGroupProps{
	ApplicationName: jsii.String("applicationName"),
	ServiceRoleArn: jsii.String("serviceRoleArn"),

	// the properties below are optional
	AlarmConfiguration: &AlarmConfigurationProperty{
		Alarms: []interface{}{
			&AlarmProperty{
				Name: jsii.String("name"),
			},
		},
		Enabled: jsii.Boolean(false),
		IgnorePollAlarmFailure: jsii.Boolean(false),
	},
	AutoRollbackConfiguration: &AutoRollbackConfigurationProperty{
		Enabled: jsii.Boolean(false),
		Events: []*string{
			jsii.String("events"),
		},
	},
	AutoScalingGroups: []*string{
		jsii.String("autoScalingGroups"),
	},
	BlueGreenDeploymentConfiguration: &BlueGreenDeploymentConfigurationProperty{
		DeploymentReadyOption: &DeploymentReadyOptionProperty{
			ActionOnTimeout: jsii.String("actionOnTimeout"),
			WaitTimeInMinutes: jsii.Number(123),
		},
		GreenFleetProvisioningOption: &GreenFleetProvisioningOptionProperty{
			Action: jsii.String("action"),
		},
		TerminateBlueInstancesOnDeploymentSuccess: &BlueInstanceTerminationOptionProperty{
			Action: jsii.String("action"),
			TerminationWaitTimeInMinutes: jsii.Number(123),
		},
	},
	Deployment: &DeploymentProperty{
		Revision: &RevisionLocationProperty{
			GitHubLocation: &GitHubLocationProperty{
				CommitId: jsii.String("commitId"),
				Repository: jsii.String("repository"),
			},
			RevisionType: jsii.String("revisionType"),
			S3Location: &S3LocationProperty{
				Bucket: jsii.String("bucket"),
				Key: jsii.String("key"),

				// the properties below are optional
				BundleType: jsii.String("bundleType"),
				ETag: jsii.String("eTag"),
				Version: jsii.String("version"),
			},
		},

		// the properties below are optional
		Description: jsii.String("description"),
		IgnoreApplicationStopFailures: jsii.Boolean(false),
	},
	DeploymentConfigName: jsii.String("deploymentConfigName"),
	DeploymentGroupName: jsii.String("deploymentGroupName"),
	DeploymentStyle: &DeploymentStyleProperty{
		DeploymentOption: jsii.String("deploymentOption"),
		DeploymentType: jsii.String("deploymentType"),
	},
	Ec2TagFilters: []interface{}{
		&EC2TagFilterProperty{
			Key: jsii.String("key"),
			Type: jsii.String("type"),
			Value: jsii.String("value"),
		},
	},
	Ec2TagSet: &EC2TagSetProperty{
		Ec2TagSetList: []interface{}{
			&EC2TagSetListObjectProperty{
				Ec2TagGroup: []interface{}{
					&EC2TagFilterProperty{
						Key: jsii.String("key"),
						Type: jsii.String("type"),
						Value: jsii.String("value"),
					},
				},
			},
		},
	},
	EcsServices: []interface{}{
		&ECSServiceProperty{
			ClusterName: jsii.String("clusterName"),
			ServiceName: jsii.String("serviceName"),
		},
	},
	LoadBalancerInfo: &LoadBalancerInfoProperty{
		ElbInfoList: []interface{}{
			&ELBInfoProperty{
				Name: jsii.String("name"),
			},
		},
		TargetGroupInfoList: []interface{}{
			&TargetGroupInfoProperty{
				Name: jsii.String("name"),
			},
		},
		TargetGroupPairInfoList: []interface{}{
			&TargetGroupPairInfoProperty{
				ProdTrafficRoute: &TrafficRouteProperty{
					ListenerArns: []*string{
						jsii.String("listenerArns"),
					},
				},
				TargetGroups: []interface{}{
					&TargetGroupInfoProperty{
						Name: jsii.String("name"),
					},
				},
				TestTrafficRoute: &TrafficRouteProperty{
					ListenerArns: []*string{
						jsii.String("listenerArns"),
					},
				},
			},
		},
	},
	OnPremisesInstanceTagFilters: []interface{}{
		&TagFilterProperty{
			Key: jsii.String("key"),
			Type: jsii.String("type"),
			Value: jsii.String("value"),
		},
	},
	OnPremisesTagSet: &OnPremisesTagSetProperty{
		OnPremisesTagSetList: []interface{}{
			&OnPremisesTagSetListObjectProperty{
				OnPremisesTagGroup: []interface{}{
					&TagFilterProperty{
						Key: jsii.String("key"),
						Type: jsii.String("type"),
						Value: jsii.String("value"),
					},
				},
			},
		},
	},
	OutdatedInstancesStrategy: jsii.String("outdatedInstancesStrategy"),
	Tags: []cfnTag{
		&cfnTag{
			Key: jsii.String("key"),
			Value: jsii.String("value"),
		},
	},
	TerminationHookEnabled: jsii.Boolean(false),
	TriggerConfigurations: []interface{}{
		&TriggerConfigProperty{
			TriggerEvents: []*string{
				jsii.String("triggerEvents"),
			},
			TriggerName: jsii.String("triggerName"),
			TriggerTargetArn: jsii.String("triggerTargetArn"),
		},
	},
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html

type CfnDeploymentGroup_AlarmConfigurationProperty

type CfnDeploymentGroup_AlarmConfigurationProperty struct {
	// A list of alarms configured for the deployment or deployment group.
	//
	// A maximum of 10 alarms can be added.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-alarmconfiguration.html#cfn-codedeploy-deploymentgroup-alarmconfiguration-alarms
	//
	Alarms interface{} `field:"optional" json:"alarms" yaml:"alarms"`
	// Indicates whether the alarm configuration is enabled.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-alarmconfiguration.html#cfn-codedeploy-deploymentgroup-alarmconfiguration-enabled
	//
	Enabled interface{} `field:"optional" json:"enabled" yaml:"enabled"`
	// Indicates whether a deployment should continue if information about the current state of alarms cannot be retrieved from Amazon CloudWatch .
	//
	// The default value is `false` .
	//
	// - `true` : The deployment proceeds even if alarm status information can't be retrieved from CloudWatch .
	// - `false` : The deployment stops if alarm status information can't be retrieved from CloudWatch .
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-alarmconfiguration.html#cfn-codedeploy-deploymentgroup-alarmconfiguration-ignorepollalarmfailure
	//
	IgnorePollAlarmFailure interface{} `field:"optional" json:"ignorePollAlarmFailure" yaml:"ignorePollAlarmFailure"`
}

The `AlarmConfiguration` property type configures CloudWatch alarms for an AWS CodeDeploy deployment group.

`AlarmConfiguration` is a property of the [DeploymentGroup](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html) resource.

Example:

// 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"

alarmConfigurationProperty := &AlarmConfigurationProperty{
	Alarms: []interface{}{
		&AlarmProperty{
			Name: jsii.String("name"),
		},
	},
	Enabled: jsii.Boolean(false),
	IgnorePollAlarmFailure: jsii.Boolean(false),
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-alarmconfiguration.html

type CfnDeploymentGroup_AlarmProperty

type CfnDeploymentGroup_AlarmProperty struct {
	// The name of the alarm.
	//
	// Maximum length is 255 characters. Each alarm name can be used only once in a list of alarms.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-alarm.html#cfn-codedeploy-deploymentgroup-alarm-name
	//
	Name *string `field:"optional" json:"name" yaml:"name"`
}

The `Alarm` property type specifies a CloudWatch alarm to use for an AWS CodeDeploy deployment group.

The `Alarm` property of the [CodeDeploy DeploymentGroup AlarmConfiguration](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-alarmconfiguration.html) property contains a list of `Alarm` property types.

Example:

// 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"

alarmProperty := &AlarmProperty{
	Name: jsii.String("name"),
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-alarm.html

type CfnDeploymentGroup_AutoRollbackConfigurationProperty

type CfnDeploymentGroup_AutoRollbackConfigurationProperty struct {
	// Indicates whether a defined automatic rollback configuration is currently enabled.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-autorollbackconfiguration.html#cfn-codedeploy-deploymentgroup-autorollbackconfiguration-enabled
	//
	Enabled interface{} `field:"optional" json:"enabled" yaml:"enabled"`
	// The event type or types that trigger a rollback.
	//
	// Valid values are `DEPLOYMENT_FAILURE` , `DEPLOYMENT_STOP_ON_ALARM` , or `DEPLOYMENT_STOP_ON_REQUEST` .
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-autorollbackconfiguration.html#cfn-codedeploy-deploymentgroup-autorollbackconfiguration-events
	//
	Events *[]*string `field:"optional" json:"events" yaml:"events"`
}

The `AutoRollbackConfiguration` property type configures automatic rollback for an AWS CodeDeploy deployment group when a deployment is not completed successfully.

For more information, see [Automatic Rollbacks](https://docs.aws.amazon.com/codedeploy/latest/userguide/deployments-rollback-and-redeploy.html#deployments-rollback-and-redeploy-automatic-rollbacks) in the *AWS CodeDeploy User Guide* .

`AutoRollbackConfiguration` is a property of the [DeploymentGroup](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html) resource.

Example:

// 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"

autoRollbackConfigurationProperty := &AutoRollbackConfigurationProperty{
	Enabled: jsii.Boolean(false),
	Events: []*string{
		jsii.String("events"),
	},
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-autorollbackconfiguration.html

type CfnDeploymentGroup_BlueGreenDeploymentConfigurationProperty

type CfnDeploymentGroup_BlueGreenDeploymentConfigurationProperty struct {
	// Information about the action to take when newly provisioned instances are ready to receive traffic in a blue/green deployment.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-bluegreendeploymentconfiguration.html#cfn-codedeploy-deploymentgroup-bluegreendeploymentconfiguration-deploymentreadyoption
	//
	DeploymentReadyOption interface{} `field:"optional" json:"deploymentReadyOption" yaml:"deploymentReadyOption"`
	// Information about how instances are provisioned for a replacement environment in a blue/green deployment.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-bluegreendeploymentconfiguration.html#cfn-codedeploy-deploymentgroup-bluegreendeploymentconfiguration-greenfleetprovisioningoption
	//
	GreenFleetProvisioningOption interface{} `field:"optional" json:"greenFleetProvisioningOption" yaml:"greenFleetProvisioningOption"`
	// Information about whether to terminate instances in the original fleet during a blue/green deployment.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-bluegreendeploymentconfiguration.html#cfn-codedeploy-deploymentgroup-bluegreendeploymentconfiguration-terminateblueinstancesondeploymentsuccess
	//
	TerminateBlueInstancesOnDeploymentSuccess interface{} `field:"optional" json:"terminateBlueInstancesOnDeploymentSuccess" yaml:"terminateBlueInstancesOnDeploymentSuccess"`
}

Information about blue/green deployment options for a deployment group.

Example:

// 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"

blueGreenDeploymentConfigurationProperty := &BlueGreenDeploymentConfigurationProperty{
	DeploymentReadyOption: &DeploymentReadyOptionProperty{
		ActionOnTimeout: jsii.String("actionOnTimeout"),
		WaitTimeInMinutes: jsii.Number(123),
	},
	GreenFleetProvisioningOption: &GreenFleetProvisioningOptionProperty{
		Action: jsii.String("action"),
	},
	TerminateBlueInstancesOnDeploymentSuccess: &BlueInstanceTerminationOptionProperty{
		Action: jsii.String("action"),
		TerminationWaitTimeInMinutes: jsii.Number(123),
	},
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-bluegreendeploymentconfiguration.html

type CfnDeploymentGroup_BlueInstanceTerminationOptionProperty

type CfnDeploymentGroup_BlueInstanceTerminationOptionProperty struct {
	// The action to take on instances in the original environment after a successful blue/green deployment.
	//
	// - `TERMINATE` : Instances are terminated after a specified wait time.
	// - `KEEP_ALIVE` : Instances are left running after they are deregistered from the load balancer and removed from the deployment group.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-blueinstanceterminationoption.html#cfn-codedeploy-deploymentgroup-blueinstanceterminationoption-action
	//
	Action *string `field:"optional" json:"action" yaml:"action"`
	// For an Amazon EC2 deployment, the number of minutes to wait after a successful blue/green deployment before terminating instances from the original environment.
	//
	// For an Amazon ECS deployment, the number of minutes before deleting the original (blue) task set. During an Amazon ECS deployment, CodeDeploy shifts traffic from the original (blue) task set to a replacement (green) task set.
	//
	// The maximum setting is 2880 minutes (2 days).
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-blueinstanceterminationoption.html#cfn-codedeploy-deploymentgroup-blueinstanceterminationoption-terminationwaittimeinminutes
	//
	TerminationWaitTimeInMinutes *float64 `field:"optional" json:"terminationWaitTimeInMinutes" yaml:"terminationWaitTimeInMinutes"`
}

Information about whether instances in the original environment are terminated when a blue/green deployment is successful.

`BlueInstanceTerminationOption` does not apply to Lambda deployments.

Example:

// 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"

blueInstanceTerminationOptionProperty := &BlueInstanceTerminationOptionProperty{
	Action: jsii.String("action"),
	TerminationWaitTimeInMinutes: jsii.Number(123),
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-blueinstanceterminationoption.html

type CfnDeploymentGroup_DeploymentProperty

type CfnDeploymentGroup_DeploymentProperty struct {
	// Information about the location of stored application artifacts and the service from which to retrieve them.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-deployment.html#cfn-codedeploy-deploymentgroup-deployment-revision
	//
	Revision interface{} `field:"required" json:"revision" yaml:"revision"`
	// A comment about the deployment.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-deployment.html#cfn-codedeploy-deploymentgroup-deployment-description
	//
	Description *string `field:"optional" json:"description" yaml:"description"`
	// If true, then if an `ApplicationStop` , `BeforeBlockTraffic` , or `AfterBlockTraffic` deployment lifecycle event to an instance fails, then the deployment continues to the next deployment lifecycle event.
	//
	// For example, if `ApplicationStop` fails, the deployment continues with DownloadBundle. If `BeforeBlockTraffic` fails, the deployment continues with `BlockTraffic` . If `AfterBlockTraffic` fails, the deployment continues with `ApplicationStop` .
	//
	// If false or not specified, then if a lifecycle event fails during a deployment to an instance, that deployment fails. If deployment to that instance is part of an overall deployment and the number of healthy hosts is not less than the minimum number of healthy hosts, then a deployment to the next instance is attempted.
	//
	// During a deployment, the AWS CodeDeploy agent runs the scripts specified for `ApplicationStop` , `BeforeBlockTraffic` , and `AfterBlockTraffic` in the AppSpec file from the previous successful deployment. (All other scripts are run from the AppSpec file in the current deployment.) If one of these scripts contains an error and does not run successfully, the deployment can fail.
	//
	// If the cause of the failure is a script from the last successful deployment that will never run successfully, create a new deployment and use `ignoreApplicationStopFailures` to specify that the `ApplicationStop` , `BeforeBlockTraffic` , and `AfterBlockTraffic` failures should be ignored.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-deployment.html#cfn-codedeploy-deploymentgroup-deployment-ignoreapplicationstopfailures
	//
	IgnoreApplicationStopFailures interface{} `field:"optional" json:"ignoreApplicationStopFailures" yaml:"ignoreApplicationStopFailures"`
}

`Deployment` is a property of the [DeploymentGroup](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html) resource that specifies an AWS CodeDeploy application revision to be deployed to instances in the deployment group. If you specify an application revision, your target revision is deployed as soon as the provisioning process is complete.

Example:

// 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"

deploymentProperty := &DeploymentProperty{
	Revision: &RevisionLocationProperty{
		GitHubLocation: &GitHubLocationProperty{
			CommitId: jsii.String("commitId"),
			Repository: jsii.String("repository"),
		},
		RevisionType: jsii.String("revisionType"),
		S3Location: &S3LocationProperty{
			Bucket: jsii.String("bucket"),
			Key: jsii.String("key"),

			// the properties below are optional
			BundleType: jsii.String("bundleType"),
			ETag: jsii.String("eTag"),
			Version: jsii.String("version"),
		},
	},

	// the properties below are optional
	Description: jsii.String("description"),
	IgnoreApplicationStopFailures: jsii.Boolean(false),
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-deployment.html

type CfnDeploymentGroup_DeploymentReadyOptionProperty

type CfnDeploymentGroup_DeploymentReadyOptionProperty struct {
	// Information about when to reroute traffic from an original environment to a replacement environment in a blue/green deployment.
	//
	// - CONTINUE_DEPLOYMENT: Register new instances with the load balancer immediately after the new application revision is installed on the instances in the replacement environment.
	// - STOP_DEPLOYMENT: Do not register new instances with a load balancer unless traffic rerouting is started using [ContinueDeployment](https://docs.aws.amazon.com/codedeploy/latest/APIReference/API_ContinueDeployment.html) . If traffic rerouting is not started before the end of the specified wait period, the deployment status is changed to Stopped.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-deploymentreadyoption.html#cfn-codedeploy-deploymentgroup-deploymentreadyoption-actionontimeout
	//
	ActionOnTimeout *string `field:"optional" json:"actionOnTimeout" yaml:"actionOnTimeout"`
	// The number of minutes to wait before the status of a blue/green deployment is changed to Stopped if rerouting is not started manually.
	//
	// Applies only to the `STOP_DEPLOYMENT` option for `actionOnTimeout` .
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-deploymentreadyoption.html#cfn-codedeploy-deploymentgroup-deploymentreadyoption-waittimeinminutes
	//
	WaitTimeInMinutes *float64 `field:"optional" json:"waitTimeInMinutes" yaml:"waitTimeInMinutes"`
}

Information about how traffic is rerouted to instances in a replacement environment in a blue/green deployment.

Example:

// 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"

deploymentReadyOptionProperty := &DeploymentReadyOptionProperty{
	ActionOnTimeout: jsii.String("actionOnTimeout"),
	WaitTimeInMinutes: jsii.Number(123),
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-deploymentreadyoption.html

type CfnDeploymentGroup_DeploymentStyleProperty

type CfnDeploymentGroup_DeploymentStyleProperty struct {
	// Indicates whether to route deployment traffic behind a load balancer.
	//
	// > An Amazon EC2 Application Load Balancer or Network Load Balancer is required for an Amazon ECS deployment.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-deploymentstyle.html#cfn-codedeploy-deploymentgroup-deploymentstyle-deploymentoption
	//
	DeploymentOption *string `field:"optional" json:"deploymentOption" yaml:"deploymentOption"`
	// Indicates whether to run an in-place or blue/green deployment.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-deploymentstyle.html#cfn-codedeploy-deploymentgroup-deploymentstyle-deploymenttype
	//
	DeploymentType *string `field:"optional" json:"deploymentType" yaml:"deploymentType"`
}

Information about the type of deployment, either in-place or blue/green, you want to run and whether to route deployment traffic behind a load balancer.

Example:

// 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"

deploymentStyleProperty := &DeploymentStyleProperty{
	DeploymentOption: jsii.String("deploymentOption"),
	DeploymentType: jsii.String("deploymentType"),
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-deploymentstyle.html

type CfnDeploymentGroup_EC2TagFilterProperty

type CfnDeploymentGroup_EC2TagFilterProperty struct {
	// The tag filter key.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-ec2tagfilter.html#cfn-codedeploy-deploymentgroup-ec2tagfilter-key
	//
	Key *string `field:"optional" json:"key" yaml:"key"`
	// The tag filter type:.
	//
	// - `KEY_ONLY` : Key only.
	// - `VALUE_ONLY` : Value only.
	// - `KEY_AND_VALUE` : Key and value.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-ec2tagfilter.html#cfn-codedeploy-deploymentgroup-ec2tagfilter-type
	//
	Type *string `field:"optional" json:"type" yaml:"type"`
	// The tag filter value.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-ec2tagfilter.html#cfn-codedeploy-deploymentgroup-ec2tagfilter-value
	//
	Value *string `field:"optional" json:"value" yaml:"value"`
}

Information about an Amazon EC2 tag filter.

For more information about using tags and tag groups to help manage your Amazon EC2 instances and on-premises instances, see [Tagging Instances for Deployment Groups in AWS CodeDeploy](https://docs.aws.amazon.com/codedeploy/latest/userguide/instances-tagging.html) in the *AWS CodeDeploy User Guide* .

Example:

// 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"

eC2TagFilterProperty := &EC2TagFilterProperty{
	Key: jsii.String("key"),
	Type: jsii.String("type"),
	Value: jsii.String("value"),
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-ec2tagfilter.html

type CfnDeploymentGroup_EC2TagSetListObjectProperty

type CfnDeploymentGroup_EC2TagSetListObjectProperty struct {
	// A list that contains other lists of Amazon EC2 instance tag groups.
	//
	// For an instance to be included in the deployment group, it must be identified by all of the tag groups in the list.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-ec2tagsetlistobject.html#cfn-codedeploy-deploymentgroup-ec2tagsetlistobject-ec2taggroup
	//
	Ec2TagGroup interface{} `field:"optional" json:"ec2TagGroup" yaml:"ec2TagGroup"`
}

The `EC2TagSet` property type specifies information about groups of tags applied to Amazon EC2 instances.

The deployment group includes only Amazon EC2 instances identified by all the tag groups. Cannot be used in the same template as EC2TagFilters.

For more information about using tags and tag groups to help manage your Amazon EC2 instances and on-premises instances, see [Tagging Instances for Deployment Groups in AWS CodeDeploy](https://docs.aws.amazon.com/codedeploy/latest/userguide/instances-tagging.html) in the *AWS CodeDeploy User Guide* .

`EC2TagSet` is a property of the [DeploymentGroup](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html) resource type.

Example:

// 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"

eC2TagSetListObjectProperty := &EC2TagSetListObjectProperty{
	Ec2TagGroup: []interface{}{
		&EC2TagFilterProperty{
			Key: jsii.String("key"),
			Type: jsii.String("type"),
			Value: jsii.String("value"),
		},
	},
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-ec2tagsetlistobject.html

type CfnDeploymentGroup_EC2TagSetProperty

type CfnDeploymentGroup_EC2TagSetProperty struct {
	// The Amazon EC2 tags that are already applied to Amazon EC2 instances that you want to include in the deployment group.
	//
	// CodeDeploy includes all Amazon EC2 instances identified by any of the tags you specify in this deployment group.
	//
	// Duplicates are not allowed.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-ec2tagset.html#cfn-codedeploy-deploymentgroup-ec2tagset-ec2tagsetlist
	//
	Ec2TagSetList interface{} `field:"optional" json:"ec2TagSetList" yaml:"ec2TagSetList"`
}

The `EC2TagSet` property type specifies information about groups of tags applied to Amazon EC2 instances.

The deployment group includes only Amazon EC2 instances identified by all the tag groups. `EC2TagSet` cannot be used in the same template as `EC2TagFilter` .

For information about using tags and tag groups to help manage your Amazon EC2 instances and on-premises instances, see [Tagging Instances for Deployment Groups in AWS CodeDeploy](https://docs.aws.amazon.com/codedeploy/latest/userguide/instances-tagging.html) .

Example:

// 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"

eC2TagSetProperty := &EC2TagSetProperty{
	Ec2TagSetList: []interface{}{
		&EC2TagSetListObjectProperty{
			Ec2TagGroup: []interface{}{
				&EC2TagFilterProperty{
					Key: jsii.String("key"),
					Type: jsii.String("type"),
					Value: jsii.String("value"),
				},
			},
		},
	},
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-ec2tagset.html

type CfnDeploymentGroup_ECSServiceProperty

type CfnDeploymentGroup_ECSServiceProperty struct {
	// The name of the cluster that the Amazon ECS service is associated with.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-ecsservice.html#cfn-codedeploy-deploymentgroup-ecsservice-clustername
	//
	ClusterName *string `field:"required" json:"clusterName" yaml:"clusterName"`
	// The name of the target Amazon ECS service.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-ecsservice.html#cfn-codedeploy-deploymentgroup-ecsservice-servicename
	//
	ServiceName *string `field:"required" json:"serviceName" yaml:"serviceName"`
}

Contains the service and cluster names used to identify an Amazon ECS deployment's target.

Example:

// 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"

eCSServiceProperty := &ECSServiceProperty{
	ClusterName: jsii.String("clusterName"),
	ServiceName: jsii.String("serviceName"),
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-ecsservice.html

type CfnDeploymentGroup_ELBInfoProperty

type CfnDeploymentGroup_ELBInfoProperty struct {
	// For blue/green deployments, the name of the load balancer that is used to route traffic from original instances to replacement instances in a blue/green deployment.
	//
	// For in-place deployments, the name of the load balancer that instances are deregistered from so they are not serving traffic during a deployment, and then re-registered with after the deployment is complete.
	//
	// > AWS CloudFormation supports blue/green deployments on AWS Lambda compute platforms only.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-elbinfo.html#cfn-codedeploy-deploymentgroup-elbinfo-name
	//
	Name *string `field:"optional" json:"name" yaml:"name"`
}

The `ELBInfo` property type specifies information about the Elastic Load Balancing load balancer used for an CodeDeploy deployment group.

If you specify the `ELBInfo` property, the `DeploymentStyle.DeploymentOption` property must be set to `WITH_TRAFFIC_CONTROL` for AWS CodeDeploy to route your traffic using the specified load balancers.

`ELBInfo` is a property of the [AWS CodeDeploy DeploymentGroup LoadBalancerInfo](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-loadbalancerinfo.html) property type.

Example:

// 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"

eLBInfoProperty := &ELBInfoProperty{
	Name: jsii.String("name"),
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-elbinfo.html

type CfnDeploymentGroup_GitHubLocationProperty

type CfnDeploymentGroup_GitHubLocationProperty struct {
	// The SHA1 commit ID of the GitHub commit that represents the bundled artifacts for the application revision.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-githublocation.html#cfn-codedeploy-deploymentgroup-githublocation-commitid
	//
	CommitId *string `field:"required" json:"commitId" yaml:"commitId"`
	// The GitHub account and repository pair that stores a reference to the commit that represents the bundled artifacts for the application revision.
	//
	// Specify the value as `account/repository` .
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-githublocation.html#cfn-codedeploy-deploymentgroup-githublocation-repository
	//
	Repository *string `field:"required" json:"repository" yaml:"repository"`
}

`GitHubLocation` is a property of the [CodeDeploy DeploymentGroup Revision](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-deployment-revision.html) property that specifies the location of an application revision that is stored in GitHub.

Example:

// 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"

gitHubLocationProperty := &GitHubLocationProperty{
	CommitId: jsii.String("commitId"),
	Repository: jsii.String("repository"),
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-githublocation.html

type CfnDeploymentGroup_GreenFleetProvisioningOptionProperty

type CfnDeploymentGroup_GreenFleetProvisioningOptionProperty struct {
	// The method used to add instances to a replacement environment.
	//
	// - `DISCOVER_EXISTING` : Use instances that already exist or will be created manually.
	// - `COPY_AUTO_SCALING_GROUP` : Use settings from a specified Auto Scaling group to define and create instances in a new Auto Scaling group.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-greenfleetprovisioningoption.html#cfn-codedeploy-deploymentgroup-greenfleetprovisioningoption-action
	//
	Action *string `field:"optional" json:"action" yaml:"action"`
}

Information about the instances that belong to the replacement environment in a blue/green deployment.

Example:

// 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"

greenFleetProvisioningOptionProperty := &GreenFleetProvisioningOptionProperty{
	Action: jsii.String("action"),
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-greenfleetprovisioningoption.html

type CfnDeploymentGroup_LoadBalancerInfoProperty

type CfnDeploymentGroup_LoadBalancerInfoProperty struct {
	// An array that contains information about the load balancers to use for load balancing in a deployment.
	//
	// If you're using Classic Load Balancers, specify those load balancers in this array.
	//
	// > You can add up to 10 load balancers to the array. > If you're using Application Load Balancers or Network Load Balancers, use the `targetGroupInfoList` array instead of this one.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-loadbalancerinfo.html#cfn-codedeploy-deploymentgroup-loadbalancerinfo-elbinfolist
	//
	ElbInfoList interface{} `field:"optional" json:"elbInfoList" yaml:"elbInfoList"`
	// An array that contains information about the target groups to use for load balancing in a deployment.
	//
	// If you're using Application Load Balancers and Network Load Balancers, specify their associated target groups in this array.
	//
	// > You can add up to 10 target groups to the array. > If you're using Classic Load Balancers, use the `elbInfoList` array instead of this one.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-loadbalancerinfo.html#cfn-codedeploy-deploymentgroup-loadbalancerinfo-targetgroupinfolist
	//
	TargetGroupInfoList interface{} `field:"optional" json:"targetGroupInfoList" yaml:"targetGroupInfoList"`
	// The target group pair information.
	//
	// This is an array of `TargeGroupPairInfo` objects with a maximum size of one.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-loadbalancerinfo.html#cfn-codedeploy-deploymentgroup-loadbalancerinfo-targetgrouppairinfolist
	//
	TargetGroupPairInfoList interface{} `field:"optional" json:"targetGroupPairInfoList" yaml:"targetGroupPairInfoList"`
}

The `LoadBalancerInfo` property type specifies information about the load balancer or target group used for an AWS CodeDeploy deployment group.

For more information, see [Integrating CodeDeploy with Elastic Load Balancing](https://docs.aws.amazon.com/codedeploy/latest/userguide/integrations-aws-elastic-load-balancing.html) in the *AWS CodeDeploy User Guide* .

For AWS CloudFormation to use the properties specified in `LoadBalancerInfo` , the `DeploymentStyle.DeploymentOption` property must be set to `WITH_TRAFFIC_CONTROL` . If `DeploymentStyle.DeploymentOption` is not set to `WITH_TRAFFIC_CONTROL` , AWS CloudFormation ignores any settings specified in `LoadBalancerInfo` .

> AWS CloudFormation supports blue/green deployments on the AWS Lambda compute platform only.

`LoadBalancerInfo` is a property of the [DeploymentGroup](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html) resource.

Example:

// 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"

loadBalancerInfoProperty := &LoadBalancerInfoProperty{
	ElbInfoList: []interface{}{
		&ELBInfoProperty{
			Name: jsii.String("name"),
		},
	},
	TargetGroupInfoList: []interface{}{
		&TargetGroupInfoProperty{
			Name: jsii.String("name"),
		},
	},
	TargetGroupPairInfoList: []interface{}{
		&TargetGroupPairInfoProperty{
			ProdTrafficRoute: &TrafficRouteProperty{
				ListenerArns: []*string{
					jsii.String("listenerArns"),
				},
			},
			TargetGroups: []interface{}{
				&TargetGroupInfoProperty{
					Name: jsii.String("name"),
				},
			},
			TestTrafficRoute: &TrafficRouteProperty{
				ListenerArns: []*string{
					jsii.String("listenerArns"),
				},
			},
		},
	},
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-loadbalancerinfo.html

type CfnDeploymentGroup_OnPremisesTagSetListObjectProperty

type CfnDeploymentGroup_OnPremisesTagSetListObjectProperty struct {
	// Information about groups of on-premises instance tags.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-onpremisestagsetlistobject.html#cfn-codedeploy-deploymentgroup-onpremisestagsetlistobject-onpremisestaggroup
	//
	OnPremisesTagGroup interface{} `field:"optional" json:"onPremisesTagGroup" yaml:"onPremisesTagGroup"`
}

The `OnPremisesTagSetListObject` property type specifies lists of on-premises instance tag groups.

In order for an instance to be included in the deployment group, it must be identified by all the tag groups in the list.

`OnPremisesTagSetListObject` is a property of the [CodeDeploy DeploymentGroup OnPremisesTagSet](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-onpremisestagset.html) property type.

Example:

// 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"

onPremisesTagSetListObjectProperty := &OnPremisesTagSetListObjectProperty{
	OnPremisesTagGroup: []interface{}{
		&TagFilterProperty{
			Key: jsii.String("key"),
			Type: jsii.String("type"),
			Value: jsii.String("value"),
		},
	},
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-onpremisestagsetlistobject.html

type CfnDeploymentGroup_OnPremisesTagSetProperty

type CfnDeploymentGroup_OnPremisesTagSetProperty struct {
	// A list that contains other lists of on-premises instance tag groups.
	//
	// For an instance to be included in the deployment group, it must be identified by all of the tag groups in the list.
	//
	// Duplicates are not allowed.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-onpremisestagset.html#cfn-codedeploy-deploymentgroup-onpremisestagset-onpremisestagsetlist
	//
	OnPremisesTagSetList interface{} `field:"optional" json:"onPremisesTagSetList" yaml:"onPremisesTagSetList"`
}

The `OnPremisesTagSet` property type specifies a list containing other lists of on-premises instance tag groups.

In order for an instance to be included in the deployment group, it must be identified by all the tag groups in the list.

For more information about using tags and tag groups to help manage your Amazon EC2 instances and on-premises instances, see [Tagging Instances for Deployment Groups in AWS CodeDeploy](https://docs.aws.amazon.com/codedeploy/latest/userguide/instances-tagging.html) in the *AWS CodeDeploy User Guide* .

`OnPremisesTagSet` is a property of the [DeploymentGroup](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html) resource.

Example:

// 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"

onPremisesTagSetProperty := &OnPremisesTagSetProperty{
	OnPremisesTagSetList: []interface{}{
		&OnPremisesTagSetListObjectProperty{
			OnPremisesTagGroup: []interface{}{
				&TagFilterProperty{
					Key: jsii.String("key"),
					Type: jsii.String("type"),
					Value: jsii.String("value"),
				},
			},
		},
	},
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-onpremisestagset.html

type CfnDeploymentGroup_RevisionLocationProperty

type CfnDeploymentGroup_RevisionLocationProperty struct {
	// Information about the location of application artifacts stored in GitHub.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-revisionlocation.html#cfn-codedeploy-deploymentgroup-revisionlocation-githublocation
	//
	GitHubLocation interface{} `field:"optional" json:"gitHubLocation" yaml:"gitHubLocation"`
	// The type of application revision:.
	//
	// - S3: An application revision stored in Amazon S3.
	// - GitHub: An application revision stored in GitHub (EC2/On-premises deployments only).
	// - String: A YAML-formatted or JSON-formatted string ( AWS Lambda deployments only).
	// - AppSpecContent: An `AppSpecContent` object that contains the contents of an AppSpec file for an AWS Lambda or Amazon ECS deployment. The content is formatted as JSON or YAML stored as a RawString.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-revisionlocation.html#cfn-codedeploy-deploymentgroup-revisionlocation-revisiontype
	//
	RevisionType *string `field:"optional" json:"revisionType" yaml:"revisionType"`
	// Information about the location of a revision stored in Amazon S3.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-revisionlocation.html#cfn-codedeploy-deploymentgroup-revisionlocation-s3location
	//
	S3Location interface{} `field:"optional" json:"s3Location" yaml:"s3Location"`
}

`RevisionLocation` is a property that defines the location of the CodeDeploy application revision to deploy.

Example:

// 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"

revisionLocationProperty := &RevisionLocationProperty{
	GitHubLocation: &GitHubLocationProperty{
		CommitId: jsii.String("commitId"),
		Repository: jsii.String("repository"),
	},
	RevisionType: jsii.String("revisionType"),
	S3Location: &S3LocationProperty{
		Bucket: jsii.String("bucket"),
		Key: jsii.String("key"),

		// the properties below are optional
		BundleType: jsii.String("bundleType"),
		ETag: jsii.String("eTag"),
		Version: jsii.String("version"),
	},
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-revisionlocation.html

type CfnDeploymentGroup_S3LocationProperty

type CfnDeploymentGroup_S3LocationProperty struct {
	// The name of the Amazon S3 bucket where the application revision is stored.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-s3location.html#cfn-codedeploy-deploymentgroup-s3location-bucket
	//
	Bucket *string `field:"required" json:"bucket" yaml:"bucket"`
	// The name of the Amazon S3 object that represents the bundled artifacts for the application revision.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-s3location.html#cfn-codedeploy-deploymentgroup-s3location-key
	//
	Key *string `field:"required" json:"key" yaml:"key"`
	// The file type of the application revision. Must be one of the following:.
	//
	// - JSON
	// - tar: A tar archive file.
	// - tgz: A compressed tar archive file.
	// - YAML
	// - zip: A zip archive file.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-s3location.html#cfn-codedeploy-deploymentgroup-s3location-bundletype
	//
	BundleType *string `field:"optional" json:"bundleType" yaml:"bundleType"`
	// The ETag of the Amazon S3 object that represents the bundled artifacts for the application revision.
	//
	// If the ETag is not specified as an input parameter, ETag validation of the object is skipped.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-s3location.html#cfn-codedeploy-deploymentgroup-s3location-etag
	//
	ETag *string `field:"optional" json:"eTag" yaml:"eTag"`
	// A specific version of the Amazon S3 object that represents the bundled artifacts for the application revision.
	//
	// If the version is not specified, the system uses the most recent version by default.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-s3location.html#cfn-codedeploy-deploymentgroup-s3location-version
	//
	Version *string `field:"optional" json:"version" yaml:"version"`
}

`S3Location` is a property of the [CodeDeploy DeploymentGroup Revision](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-deployment-revision.html) property that specifies the location of an application revision that is stored in Amazon Simple Storage Service ( Amazon S3 ).

Example:

// 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"

s3LocationProperty := &S3LocationProperty{
	Bucket: jsii.String("bucket"),
	Key: jsii.String("key"),

	// the properties below are optional
	BundleType: jsii.String("bundleType"),
	ETag: jsii.String("eTag"),
	Version: jsii.String("version"),
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-s3location.html

type CfnDeploymentGroup_TagFilterProperty

type CfnDeploymentGroup_TagFilterProperty struct {
	// The on-premises instance tag filter key.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-tagfilter.html#cfn-codedeploy-deploymentgroup-tagfilter-key
	//
	Key *string `field:"optional" json:"key" yaml:"key"`
	// The on-premises instance tag filter type:.
	//
	// - KEY_ONLY: Key only.
	// - VALUE_ONLY: Value only.
	// - KEY_AND_VALUE: Key and value.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-tagfilter.html#cfn-codedeploy-deploymentgroup-tagfilter-type
	//
	Type *string `field:"optional" json:"type" yaml:"type"`
	// The on-premises instance tag filter value.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-tagfilter.html#cfn-codedeploy-deploymentgroup-tagfilter-value
	//
	Value *string `field:"optional" json:"value" yaml:"value"`
}

`TagFilter` is a property type of the [AWS::CodeDeploy::DeploymentGroup](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codedeploy-deploymentgroup.html) resource that specifies which on-premises instances to associate with the deployment group. To register on-premise instances with AWS CodeDeploy , see [Configure Existing On-Premises Instances by Using AWS CodeDeploy](https://docs.aws.amazon.com/codedeploy/latest/userguide/instances-on-premises.html) in the *AWS CodeDeploy User Guide* .

For more information about using tags and tag groups to help manage your Amazon EC2 instances and on-premises instances, see [Tagging Instances for Deployment Groups in AWS CodeDeploy](https://docs.aws.amazon.com/codedeploy/latest/userguide/instances-tagging.html) in the *AWS CodeDeploy User Guide* .

Example:

// 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"

tagFilterProperty := &TagFilterProperty{
	Key: jsii.String("key"),
	Type: jsii.String("type"),
	Value: jsii.String("value"),
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-tagfilter.html

type CfnDeploymentGroup_TargetGroupInfoProperty

type CfnDeploymentGroup_TargetGroupInfoProperty struct {
	// For blue/green deployments, the name of the target group that instances in the original environment are deregistered from, and instances in the replacement environment registered with.
	//
	// For in-place deployments, the name of the target group that instances are deregistered from, so they are not serving traffic during a deployment, and then re-registered with after the deployment completes. No duplicates allowed.
	//
	// > AWS CloudFormation supports blue/green deployments on AWS Lambda compute platforms only.
	//
	// This value cannot exceed 32 characters, so you should use the `Name` property of the target group, or the `TargetGroupName` attribute with the `Fn::GetAtt` intrinsic function, as shown in the following example. Don't use the group's Amazon Resource Name (ARN) or `TargetGroupFullName` attribute.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-targetgroupinfo.html#cfn-codedeploy-deploymentgroup-targetgroupinfo-name
	//
	Name *string `field:"optional" json:"name" yaml:"name"`
}

The `TargetGroupInfo` property type specifies information about a target group in Elastic Load Balancing to use in a deployment.

Instances are registered as targets in a target group, and traffic is routed to the target group. For more information, see [TargetGroupInfo](https://docs.aws.amazon.com/codedeploy/latest/APIReference/API_TargetGroupInfo.html) in the *AWS CodeDeploy API Reference*

If you specify the `TargetGroupInfo` property, the `DeploymentStyle.DeploymentOption` property must be set to `WITH_TRAFFIC_CONTROL` for CodeDeploy to route your traffic using the specified target groups.

`TargetGroupInfo` is a property of the [LoadBalancerInfo](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-loadbalancerinfo.html) property type.

Example:

// 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"

targetGroupInfoProperty := &TargetGroupInfoProperty{
	Name: jsii.String("name"),
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-targetgroupinfo.html

type CfnDeploymentGroup_TargetGroupPairInfoProperty added in v2.18.0

type CfnDeploymentGroup_TargetGroupPairInfoProperty struct {
	// The path used by a load balancer to route production traffic when an Amazon ECS deployment is complete.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-targetgrouppairinfo.html#cfn-codedeploy-deploymentgroup-targetgrouppairinfo-prodtrafficroute
	//
	ProdTrafficRoute interface{} `field:"optional" json:"prodTrafficRoute" yaml:"prodTrafficRoute"`
	// One pair of target groups.
	//
	// One is associated with the original task set. The second is associated with the task set that serves traffic after the deployment is complete.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-targetgrouppairinfo.html#cfn-codedeploy-deploymentgroup-targetgrouppairinfo-targetgroups
	//
	TargetGroups interface{} `field:"optional" json:"targetGroups" yaml:"targetGroups"`
	// An optional path used by a load balancer to route test traffic after an Amazon ECS deployment.
	//
	// Validation can occur while test traffic is served during a deployment.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-targetgrouppairinfo.html#cfn-codedeploy-deploymentgroup-targetgrouppairinfo-testtrafficroute
	//
	TestTrafficRoute interface{} `field:"optional" json:"testTrafficRoute" yaml:"testTrafficRoute"`
}

Information about two target groups and how traffic is routed during an Amazon ECS deployment.

An optional test traffic route can be specified.

Example:

// 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"

targetGroupPairInfoProperty := &TargetGroupPairInfoProperty{
	ProdTrafficRoute: &TrafficRouteProperty{
		ListenerArns: []*string{
			jsii.String("listenerArns"),
		},
	},
	TargetGroups: []interface{}{
		&TargetGroupInfoProperty{
			Name: jsii.String("name"),
		},
	},
	TestTrafficRoute: &TrafficRouteProperty{
		ListenerArns: []*string{
			jsii.String("listenerArns"),
		},
	},
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-targetgrouppairinfo.html

type CfnDeploymentGroup_TrafficRouteProperty added in v2.18.0

type CfnDeploymentGroup_TrafficRouteProperty struct {
	// The Amazon Resource Name (ARN) of one listener.
	//
	// The listener identifies the route between a target group and a load balancer. This is an array of strings with a maximum size of one.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-trafficroute.html#cfn-codedeploy-deploymentgroup-trafficroute-listenerarns
	//
	ListenerArns *[]*string `field:"optional" json:"listenerArns" yaml:"listenerArns"`
}

Information about a listener.

The listener contains the path used to route traffic that is received from the load balancer to a target group.

Example:

// 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"

trafficRouteProperty := &TrafficRouteProperty{
	ListenerArns: []*string{
		jsii.String("listenerArns"),
	},
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-trafficroute.html

type CfnDeploymentGroup_TriggerConfigProperty

type CfnDeploymentGroup_TriggerConfigProperty struct {
	// The event type or types that trigger notifications.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-triggerconfig.html#cfn-codedeploy-deploymentgroup-triggerconfig-triggerevents
	//
	TriggerEvents *[]*string `field:"optional" json:"triggerEvents" yaml:"triggerEvents"`
	// The name of the notification trigger.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-triggerconfig.html#cfn-codedeploy-deploymentgroup-triggerconfig-triggername
	//
	TriggerName *string `field:"optional" json:"triggerName" yaml:"triggerName"`
	// The Amazon Resource Name (ARN) of the Amazon Simple Notification Service topic through which notifications about deployment or instance events are sent.
	// See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-triggerconfig.html#cfn-codedeploy-deploymentgroup-triggerconfig-triggertargetarn
	//
	TriggerTargetArn *string `field:"optional" json:"triggerTargetArn" yaml:"triggerTargetArn"`
}

Information about notification triggers for the deployment group.

Example:

// 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"

triggerConfigProperty := &TriggerConfigProperty{
	TriggerEvents: []*string{
		jsii.String("triggerEvents"),
	},
	TriggerName: jsii.String("triggerName"),
	TriggerTargetArn: jsii.String("triggerTargetArn"),
}

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codedeploy-deploymentgroup-triggerconfig.html

type ComputePlatform added in v2.45.0

type ComputePlatform string

The compute platform of a deployment configuration.

const (
	// The deployment will target EC2 instances or on-premise servers.
	ComputePlatform_SERVER ComputePlatform = "SERVER"
	// The deployment will target a Lambda function.
	ComputePlatform_LAMBDA ComputePlatform = "LAMBDA"
	// The deployment will target an ECS server.
	ComputePlatform_ECS ComputePlatform = "ECS"
)

type CustomLambdaDeploymentConfig deprecated

type CustomLambdaDeploymentConfig interface {
	awscdk.Resource
	ILambdaDeploymentConfig
	// The arn of the deployment config.
	// Deprecated: Use `LambdaDeploymentConfig`.
	DeploymentConfigArn() *string
	// The name of the deployment config.
	// Deprecated: Use `LambdaDeploymentConfig`.
	DeploymentConfigName() *string
	// The environment this resource belongs to.
	//
	// For resources that are created and managed by the CDK
	// (generally, those created by creating new class instances like Role, Bucket, etc.),
	// this is always the same as the environment of the stack they belong to;
	// however, for imported resources
	// (those obtained from static methods like fromRoleArn, fromBucketName, etc.),
	// that might be different than the stack they were imported into.
	// Deprecated: CloudFormation now supports Lambda deployment configurations without custom resources. Use `LambdaDeploymentConfig`.
	Env() *awscdk.ResourceEnvironment
	// The tree node.
	// Deprecated: CloudFormation now supports Lambda deployment configurations without custom resources. Use `LambdaDeploymentConfig`.
	Node() constructs.Node
	// Returns a string-encoded token that resolves to the physical name that should be passed to the CloudFormation resource.
	//
	// This value will resolve to one of the following:
	// - a concrete value (e.g. `"my-awesome-bucket"`)
	// - `undefined`, when a name should be generated by CloudFormation
	// - a concrete name generated automatically during synthesis, in
	//   cross-environment scenarios.
	// Deprecated: CloudFormation now supports Lambda deployment configurations without custom resources. Use `LambdaDeploymentConfig`.
	PhysicalName() *string
	// The stack in which this resource is defined.
	// Deprecated: CloudFormation now supports Lambda deployment configurations without custom resources. Use `LambdaDeploymentConfig`.
	Stack() awscdk.Stack
	// Apply the given removal policy to this resource.
	//
	// The Removal Policy controls what happens to this resource when it stops
	// being managed by CloudFormation, either because you've removed it from the
	// CDK application or because you've made a change that requires the resource
	// to be replaced.
	//
	// The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS
	// account for data recovery and cleanup later (`RemovalPolicy.RETAIN`).
	// Deprecated: CloudFormation now supports Lambda deployment configurations without custom resources. Use `LambdaDeploymentConfig`.
	ApplyRemovalPolicy(policy awscdk.RemovalPolicy)
	// Deprecated: CloudFormation now supports Lambda deployment configurations without custom resources. Use `LambdaDeploymentConfig`.
	GeneratePhysicalName() *string
	// Returns an environment-sensitive token that should be used for the resource's "ARN" attribute (e.g. `bucket.bucketArn`).
	//
	// Normally, this token will resolve to `arnAttr`, but if the resource is
	// referenced across environments, `arnComponents` will be used to synthesize
	// a concrete ARN with the resource's physical name. Make sure to reference
	// `this.physicalName` in `arnComponents`.
	// Deprecated: CloudFormation now supports Lambda deployment configurations without custom resources. Use `LambdaDeploymentConfig`.
	GetResourceArnAttribute(arnAttr *string, arnComponents *awscdk.ArnComponents) *string
	// Returns an environment-sensitive token that should be used for the resource's "name" attribute (e.g. `bucket.bucketName`).
	//
	// Normally, this token will resolve to `nameAttr`, but if the resource is
	// referenced across environments, it will be resolved to `this.physicalName`,
	// which will be a concrete name.
	// Deprecated: CloudFormation now supports Lambda deployment configurations without custom resources. Use `LambdaDeploymentConfig`.
	GetResourceNameAttribute(nameAttr *string) *string
	// Returns a string representation of this construct.
	// Deprecated: CloudFormation now supports Lambda deployment configurations without custom resources. Use `LambdaDeploymentConfig`.
	ToString() *string
}

A custom Deployment Configuration for a Lambda Deployment Group.

Example:

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import cdk "github.com/aws/aws-cdk-go/awscdk"
import "github.com/aws/aws-cdk-go/awscdk"

customLambdaDeploymentConfig := awscdk.Aws_codedeploy.NewCustomLambdaDeploymentConfig(this, jsii.String("MyCustomLambdaDeploymentConfig"), &CustomLambdaDeploymentConfigProps{
	Interval: cdk.Duration_Minutes(jsii.Number(30)),
	Percentage: jsii.Number(123),
	Type: awscdk.*Aws_codedeploy.CustomLambdaDeploymentConfigType_CANARY,

	// the properties below are optional
	DeploymentConfigName: jsii.String("deploymentConfigName"),
})

Deprecated: CloudFormation now supports Lambda deployment configurations without custom resources. Use `LambdaDeploymentConfig`.

func NewCustomLambdaDeploymentConfig deprecated

func NewCustomLambdaDeploymentConfig(scope constructs.Construct, id *string, props *CustomLambdaDeploymentConfigProps) CustomLambdaDeploymentConfig

Deprecated: CloudFormation now supports Lambda deployment configurations without custom resources. Use `LambdaDeploymentConfig`.

type CustomLambdaDeploymentConfigProps deprecated

type CustomLambdaDeploymentConfigProps struct {
	// The interval, in number of minutes: - For LINEAR, how frequently additional traffic is shifted - For CANARY, how long to shift traffic before the full deployment.
	// Deprecated: Use `LambdaDeploymentConfig`.
	Interval awscdk.Duration `field:"required" json:"interval" yaml:"interval"`
	// The integer percentage of traffic to shift: - For LINEAR, the percentage to shift every interval - For CANARY, the percentage to shift until the interval passes, before the full deployment.
	// Deprecated: Use `LambdaDeploymentConfig`.
	Percentage *float64 `field:"required" json:"percentage" yaml:"percentage"`
	// The type of deployment config, either CANARY or LINEAR.
	// Deprecated: Use `LambdaDeploymentConfig`.
	Type CustomLambdaDeploymentConfigType `field:"required" json:"type" yaml:"type"`
	// The verbatim name of the deployment config.
	//
	// Must be unique per account/region.
	// Other parameters cannot be updated if this name is provided.
	// Default: - automatically generated name.
	//
	// Deprecated: Use `LambdaDeploymentConfig`.
	DeploymentConfigName *string `field:"optional" json:"deploymentConfigName" yaml:"deploymentConfigName"`
}

Properties of a reference to a CodeDeploy Lambda Deployment Configuration.

Example:

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import cdk "github.com/aws/aws-cdk-go/awscdk"
import "github.com/aws/aws-cdk-go/awscdk"

customLambdaDeploymentConfigProps := &CustomLambdaDeploymentConfigProps{
	Interval: cdk.Duration_Minutes(jsii.Number(30)),
	Percentage: jsii.Number(123),
	Type: awscdk.Aws_codedeploy.CustomLambdaDeploymentConfigType_CANARY,

	// the properties below are optional
	DeploymentConfigName: jsii.String("deploymentConfigName"),
}

Deprecated: Use `LambdaDeploymentConfig`.

type CustomLambdaDeploymentConfigType

type CustomLambdaDeploymentConfigType string

Lambda Deployment config type. Deprecated: Use `LambdaDeploymentConfig`.

const (
	// Canary deployment type.
	// Deprecated: Use `LambdaDeploymentConfig`.
	CustomLambdaDeploymentConfigType_CANARY CustomLambdaDeploymentConfigType = "CANARY"
	// Linear deployment type.
	// Deprecated: Use `LambdaDeploymentConfig`.
	CustomLambdaDeploymentConfigType_LINEAR CustomLambdaDeploymentConfigType = "LINEAR"
)

type EcsApplication

type EcsApplication interface {
	awscdk.Resource
	IEcsApplication
	ApplicationArn() *string
	ApplicationName() *string
	// The environment this resource belongs to.
	//
	// For resources that are created and managed by the CDK
	// (generally, those created by creating new class instances like Role, Bucket, etc.),
	// this is always the same as the environment of the stack they belong to;
	// however, for imported resources
	// (those obtained from static methods like fromRoleArn, fromBucketName, etc.),
	// that might be different than the stack they were imported into.
	Env() *awscdk.ResourceEnvironment
	// The tree node.
	Node() constructs.Node
	// Returns a string-encoded token that resolves to the physical name that should be passed to the CloudFormation resource.
	//
	// This value will resolve to one of the following:
	// - a concrete value (e.g. `"my-awesome-bucket"`)
	// - `undefined`, when a name should be generated by CloudFormation
	// - a concrete name generated automatically during synthesis, in
	//   cross-environment scenarios.
	PhysicalName() *string
	// The stack in which this resource is defined.
	Stack() awscdk.Stack
	// Apply the given removal policy to this resource.
	//
	// The Removal Policy controls what happens to this resource when it stops
	// being managed by CloudFormation, either because you've removed it from the
	// CDK application or because you've made a change that requires the resource
	// to be replaced.
	//
	// The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS
	// account for data recovery and cleanup later (`RemovalPolicy.RETAIN`).
	ApplyRemovalPolicy(policy awscdk.RemovalPolicy)
	GeneratePhysicalName() *string
	// Returns an environment-sensitive token that should be used for the resource's "ARN" attribute (e.g. `bucket.bucketArn`).
	//
	// Normally, this token will resolve to `arnAttr`, but if the resource is
	// referenced across environments, `arnComponents` will be used to synthesize
	// a concrete ARN with the resource's physical name. Make sure to reference
	// `this.physicalName` in `arnComponents`.
	GetResourceArnAttribute(arnAttr *string, arnComponents *awscdk.ArnComponents) *string
	// Returns an environment-sensitive token that should be used for the resource's "name" attribute (e.g. `bucket.bucketName`).
	//
	// Normally, this token will resolve to `nameAttr`, but if the resource is
	// referenced across environments, it will be resolved to `this.physicalName`,
	// which will be a concrete name.
	GetResourceNameAttribute(nameAttr *string) *string
	// Returns a string representation of this construct.
	ToString() *string
}

A CodeDeploy Application that deploys to an Amazon ECS service.

Example:

application := codedeploy.NewEcsApplication(this, jsii.String("CodeDeployApplication"), &EcsApplicationProps{
	ApplicationName: jsii.String("MyApplication"),
})

func NewEcsApplication

func NewEcsApplication(scope constructs.Construct, id *string, props *EcsApplicationProps) EcsApplication

type EcsApplicationProps

type EcsApplicationProps struct {
	// The physical, human-readable name of the CodeDeploy Application.
	// Default: an auto-generated name will be used.
	//
	ApplicationName *string `field:"optional" json:"applicationName" yaml:"applicationName"`
}

Construction properties for `EcsApplication`.

Example:

application := codedeploy.NewEcsApplication(this, jsii.String("CodeDeployApplication"), &EcsApplicationProps{
	ApplicationName: jsii.String("MyApplication"),
})

type EcsBlueGreenDeploymentConfig added in v2.50.0

type EcsBlueGreenDeploymentConfig struct {
	// The target group that will be associated with the 'blue' ECS task set during a blue-green deployment.
	BlueTargetGroup awselasticloadbalancingv2.ITargetGroup `field:"required" json:"blueTargetGroup" yaml:"blueTargetGroup"`
	// The target group that will be associated with the 'green' ECS task set during a blue-green deployment.
	GreenTargetGroup awselasticloadbalancingv2.ITargetGroup `field:"required" json:"greenTargetGroup" yaml:"greenTargetGroup"`
	// The load balancer listener used to serve production traffic and to shift production traffic from the 'blue' ECS task set to the 'green' ECS task set during a blue-green deployment.
	Listener awselasticloadbalancingv2.IListener `field:"required" json:"listener" yaml:"listener"`
	// Specify how long CodeDeploy waits for approval to continue a blue-green deployment before it stops the deployment.
	//
	// After provisioning the 'green' ECS task set and re-routing test traffic, CodeDeploy can wait for approval before
	// continuing the deployment and re-routing production traffic.  During this wait time, validation such as manual
	// testing or running integration tests can occur using the test traffic port, prior to exposing the new 'green' task
	// set to production traffic.  To approve the deployment, validation steps use the CodeDeploy
	// [ContinueDeployment API(https://docs.aws.amazon.com/codedeploy/latest/APIReference/API_ContinueDeployment.html).
	// If the ContinueDeployment API is not called within the wait time period, CodeDeploy will stop the deployment.
	//
	// By default, CodeDeploy will not wait for deployment approval.  After re-routing test traffic to the 'green' ECS task set
	// and running any 'AfterAllowTestTraffic' and 'BeforeAllowTraffic' lifecycle hooks, the deployment will immediately
	// re-route production traffic to the 'green' ECS task set.
	// Default: 0.
	//
	DeploymentApprovalWaitTime awscdk.Duration `field:"optional" json:"deploymentApprovalWaitTime" yaml:"deploymentApprovalWaitTime"`
	// Specify how long CodeDeploy waits before it terminates the original 'blue' ECS task set when a blue-green deployment is complete.
	//
	// During this wait time, CodeDeploy will continue to monitor any CloudWatch alarms specified for the deployment group,
	// and the deployment group can be configured to automatically roll back if those alarms fire.  Once CodeDeploy begins to
	// terminate the 'blue' ECS task set, the deployment can no longer be rolled back, manually or automatically.
	//
	// By default, the deployment will immediately terminate the 'blue' ECS task set after production traffic is successfully
	// routed to the 'green' ECS task set.
	// Default: 0.
	//
	TerminationWaitTime awscdk.Duration `field:"optional" json:"terminationWaitTime" yaml:"terminationWaitTime"`
	// The load balancer listener used to route test traffic to the 'green' ECS task set during a blue-green deployment.
	//
	// During a blue-green deployment, validation can occur after test traffic has been re-routed and before production
	// traffic has been re-routed to the 'green' ECS task set.  You can specify one or more Lambda funtions in the
	// deployment's AppSpec file that run during the AfterAllowTestTraffic hook. The functions can run validation tests.
	// If a validation test fails, a deployment rollback is triggered. If the validation tests succeed, the next hook in
	// the deployment lifecycle, BeforeAllowTraffic, is triggered.
	//
	// If a test listener is not specified, the deployment will proceed to routing the production listener to the 'green' ECS task set
	// and will skip the AfterAllowTestTraffic hook.
	// Default: No test listener will be added.
	//
	TestListener awselasticloadbalancingv2.IListener `field:"optional" json:"testListener" yaml:"testListener"`
}

Specify how the deployment behaves and how traffic is routed to the ECS service during a blue-green ECS deployment.

Example:

var myApplication ecsApplication
var cluster cluster
var taskDefinition fargateTaskDefinition
var blueTargetGroup iTargetGroup
var greenTargetGroup iTargetGroup
var listener iApplicationListener

service := ecs.NewFargateService(this, jsii.String("Service"), &FargateServiceProps{
	Cluster: Cluster,
	TaskDefinition: TaskDefinition,
	DeploymentController: &DeploymentController{
		Type: ecs.DeploymentControllerType_CODE_DEPLOY,
	},
})

codedeploy.NewEcsDeploymentGroup(this, jsii.String("BlueGreenDG"), &EcsDeploymentGroupProps{
	Service: Service,
	BlueGreenDeploymentConfig: &EcsBlueGreenDeploymentConfig{
		BlueTargetGroup: *BlueTargetGroup,
		GreenTargetGroup: *GreenTargetGroup,
		Listener: *Listener,
	},
	DeploymentConfig: codedeploy.EcsDeploymentConfig_CANARY_10PERCENT_5MINUTES(),
})

See: https://docs.aws.amazon.com/codedeploy/latest/userguide/reference-appspec-file-structure-hooks.html#appspec-hooks-ecs

type EcsDeploymentConfig

type EcsDeploymentConfig interface {
	BaseDeploymentConfig
	IEcsDeploymentConfig
	// The arn of the deployment config.
	DeploymentConfigArn() *string
	// The name of the deployment config.
	DeploymentConfigName() *string
	// The environment this resource belongs to.
	//
	// For resources that are created and managed by the CDK
	// (generally, those created by creating new class instances like Role, Bucket, etc.),
	// this is always the same as the environment of the stack they belong to;
	// however, for imported resources
	// (those obtained from static methods like fromRoleArn, fromBucketName, etc.),
	// that might be different than the stack they were imported into.
	Env() *awscdk.ResourceEnvironment
	// The tree node.
	Node() constructs.Node
	// Returns a string-encoded token that resolves to the physical name that should be passed to the CloudFormation resource.
	//
	// This value will resolve to one of the following:
	// - a concrete value (e.g. `"my-awesome-bucket"`)
	// - `undefined`, when a name should be generated by CloudFormation
	// - a concrete name generated automatically during synthesis, in
	//   cross-environment scenarios.
	PhysicalName() *string
	// The stack in which this resource is defined.
	Stack() awscdk.Stack
	// Apply the given removal policy to this resource.
	//
	// The Removal Policy controls what happens to this resource when it stops
	// being managed by CloudFormation, either because you've removed it from the
	// CDK application or because you've made a change that requires the resource
	// to be replaced.
	//
	// The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS
	// account for data recovery and cleanup later (`RemovalPolicy.RETAIN`).
	ApplyRemovalPolicy(policy awscdk.RemovalPolicy)
	GeneratePhysicalName() *string
	// Returns an environment-sensitive token that should be used for the resource's "ARN" attribute (e.g. `bucket.bucketArn`).
	//
	// Normally, this token will resolve to `arnAttr`, but if the resource is
	// referenced across environments, `arnComponents` will be used to synthesize
	// a concrete ARN with the resource's physical name. Make sure to reference
	// `this.physicalName` in `arnComponents`.
	GetResourceArnAttribute(arnAttr *string, arnComponents *awscdk.ArnComponents) *string
	// Returns an environment-sensitive token that should be used for the resource's "name" attribute (e.g. `bucket.bucketName`).
	//
	// Normally, this token will resolve to `nameAttr`, but if the resource is
	// referenced across environments, it will be resolved to `this.physicalName`,
	// which will be a concrete name.
	GetResourceNameAttribute(nameAttr *string) *string
	// Returns a string representation of this construct.
	ToString() *string
}

A custom Deployment Configuration for an ECS Deployment Group.

Example:

var service fargateService
var blueTargetGroup iTargetGroup
var greenTargetGroup iTargetGroup
var listener iApplicationListener
var testListener iApplicationListener

codedeploy.NewEcsDeploymentGroup(this, jsii.String("BlueGreenDG"), &EcsDeploymentGroupProps{
	AutoRollback: &AutoRollbackConfig{
		// CodeDeploy will automatically roll back if the 8-hour approval period times out and the deployment stops
		StoppedDeployment: jsii.Boolean(true),
	},
	Service: Service,
	BlueGreenDeploymentConfig: &EcsBlueGreenDeploymentConfig{
		// The deployment will wait for approval for up to 8 hours before stopping the deployment
		DeploymentApprovalWaitTime: awscdk.Duration_Hours(jsii.Number(8)),
		BlueTargetGroup: *BlueTargetGroup,
		GreenTargetGroup: *GreenTargetGroup,
		Listener: *Listener,
		TestListener: *TestListener,
	},
	DeploymentConfig: codedeploy.EcsDeploymentConfig_CANARY_10PERCENT_5MINUTES(),
})

func NewEcsDeploymentConfig added in v2.45.0

func NewEcsDeploymentConfig(scope constructs.Construct, id *string, props *EcsDeploymentConfigProps) EcsDeploymentConfig

type EcsDeploymentConfigProps added in v2.45.0

type EcsDeploymentConfigProps struct {
	// The physical, human-readable name of the Deployment Configuration.
	// Default: - automatically generated name.
	//
	DeploymentConfigName *string `field:"optional" json:"deploymentConfigName" yaml:"deploymentConfigName"`
	// The configuration that specifies how traffic is shifted from the 'blue' target group to the 'green' target group during a deployment.
	// Default: AllAtOnce.
	//
	TrafficRouting TrafficRouting `field:"optional" json:"trafficRouting" yaml:"trafficRouting"`
}

Construction properties of `EcsDeploymentConfig`.

Example:

codedeploy.NewEcsDeploymentConfig(this, jsii.String("CustomConfig"), &EcsDeploymentConfigProps{
	TrafficRouting: codedeploy.NewTimeBasedCanaryTrafficRouting(&TimeBasedCanaryTrafficRoutingProps{
		Interval: awscdk.Duration_Minutes(jsii.Number(15)),
		Percentage: jsii.Number(5),
	}),
})

type EcsDeploymentGroup

type EcsDeploymentGroup interface {
	awscdk.Resource
	IEcsDeploymentGroup
	// The reference to the CodeDeploy ECS Application that this Deployment Group belongs to.
	Application() IEcsApplication
	// The Deployment Configuration this Group uses.
	DeploymentConfig() IEcsDeploymentConfig
	// The ARN of the Deployment Group.
	DeploymentGroupArn() *string
	// The name of the Deployment Group.
	DeploymentGroupName() *string
	// The environment this resource belongs to.
	//
	// For resources that are created and managed by the CDK
	// (generally, those created by creating new class instances like Role, Bucket, etc.),
	// this is always the same as the environment of the stack they belong to;
	// however, for imported resources
	// (those obtained from static methods like fromRoleArn, fromBucketName, etc.),
	// that might be different than the stack they were imported into.
	Env() *awscdk.ResourceEnvironment
	// The tree node.
	Node() constructs.Node
	// Returns a string-encoded token that resolves to the physical name that should be passed to the CloudFormation resource.
	//
	// This value will resolve to one of the following:
	// - a concrete value (e.g. `"my-awesome-bucket"`)
	// - `undefined`, when a name should be generated by CloudFormation
	// - a concrete name generated automatically during synthesis, in
	//   cross-environment scenarios.
	PhysicalName() *string
	// The service Role of this Deployment Group.
	Role() awsiam.IRole
	// The stack in which this resource is defined.
	Stack() awscdk.Stack
	// Associates an additional alarm with this Deployment Group.
	AddAlarm(alarm awscloudwatch.IAlarm)
	// Apply the given removal policy to this resource.
	//
	// The Removal Policy controls what happens to this resource when it stops
	// being managed by CloudFormation, either because you've removed it from the
	// CDK application or because you've made a change that requires the resource
	// to be replaced.
	//
	// The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS
	// account for data recovery and cleanup later (`RemovalPolicy.RETAIN`).
	ApplyRemovalPolicy(policy awscdk.RemovalPolicy)
	GeneratePhysicalName() *string
	// Returns an environment-sensitive token that should be used for the resource's "ARN" attribute (e.g. `bucket.bucketArn`).
	//
	// Normally, this token will resolve to `arnAttr`, but if the resource is
	// referenced across environments, `arnComponents` will be used to synthesize
	// a concrete ARN with the resource's physical name. Make sure to reference
	// `this.physicalName` in `arnComponents`.
	GetResourceArnAttribute(arnAttr *string, arnComponents *awscdk.ArnComponents) *string
	// Returns an environment-sensitive token that should be used for the resource's "name" attribute (e.g. `bucket.bucketName`).
	//
	// Normally, this token will resolve to `nameAttr`, but if the resource is
	// referenced across environments, it will be resolved to `this.physicalName`,
	// which will be a concrete name.
	GetResourceNameAttribute(nameAttr *string) *string
	// Returns a string representation of this construct.
	ToString() *string
}

A CodeDeploy deployment group that orchestrates ECS blue-green deployments.

Example:

var myApplication ecsApplication
var cluster cluster
var taskDefinition fargateTaskDefinition
var blueTargetGroup iTargetGroup
var greenTargetGroup iTargetGroup
var listener iApplicationListener

service := ecs.NewFargateService(this, jsii.String("Service"), &FargateServiceProps{
	Cluster: Cluster,
	TaskDefinition: TaskDefinition,
	DeploymentController: &DeploymentController{
		Type: ecs.DeploymentControllerType_CODE_DEPLOY,
	},
})

codedeploy.NewEcsDeploymentGroup(this, jsii.String("BlueGreenDG"), &EcsDeploymentGroupProps{
	Service: Service,
	BlueGreenDeploymentConfig: &EcsBlueGreenDeploymentConfig{
		BlueTargetGroup: *BlueTargetGroup,
		GreenTargetGroup: *GreenTargetGroup,
		Listener: *Listener,
	},
	DeploymentConfig: codedeploy.EcsDeploymentConfig_CANARY_10PERCENT_5MINUTES(),
})

func NewEcsDeploymentGroup added in v2.50.0

func NewEcsDeploymentGroup(scope constructs.Construct, id *string, props *EcsDeploymentGroupProps) EcsDeploymentGroup

type EcsDeploymentGroupAttributes

type EcsDeploymentGroupAttributes struct {
	// The reference to the CodeDeploy ECS Application that this Deployment Group belongs to.
	Application IEcsApplication `field:"required" json:"application" yaml:"application"`
	// The physical, human-readable name of the CodeDeploy ECS Deployment Group that we are referencing.
	DeploymentGroupName *string `field:"required" json:"deploymentGroupName" yaml:"deploymentGroupName"`
	// The Deployment Configuration this Deployment Group uses.
	// Default: EcsDeploymentConfig.ALL_AT_ONCE
	//
	DeploymentConfig IEcsDeploymentConfig `field:"optional" json:"deploymentConfig" yaml:"deploymentConfig"`
}

Properties of a reference to a CodeDeploy ECS Deployment Group.

Example:

var application ecsApplication

deploymentGroup := codedeploy.EcsDeploymentGroup_FromEcsDeploymentGroupAttributes(this, jsii.String("ExistingCodeDeployDeploymentGroup"), &EcsDeploymentGroupAttributes{
	Application: Application,
	DeploymentGroupName: jsii.String("MyExistingDeploymentGroup"),
})

See: EcsDeploymentGroup#fromEcsDeploymentGroupAttributes.

type EcsDeploymentGroupProps added in v2.50.0

type EcsDeploymentGroupProps struct {
	// The configuration options for blue-green ECS deployments.
	BlueGreenDeploymentConfig *EcsBlueGreenDeploymentConfig `field:"required" json:"blueGreenDeploymentConfig" yaml:"blueGreenDeploymentConfig"`
	// The ECS service to deploy with this Deployment Group.
	Service awsecs.IBaseService `field:"required" json:"service" yaml:"service"`
	// 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.
	// See: https://docs.aws.amazon.com/codedeploy/latest/userguide/monitoring-create-alarms.html
	//
	// Default: [].
	//
	Alarms *[]awscloudwatch.IAlarm `field:"optional" json:"alarms" yaml:"alarms"`
	// The reference to the CodeDeploy ECS Application that this Deployment Group belongs to.
	// Default: One will be created for you.
	//
	Application IEcsApplication `field:"optional" json:"application" yaml:"application"`
	// The auto-rollback configuration for this Deployment Group.
	// Default: - default AutoRollbackConfig.
	//
	AutoRollback *AutoRollbackConfig `field:"optional" json:"autoRollback" yaml:"autoRollback"`
	// The Deployment Configuration this Deployment Group uses.
	// Default: EcsDeploymentConfig.ALL_AT_ONCE
	//
	DeploymentConfig IEcsDeploymentConfig `field:"optional" json:"deploymentConfig" yaml:"deploymentConfig"`
	// The physical, human-readable name of the CodeDeploy Deployment Group.
	// Default: An auto-generated name will be used.
	//
	DeploymentGroupName *string `field:"optional" json:"deploymentGroupName" yaml:"deploymentGroupName"`
	// Whether to skip the step of checking CloudWatch alarms during the deployment process.
	// Default: - false.
	//
	IgnoreAlarmConfiguration *bool `field:"optional" json:"ignoreAlarmConfiguration" yaml:"ignoreAlarmConfiguration"`
	// Whether to continue a deployment even if fetching the alarm status from CloudWatch failed.
	// Default: false.
	//
	IgnorePollAlarmsFailure *bool `field:"optional" json:"ignorePollAlarmsFailure" yaml:"ignorePollAlarmsFailure"`
	// The service Role of this Deployment Group.
	// Default: - A new Role will be created.
	//
	Role awsiam.IRole `field:"optional" json:"role" yaml:"role"`
}

Construction properties for `EcsDeploymentGroup`.

Example:

var myApplication ecsApplication
var cluster cluster
var taskDefinition fargateTaskDefinition
var blueTargetGroup iTargetGroup
var greenTargetGroup iTargetGroup
var listener iApplicationListener

service := ecs.NewFargateService(this, jsii.String("Service"), &FargateServiceProps{
	Cluster: Cluster,
	TaskDefinition: TaskDefinition,
	DeploymentController: &DeploymentController{
		Type: ecs.DeploymentControllerType_CODE_DEPLOY,
	},
})

codedeploy.NewEcsDeploymentGroup(this, jsii.String("BlueGreenDG"), &EcsDeploymentGroupProps{
	Service: Service,
	BlueGreenDeploymentConfig: &EcsBlueGreenDeploymentConfig{
		BlueTargetGroup: *BlueTargetGroup,
		GreenTargetGroup: *GreenTargetGroup,
		Listener: *Listener,
	},
	DeploymentConfig: codedeploy.EcsDeploymentConfig_CANARY_10PERCENT_5MINUTES(),
})

type IBaseDeploymentConfig added in v2.45.0

type IBaseDeploymentConfig interface {
	// The ARN of the Deployment Configuration.
	DeploymentConfigArn() *string
	// The physical, human-readable name of the Deployment Configuration.
	DeploymentConfigName() *string
}

The base class for ServerDeploymentConfig, EcsDeploymentConfig, and LambdaDeploymentConfig deployment configurations.

func BaseDeploymentConfig_FromDeploymentConfigName added in v2.45.0

func BaseDeploymentConfig_FromDeploymentConfigName(scope constructs.Construct, id *string, deploymentConfigName *string) IBaseDeploymentConfig

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

Returns: a Construct representing a reference to an existing custom Deployment Configuration.

func EcsDeploymentConfig_FromDeploymentConfigName added in v2.45.0

func EcsDeploymentConfig_FromDeploymentConfigName(scope constructs.Construct, id *string, deploymentConfigName *string) IBaseDeploymentConfig

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

Returns: a Construct representing a reference to an existing custom Deployment Configuration.

func LambdaDeploymentConfig_FromDeploymentConfigName added in v2.45.0

func LambdaDeploymentConfig_FromDeploymentConfigName(scope constructs.Construct, id *string, deploymentConfigName *string) IBaseDeploymentConfig

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

Returns: a Construct representing a reference to an existing custom Deployment Configuration.

func ServerDeploymentConfig_FromDeploymentConfigName added in v2.45.0

func ServerDeploymentConfig_FromDeploymentConfigName(scope constructs.Construct, id *string, deploymentConfigName *string) IBaseDeploymentConfig

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

Returns: a Construct representing a reference to an existing custom Deployment Configuration.

type IEcsApplication

type IEcsApplication interface {
	awscdk.IResource
	ApplicationArn() *string
	ApplicationName() *string
}

Represents a reference to a CodeDeploy Application deploying to Amazon ECS.

If you're managing the Application alongside the rest of your CDK resources, use the `EcsApplication` class.

If you want to reference an already existing Application, or one defined in a different CDK Stack, use the `EcsApplication#fromEcsApplicationName` method.

func EcsApplication_FromEcsApplicationArn added in v2.57.0

func EcsApplication_FromEcsApplicationArn(scope constructs.Construct, id *string, ecsApplicationArn *string) IEcsApplication

Import an Application defined either outside the CDK, or in a different CDK Stack, by ARN.

Returns: a Construct representing a reference to an existing Application.

func EcsApplication_FromEcsApplicationName

func EcsApplication_FromEcsApplicationName(scope constructs.Construct, id *string, ecsApplicationName *string) IEcsApplication

Import an Application defined either outside the CDK, or in a different CDK Stack.

The Application's account and region are assumed to be the same as the stack it is being imported into. If not, use `fromEcsApplicationArn`.

Returns: a Construct representing a reference to an existing Application.

type IEcsDeploymentConfig

type IEcsDeploymentConfig interface {
	IBaseDeploymentConfig
}

The Deployment Configuration of an ECS Deployment Group.

If you're managing the Deployment Configuration alongside the rest of your CDK resources, use the `EcsDeploymentConfig` class.

If you want to reference an already existing deployment configuration, or one defined in a different CDK Stack, use the `EcsDeploymentConfig#fromEcsDeploymentConfigName` method.

The default, pre-defined Configurations are available as constants on the `EcsDeploymentConfig` class (for example, `EcsDeploymentConfig.AllAtOnce`).

func EcsDeploymentConfig_ALL_AT_ONCE

func EcsDeploymentConfig_ALL_AT_ONCE() IEcsDeploymentConfig

func EcsDeploymentConfig_CANARY_10PERCENT_15MINUTES added in v2.45.0

func EcsDeploymentConfig_CANARY_10PERCENT_15MINUTES() IEcsDeploymentConfig

func EcsDeploymentConfig_CANARY_10PERCENT_5MINUTES added in v2.45.0

func EcsDeploymentConfig_CANARY_10PERCENT_5MINUTES() IEcsDeploymentConfig

func EcsDeploymentConfig_FromEcsDeploymentConfigName

func EcsDeploymentConfig_FromEcsDeploymentConfigName(scope constructs.Construct, id *string, ecsDeploymentConfigName *string) IEcsDeploymentConfig

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

Returns: a Construct representing a reference to an existing custom Deployment Configuration.

func EcsDeploymentConfig_LINEAR_10PERCENT_EVERY_1MINUTES added in v2.45.0

func EcsDeploymentConfig_LINEAR_10PERCENT_EVERY_1MINUTES() IEcsDeploymentConfig

func EcsDeploymentConfig_LINEAR_10PERCENT_EVERY_3MINUTES added in v2.45.0

func EcsDeploymentConfig_LINEAR_10PERCENT_EVERY_3MINUTES() IEcsDeploymentConfig

type IEcsDeploymentGroup

type IEcsDeploymentGroup interface {
	awscdk.IResource
	// The reference to the CodeDeploy ECS Application that this Deployment Group belongs to.
	Application() IEcsApplication
	// The Deployment Configuration this Group uses.
	DeploymentConfig() IEcsDeploymentConfig
	// The ARN of this Deployment Group.
	DeploymentGroupArn() *string
	// The physical name of the CodeDeploy Deployment Group.
	DeploymentGroupName() *string
}

Interface for an ECS deployment group.

func EcsDeploymentGroup_FromEcsDeploymentGroupAttributes

func EcsDeploymentGroup_FromEcsDeploymentGroupAttributes(scope constructs.Construct, id *string, attrs *EcsDeploymentGroupAttributes) IEcsDeploymentGroup

Reference an ECS Deployment Group defined outside the CDK app.

Account and region for the DeploymentGroup are taken from the application.

Returns: a Construct representing a reference to an existing Deployment Group.

type ILambdaApplication

type ILambdaApplication interface {
	awscdk.IResource
	ApplicationArn() *string
	ApplicationName() *string
}

Represents a reference to a CodeDeploy Application deploying to AWS Lambda.

If you're managing the Application alongside the rest of your CDK resources, use the `LambdaApplication` class.

If you want to reference an already existing Application, or one defined in a different CDK Stack, use the `LambdaApplication#fromLambdaApplicationName` method.

func LambdaApplication_FromLambdaApplicationArn added in v2.57.0

func LambdaApplication_FromLambdaApplicationArn(scope constructs.Construct, id *string, lambdaApplicationArn *string) ILambdaApplication

Import an Application defined either outside the CDK, or in a different CDK Stack, by ARN.

Returns: a Construct representing a reference to an existing Application.

func LambdaApplication_FromLambdaApplicationName

func LambdaApplication_FromLambdaApplicationName(scope constructs.Construct, id *string, lambdaApplicationName *string) ILambdaApplication

Import an Application defined either outside the CDK, or in a different CDK Stack.

The Application's account and region are assumed to be the same as the stack it is being imported into. If not, use `fromLambdaApplicationArn`.

Returns: a Construct representing a reference to an existing Application.

type ILambdaDeploymentConfig

type ILambdaDeploymentConfig interface {
	IBaseDeploymentConfig
}

The Deployment Configuration of a Lambda Deployment Group.

If you're managing the Deployment Configuration alongside the rest of your CDK resources, use the `LambdaDeploymentConfig` class.

If you want to reference an already existing deployment configuration, or one defined in a different CDK Stack, use the `LambdaDeploymentConfig#fromLambdaDeploymentConfigName` method.

The default, pre-defined Configurations are available as constants on the `LambdaDeploymentConfig` class (`LambdaDeploymentConfig.AllAtOnce`, `LambdaDeploymentConfig.Canary10Percent30Minutes`, etc.).

func LambdaDeploymentConfig_ALL_AT_ONCE

func LambdaDeploymentConfig_ALL_AT_ONCE() ILambdaDeploymentConfig

func LambdaDeploymentConfig_CANARY_10PERCENT_10MINUTES

func LambdaDeploymentConfig_CANARY_10PERCENT_10MINUTES() ILambdaDeploymentConfig

func LambdaDeploymentConfig_CANARY_10PERCENT_15MINUTES

func LambdaDeploymentConfig_CANARY_10PERCENT_15MINUTES() ILambdaDeploymentConfig

func LambdaDeploymentConfig_CANARY_10PERCENT_30MINUTES

func LambdaDeploymentConfig_CANARY_10PERCENT_30MINUTES() ILambdaDeploymentConfig

func LambdaDeploymentConfig_CANARY_10PERCENT_5MINUTES

func LambdaDeploymentConfig_CANARY_10PERCENT_5MINUTES() ILambdaDeploymentConfig

func LambdaDeploymentConfig_FromLambdaDeploymentConfigName added in v2.45.0

func LambdaDeploymentConfig_FromLambdaDeploymentConfigName(scope constructs.Construct, id *string, lambdaDeploymentConfigName *string) ILambdaDeploymentConfig

Import a Deployment Configuration for a Lambda Deployment Group defined outside the CDK.

Returns: a Construct representing a reference to an existing Lambda Deployment Configuration.

func LambdaDeploymentConfig_Import

func LambdaDeploymentConfig_Import(_scope constructs.Construct, _id *string, props *LambdaDeploymentConfigImportProps) ILambdaDeploymentConfig

Import a Deployment Configuration for a Lambda Deployment Group defined outside the CDK.

Returns: a Construct representing a reference to an existing custom Deployment Configuration. Deprecated: use `fromLambdaDeploymentConfigName`.

func LambdaDeploymentConfig_LINEAR_10PERCENT_EVERY_10MINUTES

func LambdaDeploymentConfig_LINEAR_10PERCENT_EVERY_10MINUTES() ILambdaDeploymentConfig

func LambdaDeploymentConfig_LINEAR_10PERCENT_EVERY_1MINUTE

func LambdaDeploymentConfig_LINEAR_10PERCENT_EVERY_1MINUTE() ILambdaDeploymentConfig

func LambdaDeploymentConfig_LINEAR_10PERCENT_EVERY_2MINUTES

func LambdaDeploymentConfig_LINEAR_10PERCENT_EVERY_2MINUTES() ILambdaDeploymentConfig

func LambdaDeploymentConfig_LINEAR_10PERCENT_EVERY_3MINUTES

func LambdaDeploymentConfig_LINEAR_10PERCENT_EVERY_3MINUTES() ILambdaDeploymentConfig

type ILambdaDeploymentGroup

type ILambdaDeploymentGroup interface {
	awscdk.IResource
	// The reference to the CodeDeploy Lambda Application that this Deployment Group belongs to.
	Application() ILambdaApplication
	// The Deployment Configuration this Group uses.
	DeploymentConfig() ILambdaDeploymentConfig
	// The ARN of this Deployment Group.
	DeploymentGroupArn() *string
	// The physical name of the CodeDeploy Deployment Group.
	DeploymentGroupName() *string
}

Interface for a Lambda deployment groups.

func LambdaDeploymentGroup_FromLambdaDeploymentGroupAttributes

func LambdaDeploymentGroup_FromLambdaDeploymentGroupAttributes(scope constructs.Construct, id *string, attrs *LambdaDeploymentGroupAttributes) ILambdaDeploymentGroup

Import an Lambda Deployment Group defined either outside the CDK app, or in a different AWS region.

Account and region for the DeploymentGroup are taken from the application.

Returns: a Construct representing a reference to an existing Deployment Group.

type IServerApplication

type IServerApplication interface {
	awscdk.IResource
	ApplicationArn() *string
	ApplicationName() *string
}

Represents a reference to a CodeDeploy Application deploying to EC2/on-premise instances.

If you're managing the Application alongside the rest of your CDK resources, use the `ServerApplication` class.

If you want to reference an already existing Application, or one defined in a different CDK Stack, use the `#fromServerApplicationName` method.

func ServerApplication_FromServerApplicationArn added in v2.57.0

func ServerApplication_FromServerApplicationArn(scope constructs.Construct, id *string, serverApplicationArn *string) IServerApplication

Import an Application defined either outside the CDK, or in a different CDK Stack, by ARN.

Returns: a Construct representing a reference to an existing Application.

func ServerApplication_FromServerApplicationName

func ServerApplication_FromServerApplicationName(scope constructs.Construct, id *string, serverApplicationName *string) IServerApplication

Import an Application defined either outside the CDK app, or in a different region.

The Application's account and region are assumed to be the same as the stack it is being imported into. If not, use `fromServerApplicationArn`.

Returns: a Construct representing a reference to an existing Application.

type IServerDeploymentConfig

type IServerDeploymentConfig interface {
	IBaseDeploymentConfig
}

The Deployment Configuration of an EC2/on-premise Deployment Group.

The default, pre-defined Configurations are available as constants on the `ServerDeploymentConfig` class (`ServerDeploymentConfig.HALF_AT_A_TIME`, `ServerDeploymentConfig.ALL_AT_ONCE`, etc.). To create a custom Deployment Configuration, instantiate the `ServerDeploymentConfig` Construct.

func ServerDeploymentConfig_ALL_AT_ONCE

func ServerDeploymentConfig_ALL_AT_ONCE() IServerDeploymentConfig

func ServerDeploymentConfig_FromServerDeploymentConfigName

func ServerDeploymentConfig_FromServerDeploymentConfigName(scope constructs.Construct, id *string, serverDeploymentConfigName *string) IServerDeploymentConfig

Import a custom Deployment Configuration for an EC2/on-premise Deployment Group defined either outside the CDK app, or in a different region.

Returns: a Construct representing a reference to an existing custom Deployment Configuration.

func ServerDeploymentConfig_HALF_AT_A_TIME

func ServerDeploymentConfig_HALF_AT_A_TIME() IServerDeploymentConfig

func ServerDeploymentConfig_ONE_AT_A_TIME

func ServerDeploymentConfig_ONE_AT_A_TIME() IServerDeploymentConfig

type IServerDeploymentGroup

type IServerDeploymentGroup interface {
	awscdk.IResource
	Application() IServerApplication
	AutoScalingGroups() *[]awsautoscaling.IAutoScalingGroup
	DeploymentConfig() IServerDeploymentConfig
	DeploymentGroupArn() *string
	DeploymentGroupName() *string
	Role() awsiam.IRole
}

func ServerDeploymentGroup_FromServerDeploymentGroupAttributes

func ServerDeploymentGroup_FromServerDeploymentGroupAttributes(scope constructs.Construct, id *string, attrs *ServerDeploymentGroupAttributes) IServerDeploymentGroup

Import an EC2/on-premise Deployment Group defined either outside the CDK app, or in a different region.

Returns: a Construct representing a reference to an existing Deployment Group.

type InstanceTagSet

type InstanceTagSet interface {
	InstanceTagGroups() *[]*map[string]*[]*string
}

Represents a set of instance tag groups.

An instance will match a set if it matches all of the groups in the set - in other words, sets follow 'and' semantics. You can have a maximum of 3 tag groups inside a set.

Example:

import autoscaling "github.com/aws/aws-cdk-go/awscdk"
import cloudwatch "github.com/aws/aws-cdk-go/awscdk"

var application serverApplication
var asg autoScalingGroup
var alarm alarm

deploymentGroup := codedeploy.NewServerDeploymentGroup(this, jsii.String("CodeDeployDeploymentGroup"), &ServerDeploymentGroupProps{
	Application: Application,
	DeploymentGroupName: jsii.String("MyDeploymentGroup"),
	AutoScalingGroups: []iAutoScalingGroup{
		asg,
	},
	// adds User Data that installs the CodeDeploy agent on your auto-scaling groups hosts
	// default: true
	InstallAgent: jsii.Boolean(true),
	// adds EC2 instances matching tags
	Ec2InstanceTags: codedeploy.NewInstanceTagSet(map[string][]*string{
		// any instance with tags satisfying
		// key1=v1 or key1=v2 or key2 (any value) or value v3 (any key)
		// will match this group
		"key1": []*string{
			jsii.String("v1"),
			jsii.String("v2"),
		},
		"key2": []*string{
		},
		"": []*string{
			jsii.String("v3"),
		},
	}),
	// adds on-premise instances matching tags
	OnPremiseInstanceTags: codedeploy.NewInstanceTagSet(map[string][]*string{
		"key1": []*string{
			jsii.String("v1"),
			jsii.String("v2"),
		},
	}, map[string][]*string{
		"key2": []*string{
			jsii.String("v3"),
		},
	}),
	// CloudWatch alarms
	Alarms: []iAlarm{
		alarm,
	},
	// whether to ignore failure to fetch the status of alarms from CloudWatch
	// default: false
	IgnorePollAlarmsFailure: jsii.Boolean(false),
	// whether to skip the step of checking CloudWatch alarms during the deployment process
	// default: false
	IgnoreAlarmConfiguration: jsii.Boolean(false),
	// auto-rollback configuration
	AutoRollback: &AutoRollbackConfig{
		FailedDeployment: jsii.Boolean(true),
		 // default: true
		StoppedDeployment: jsii.Boolean(true),
		 // default: false
		DeploymentInAlarm: jsii.Boolean(true),
	},
})

func NewInstanceTagSet

func NewInstanceTagSet(instanceTagGroups ...*map[string]*[]*string) InstanceTagSet

type LambdaApplication

type LambdaApplication interface {
	awscdk.Resource
	ILambdaApplication
	ApplicationArn() *string
	ApplicationName() *string
	// The environment this resource belongs to.
	//
	// For resources that are created and managed by the CDK
	// (generally, those created by creating new class instances like Role, Bucket, etc.),
	// this is always the same as the environment of the stack they belong to;
	// however, for imported resources
	// (those obtained from static methods like fromRoleArn, fromBucketName, etc.),
	// that might be different than the stack they were imported into.
	Env() *awscdk.ResourceEnvironment
	// The tree node.
	Node() constructs.Node
	// Returns a string-encoded token that resolves to the physical name that should be passed to the CloudFormation resource.
	//
	// This value will resolve to one of the following:
	// - a concrete value (e.g. `"my-awesome-bucket"`)
	// - `undefined`, when a name should be generated by CloudFormation
	// - a concrete name generated automatically during synthesis, in
	//   cross-environment scenarios.
	PhysicalName() *string
	// The stack in which this resource is defined.
	Stack() awscdk.Stack
	// Apply the given removal policy to this resource.
	//
	// The Removal Policy controls what happens to this resource when it stops
	// being managed by CloudFormation, either because you've removed it from the
	// CDK application or because you've made a change that requires the resource
	// to be replaced.
	//
	// The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS
	// account for data recovery and cleanup later (`RemovalPolicy.RETAIN`).
	ApplyRemovalPolicy(policy awscdk.RemovalPolicy)
	GeneratePhysicalName() *string
	// Returns an environment-sensitive token that should be used for the resource's "ARN" attribute (e.g. `bucket.bucketArn`).
	//
	// Normally, this token will resolve to `arnAttr`, but if the resource is
	// referenced across environments, `arnComponents` will be used to synthesize
	// a concrete ARN with the resource's physical name. Make sure to reference
	// `this.physicalName` in `arnComponents`.
	GetResourceArnAttribute(arnAttr *string, arnComponents *awscdk.ArnComponents) *string
	// Returns an environment-sensitive token that should be used for the resource's "name" attribute (e.g. `bucket.bucketName`).
	//
	// Normally, this token will resolve to `nameAttr`, but if the resource is
	// referenced across environments, it will be resolved to `this.physicalName`,
	// which will be a concrete name.
	GetResourceNameAttribute(nameAttr *string) *string
	// Returns a string representation of this construct.
	ToString() *string
}

A CodeDeploy Application that deploys to an AWS Lambda function.

Example:

application := codedeploy.NewLambdaApplication(this, jsii.String("CodeDeployApplication"), &LambdaApplicationProps{
	ApplicationName: jsii.String("MyApplication"),
})

func NewLambdaApplication

func NewLambdaApplication(scope constructs.Construct, id *string, props *LambdaApplicationProps) LambdaApplication

type LambdaApplicationProps

type LambdaApplicationProps struct {
	// The physical, human-readable name of the CodeDeploy Application.
	// Default: an auto-generated name will be used.
	//
	ApplicationName *string `field:"optional" json:"applicationName" yaml:"applicationName"`
}

Construction properties for `LambdaApplication`.

Example:

application := codedeploy.NewLambdaApplication(this, jsii.String("CodeDeployApplication"), &LambdaApplicationProps{
	ApplicationName: jsii.String("MyApplication"),
})

type LambdaDeploymentConfig

type LambdaDeploymentConfig interface {
	BaseDeploymentConfig
	ILambdaDeploymentConfig
	// The arn of the deployment config.
	DeploymentConfigArn() *string
	// The name of the deployment config.
	DeploymentConfigName() *string
	// The environment this resource belongs to.
	//
	// For resources that are created and managed by the CDK
	// (generally, those created by creating new class instances like Role, Bucket, etc.),
	// this is always the same as the environment of the stack they belong to;
	// however, for imported resources
	// (those obtained from static methods like fromRoleArn, fromBucketName, etc.),
	// that might be different than the stack they were imported into.
	Env() *awscdk.ResourceEnvironment
	// The tree node.
	Node() constructs.Node
	// Returns a string-encoded token that resolves to the physical name that should be passed to the CloudFormation resource.
	//
	// This value will resolve to one of the following:
	// - a concrete value (e.g. `"my-awesome-bucket"`)
	// - `undefined`, when a name should be generated by CloudFormation
	// - a concrete name generated automatically during synthesis, in
	//   cross-environment scenarios.
	PhysicalName() *string
	// The stack in which this resource is defined.
	Stack() awscdk.Stack
	// Apply the given removal policy to this resource.
	//
	// The Removal Policy controls what happens to this resource when it stops
	// being managed by CloudFormation, either because you've removed it from the
	// CDK application or because you've made a change that requires the resource
	// to be replaced.
	//
	// The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS
	// account for data recovery and cleanup later (`RemovalPolicy.RETAIN`).
	ApplyRemovalPolicy(policy awscdk.RemovalPolicy)
	GeneratePhysicalName() *string
	// Returns an environment-sensitive token that should be used for the resource's "ARN" attribute (e.g. `bucket.bucketArn`).
	//
	// Normally, this token will resolve to `arnAttr`, but if the resource is
	// referenced across environments, `arnComponents` will be used to synthesize
	// a concrete ARN with the resource's physical name. Make sure to reference
	// `this.physicalName` in `arnComponents`.
	GetResourceArnAttribute(arnAttr *string, arnComponents *awscdk.ArnComponents) *string
	// Returns an environment-sensitive token that should be used for the resource's "name" attribute (e.g. `bucket.bucketName`).
	//
	// Normally, this token will resolve to `nameAttr`, but if the resource is
	// referenced across environments, it will be resolved to `this.physicalName`,
	// which will be a concrete name.
	GetResourceNameAttribute(nameAttr *string) *string
	// Returns a string representation of this construct.
	ToString() *string
}

A custom Deployment Configuration for a Lambda Deployment Group.

Example:

var application lambdaApplication
var alias alias
config := codedeploy.NewLambdaDeploymentConfig(this, jsii.String("CustomConfig"), &LambdaDeploymentConfigProps{
	TrafficRouting: codedeploy.NewTimeBasedCanaryTrafficRouting(&TimeBasedCanaryTrafficRoutingProps{
		Interval: awscdk.Duration_Minutes(jsii.Number(15)),
		Percentage: jsii.Number(5),
	}),
})
deploymentGroup := codedeploy.NewLambdaDeploymentGroup(this, jsii.String("BlueGreenDeployment"), &LambdaDeploymentGroupProps{
	Application: Application,
	Alias: Alias,
	DeploymentConfig: config,
})

func NewLambdaDeploymentConfig added in v2.45.0

func NewLambdaDeploymentConfig(scope constructs.Construct, id *string, props *LambdaDeploymentConfigProps) LambdaDeploymentConfig

type LambdaDeploymentConfigImportProps

type LambdaDeploymentConfigImportProps struct {
	// The physical, human-readable name of the custom CodeDeploy Lambda Deployment Configuration that we are referencing.
	DeploymentConfigName *string `field:"required" json:"deploymentConfigName" yaml:"deploymentConfigName"`
}

Properties of a reference to a CodeDeploy Lambda Deployment Configuration.

Example:

// 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"

lambdaDeploymentConfigImportProps := &LambdaDeploymentConfigImportProps{
	DeploymentConfigName: jsii.String("deploymentConfigName"),
}

See: LambdaDeploymentConfig# import.

type LambdaDeploymentConfigProps added in v2.45.0

type LambdaDeploymentConfigProps struct {
	// The physical, human-readable name of the Deployment Configuration.
	// Default: - automatically generated name.
	//
	DeploymentConfigName *string `field:"optional" json:"deploymentConfigName" yaml:"deploymentConfigName"`
	// The configuration that specifies how traffic is shifted from the 'blue' target group to the 'green' target group during a deployment.
	// Default: AllAtOnce.
	//
	TrafficRouting TrafficRouting `field:"optional" json:"trafficRouting" yaml:"trafficRouting"`
}

Construction properties of `LambdaDeploymentConfig`.

Example:

var application lambdaApplication
var alias alias
config := codedeploy.NewLambdaDeploymentConfig(this, jsii.String("CustomConfig"), &LambdaDeploymentConfigProps{
	TrafficRouting: codedeploy.NewTimeBasedCanaryTrafficRouting(&TimeBasedCanaryTrafficRoutingProps{
		Interval: awscdk.Duration_Minutes(jsii.Number(15)),
		Percentage: jsii.Number(5),
	}),
})
deploymentGroup := codedeploy.NewLambdaDeploymentGroup(this, jsii.String("BlueGreenDeployment"), &LambdaDeploymentGroupProps{
	Application: Application,
	Alias: Alias,
	DeploymentConfig: config,
})

type LambdaDeploymentGroup

type LambdaDeploymentGroup interface {
	awscdk.Resource
	ILambdaDeploymentGroup
	// The reference to the CodeDeploy Lambda Application that this Deployment Group belongs to.
	Application() ILambdaApplication
	// The Deployment Configuration this Group uses.
	DeploymentConfig() ILambdaDeploymentConfig
	// The ARN of the Deployment Group.
	DeploymentGroupArn() *string
	// The name of the Deployment Group.
	DeploymentGroupName() *string
	// The environment this resource belongs to.
	//
	// For resources that are created and managed by the CDK
	// (generally, those created by creating new class instances like Role, Bucket, etc.),
	// this is always the same as the environment of the stack they belong to;
	// however, for imported resources
	// (those obtained from static methods like fromRoleArn, fromBucketName, etc.),
	// that might be different than the stack they were imported into.
	Env() *awscdk.ResourceEnvironment
	// The tree node.
	Node() constructs.Node
	// Returns a string-encoded token that resolves to the physical name that should be passed to the CloudFormation resource.
	//
	// This value will resolve to one of the following:
	// - a concrete value (e.g. `"my-awesome-bucket"`)
	// - `undefined`, when a name should be generated by CloudFormation
	// - a concrete name generated automatically during synthesis, in
	//   cross-environment scenarios.
	PhysicalName() *string
	// The service Role of this Deployment Group.
	Role() awsiam.IRole
	// The stack in which this resource is defined.
	Stack() awscdk.Stack
	// Associates an additional alarm with this Deployment Group.
	AddAlarm(alarm awscloudwatch.IAlarm)
	// Associate a function to run after deployment completes.
	AddPostHook(postHook awslambda.IFunction)
	// Associate a function to run before deployment begins.
	AddPreHook(preHook awslambda.IFunction)
	// Apply the given removal policy to this resource.
	//
	// The Removal Policy controls what happens to this resource when it stops
	// being managed by CloudFormation, either because you've removed it from the
	// CDK application or because you've made a change that requires the resource
	// to be replaced.
	//
	// The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS
	// account for data recovery and cleanup later (`RemovalPolicy.RETAIN`).
	ApplyRemovalPolicy(policy awscdk.RemovalPolicy)
	GeneratePhysicalName() *string
	// Returns an environment-sensitive token that should be used for the resource's "ARN" attribute (e.g. `bucket.bucketArn`).
	//
	// Normally, this token will resolve to `arnAttr`, but if the resource is
	// referenced across environments, `arnComponents` will be used to synthesize
	// a concrete ARN with the resource's physical name. Make sure to reference
	// `this.physicalName` in `arnComponents`.
	GetResourceArnAttribute(arnAttr *string, arnComponents *awscdk.ArnComponents) *string
	// Returns an environment-sensitive token that should be used for the resource's "name" attribute (e.g. `bucket.bucketName`).
	//
	// Normally, this token will resolve to `nameAttr`, but if the resource is
	// referenced across environments, it will be resolved to `this.physicalName`,
	// which will be a concrete name.
	GetResourceNameAttribute(nameAttr *string) *string
	// Grant a principal permission to codedeploy:PutLifecycleEventHookExecutionStatus on this deployment group resource.
	GrantPutLifecycleEventHookExecutionStatus(grantee awsiam.IGrantable) awsiam.Grant
	// Returns a string representation of this construct.
	ToString() *string
}

Example:

var application lambdaApplication
var alias alias
config := codedeploy.NewLambdaDeploymentConfig(this, jsii.String("CustomConfig"), &LambdaDeploymentConfigProps{
	TrafficRouting: codedeploy.NewTimeBasedCanaryTrafficRouting(&TimeBasedCanaryTrafficRoutingProps{
		Interval: awscdk.Duration_Minutes(jsii.Number(15)),
		Percentage: jsii.Number(5),
	}),
})
deploymentGroup := codedeploy.NewLambdaDeploymentGroup(this, jsii.String("BlueGreenDeployment"), &LambdaDeploymentGroupProps{
	Application: Application,
	Alias: Alias,
	DeploymentConfig: config,
})

func NewLambdaDeploymentGroup

func NewLambdaDeploymentGroup(scope constructs.Construct, id *string, props *LambdaDeploymentGroupProps) LambdaDeploymentGroup

type LambdaDeploymentGroupAttributes

type LambdaDeploymentGroupAttributes struct {
	// The reference to the CodeDeploy Lambda Application that this Deployment Group belongs to.
	Application ILambdaApplication `field:"required" json:"application" yaml:"application"`
	// The physical, human-readable name of the CodeDeploy Lambda Deployment Group that we are referencing.
	DeploymentGroupName *string `field:"required" json:"deploymentGroupName" yaml:"deploymentGroupName"`
	// The Deployment Configuration this Deployment Group uses.
	// Default: LambdaDeploymentConfig.CANARY_10PERCENT_5MINUTES
	//
	DeploymentConfig ILambdaDeploymentConfig `field:"optional" json:"deploymentConfig" yaml:"deploymentConfig"`
}

Properties of a reference to a CodeDeploy Lambda Deployment Group.

Example:

var application lambdaApplication

deploymentGroup := codedeploy.LambdaDeploymentGroup_FromLambdaDeploymentGroupAttributes(this, jsii.String("ExistingCodeDeployDeploymentGroup"), &LambdaDeploymentGroupAttributes{
	Application: Application,
	DeploymentGroupName: jsii.String("MyExistingDeploymentGroup"),
})

See: LambdaDeploymentGroup#fromLambdaDeploymentGroupAttributes.

type LambdaDeploymentGroupProps

type LambdaDeploymentGroupProps struct {
	// Lambda Alias to shift traffic. Updating the version of the alias will trigger a CodeDeploy deployment.
	//
	// [disable-awslint:ref-via-interface] since we need to modify the alias CFN resource update policy.
	Alias awslambda.Alias `field:"required" json:"alias" yaml:"alias"`
	// 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.
	// See: https://docs.aws.amazon.com/codedeploy/latest/userguide/monitoring-create-alarms.html
	//
	// Default: [].
	//
	Alarms *[]awscloudwatch.IAlarm `field:"optional" json:"alarms" yaml:"alarms"`
	// The reference to the CodeDeploy Lambda Application that this Deployment Group belongs to.
	// Default: - One will be created for you.
	//
	Application ILambdaApplication `field:"optional" json:"application" yaml:"application"`
	// The auto-rollback configuration for this Deployment Group.
	// Default: - default AutoRollbackConfig.
	//
	AutoRollback *AutoRollbackConfig `field:"optional" json:"autoRollback" yaml:"autoRollback"`
	// The Deployment Configuration this Deployment Group uses.
	// Default: LambdaDeploymentConfig.CANARY_10PERCENT_5MINUTES
	//
	DeploymentConfig ILambdaDeploymentConfig `field:"optional" json:"deploymentConfig" yaml:"deploymentConfig"`
	// The physical, human-readable name of the CodeDeploy Deployment Group.
	// Default: - An auto-generated name will be used.
	//
	DeploymentGroupName *string `field:"optional" json:"deploymentGroupName" yaml:"deploymentGroupName"`
	// Whether to skip the step of checking CloudWatch alarms during the deployment process.
	// Default: - false.
	//
	IgnoreAlarmConfiguration *bool `field:"optional" json:"ignoreAlarmConfiguration" yaml:"ignoreAlarmConfiguration"`
	// Whether to continue a deployment even if fetching the alarm status from CloudWatch failed.
	// Default: false.
	//
	IgnorePollAlarmsFailure *bool `field:"optional" json:"ignorePollAlarmsFailure" yaml:"ignorePollAlarmsFailure"`
	// The Lambda function to run after traffic routing starts.
	// Default: - None.
	//
	PostHook awslambda.IFunction `field:"optional" json:"postHook" yaml:"postHook"`
	// The Lambda function to run before traffic routing starts.
	// Default: - None.
	//
	PreHook awslambda.IFunction `field:"optional" json:"preHook" yaml:"preHook"`
	// The service Role of this Deployment Group.
	// Default: - A new Role will be created.
	//
	Role awsiam.IRole `field:"optional" json:"role" yaml:"role"`
}

Construction properties for `LambdaDeploymentGroup`.

Example:

var myApplication lambdaApplication
var func function

version := func.currentVersion
version1Alias := lambda.NewAlias(this, jsii.String("alias"), &AliasProps{
	AliasName: jsii.String("prod"),
	Version: Version,
})

deploymentGroup := codedeploy.NewLambdaDeploymentGroup(this, jsii.String("BlueGreenDeployment"), &LambdaDeploymentGroupProps{
	Application: myApplication,
	 // optional property: one will be created for you if not provided
	Alias: version1Alias,
	DeploymentConfig: codedeploy.LambdaDeploymentConfig_LINEAR_10PERCENT_EVERY_1MINUTE(),
})

type LinearTrafficRoutingConfig added in v2.45.0

type LinearTrafficRoutingConfig struct {
	// The number of minutes between each incremental traffic shift of a `TimeBasedLinear` deployment.
	LinearInterval *float64 `field:"required" json:"linearInterval" yaml:"linearInterval"`
	// The percentage of traffic that is shifted at the start of each increment of a `TimeBasedLinear` deployment.
	LinearPercentage *float64 `field:"required" json:"linearPercentage" yaml:"linearPercentage"`
}

Represents the configuration specific to linear traffic shifting.

Example:

// 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"

linearTrafficRoutingConfig := &LinearTrafficRoutingConfig{
	LinearInterval: jsii.Number(123),
	LinearPercentage: jsii.Number(123),
}

type LoadBalancer

type LoadBalancer interface {
	Generation() LoadBalancerGeneration
	Name() *string
}

An interface of an abstract load balancer, as needed by CodeDeploy.

Create instances using the static factory methods: `#classic`, `#application` and `#network`.

Example:

var alb applicationLoadBalancer

listener := alb.AddListener(jsii.String("Listener"), &BaseApplicationListenerProps{
	Port: jsii.Number(80),
})
targetGroup := listener.AddTargets(jsii.String("Fleet"), &AddApplicationTargetsProps{
	Port: jsii.Number(80),
})

deploymentGroup := codedeploy.NewServerDeploymentGroup(this, jsii.String("DeploymentGroup"), &ServerDeploymentGroupProps{
	LoadBalancer: codedeploy.LoadBalancer_Application(targetGroup),
})

func LoadBalancer_Application

func LoadBalancer_Application(albTargetGroup awselasticloadbalancingv2.IApplicationTargetGroup) LoadBalancer

Creates a new CodeDeploy load balancer from an Application Load Balancer Target Group.

func LoadBalancer_Classic

func LoadBalancer_Classic(loadBalancer awselasticloadbalancing.LoadBalancer) LoadBalancer

Creates a new CodeDeploy load balancer from a Classic ELB Load Balancer.

func LoadBalancer_Network

func LoadBalancer_Network(nlbTargetGroup awselasticloadbalancingv2.INetworkTargetGroup) LoadBalancer

Creates a new CodeDeploy load balancer from a Network Load Balancer Target Group.

type LoadBalancerGeneration

type LoadBalancerGeneration string

The generations of AWS load balancing solutions.

const (
	// The first generation (ELB Classic).
	LoadBalancerGeneration_FIRST LoadBalancerGeneration = "FIRST"
	// The second generation (ALB and NLB).
	LoadBalancerGeneration_SECOND LoadBalancerGeneration = "SECOND"
)

type MinimumHealthyHosts

type MinimumHealthyHosts interface {
}

Minimum number of healthy hosts for a server deployment.

Example:

deploymentConfig := codedeploy.NewServerDeploymentConfig(this, jsii.String("DeploymentConfiguration"), &ServerDeploymentConfigProps{
	DeploymentConfigName: jsii.String("MyDeploymentConfiguration"),
	 // optional property
	// one of these is required, but both cannot be specified at the same time
	MinimumHealthyHosts: codedeploy.MinimumHealthyHosts_Count(jsii.Number(2)),
})

func MinimumHealthyHosts_Count

func MinimumHealthyHosts_Count(value *float64) MinimumHealthyHosts

The minimum healhty hosts threshold expressed as an absolute number.

func MinimumHealthyHosts_Percentage

func MinimumHealthyHosts_Percentage(value *float64) MinimumHealthyHosts

The minmum healhty hosts threshold expressed as a percentage of the fleet.

type ServerApplication

type ServerApplication interface {
	awscdk.Resource
	IServerApplication
	ApplicationArn() *string
	ApplicationName() *string
	// The environment this resource belongs to.
	//
	// For resources that are created and managed by the CDK
	// (generally, those created by creating new class instances like Role, Bucket, etc.),
	// this is always the same as the environment of the stack they belong to;
	// however, for imported resources
	// (those obtained from static methods like fromRoleArn, fromBucketName, etc.),
	// that might be different than the stack they were imported into.
	Env() *awscdk.ResourceEnvironment
	// The tree node.
	Node() constructs.Node
	// Returns a string-encoded token that resolves to the physical name that should be passed to the CloudFormation resource.
	//
	// This value will resolve to one of the following:
	// - a concrete value (e.g. `"my-awesome-bucket"`)
	// - `undefined`, when a name should be generated by CloudFormation
	// - a concrete name generated automatically during synthesis, in
	//   cross-environment scenarios.
	PhysicalName() *string
	// The stack in which this resource is defined.
	Stack() awscdk.Stack
	// Apply the given removal policy to this resource.
	//
	// The Removal Policy controls what happens to this resource when it stops
	// being managed by CloudFormation, either because you've removed it from the
	// CDK application or because you've made a change that requires the resource
	// to be replaced.
	//
	// The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS
	// account for data recovery and cleanup later (`RemovalPolicy.RETAIN`).
	ApplyRemovalPolicy(policy awscdk.RemovalPolicy)
	GeneratePhysicalName() *string
	// Returns an environment-sensitive token that should be used for the resource's "ARN" attribute (e.g. `bucket.bucketArn`).
	//
	// Normally, this token will resolve to `arnAttr`, but if the resource is
	// referenced across environments, `arnComponents` will be used to synthesize
	// a concrete ARN with the resource's physical name. Make sure to reference
	// `this.physicalName` in `arnComponents`.
	GetResourceArnAttribute(arnAttr *string, arnComponents *awscdk.ArnComponents) *string
	// Returns an environment-sensitive token that should be used for the resource's "name" attribute (e.g. `bucket.bucketName`).
	//
	// Normally, this token will resolve to `nameAttr`, but if the resource is
	// referenced across environments, it will be resolved to `this.physicalName`,
	// which will be a concrete name.
	GetResourceNameAttribute(nameAttr *string) *string
	// Returns a string representation of this construct.
	ToString() *string
}

A CodeDeploy Application that deploys to EC2/on-premise instances.

Example:

application := codedeploy.NewServerApplication(this, jsii.String("CodeDeployApplication"), &ServerApplicationProps{
	ApplicationName: jsii.String("MyApplication"),
})

func NewServerApplication

func NewServerApplication(scope constructs.Construct, id *string, props *ServerApplicationProps) ServerApplication

type ServerApplicationProps

type ServerApplicationProps struct {
	// The physical, human-readable name of the CodeDeploy Application.
	// Default: an auto-generated name will be used.
	//
	ApplicationName *string `field:"optional" json:"applicationName" yaml:"applicationName"`
}

Construction properties for `ServerApplication`.

Example:

application := codedeploy.NewServerApplication(this, jsii.String("CodeDeployApplication"), &ServerApplicationProps{
	ApplicationName: jsii.String("MyApplication"),
})

type ServerDeploymentConfig

type ServerDeploymentConfig interface {
	BaseDeploymentConfig
	IServerDeploymentConfig
	// The arn of the deployment config.
	DeploymentConfigArn() *string
	// The name of the deployment config.
	DeploymentConfigName() *string
	// The environment this resource belongs to.
	//
	// For resources that are created and managed by the CDK
	// (generally, those created by creating new class instances like Role, Bucket, etc.),
	// this is always the same as the environment of the stack they belong to;
	// however, for imported resources
	// (those obtained from static methods like fromRoleArn, fromBucketName, etc.),
	// that might be different than the stack they were imported into.
	Env() *awscdk.ResourceEnvironment
	// The tree node.
	Node() constructs.Node
	// Returns a string-encoded token that resolves to the physical name that should be passed to the CloudFormation resource.
	//
	// This value will resolve to one of the following:
	// - a concrete value (e.g. `"my-awesome-bucket"`)
	// - `undefined`, when a name should be generated by CloudFormation
	// - a concrete name generated automatically during synthesis, in
	//   cross-environment scenarios.
	PhysicalName() *string
	// The stack in which this resource is defined.
	Stack() awscdk.Stack
	// Apply the given removal policy to this resource.
	//
	// The Removal Policy controls what happens to this resource when it stops
	// being managed by CloudFormation, either because you've removed it from the
	// CDK application or because you've made a change that requires the resource
	// to be replaced.
	//
	// The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS
	// account for data recovery and cleanup later (`RemovalPolicy.RETAIN`).
	ApplyRemovalPolicy(policy awscdk.RemovalPolicy)
	GeneratePhysicalName() *string
	// Returns an environment-sensitive token that should be used for the resource's "ARN" attribute (e.g. `bucket.bucketArn`).
	//
	// Normally, this token will resolve to `arnAttr`, but if the resource is
	// referenced across environments, `arnComponents` will be used to synthesize
	// a concrete ARN with the resource's physical name. Make sure to reference
	// `this.physicalName` in `arnComponents`.
	GetResourceArnAttribute(arnAttr *string, arnComponents *awscdk.ArnComponents) *string
	// Returns an environment-sensitive token that should be used for the resource's "name" attribute (e.g. `bucket.bucketName`).
	//
	// Normally, this token will resolve to `nameAttr`, but if the resource is
	// referenced across environments, it will be resolved to `this.physicalName`,
	// which will be a concrete name.
	GetResourceNameAttribute(nameAttr *string) *string
	// Returns a string representation of this construct.
	ToString() *string
}

A custom Deployment Configuration for an EC2/on-premise Deployment Group.

Example:

deploymentGroup := codedeploy.NewServerDeploymentGroup(this, jsii.String("CodeDeployDeploymentGroup"), &ServerDeploymentGroupProps{
	DeploymentConfig: codedeploy.ServerDeploymentConfig_ALL_AT_ONCE(),
})

func NewServerDeploymentConfig

func NewServerDeploymentConfig(scope constructs.Construct, id *string, props *ServerDeploymentConfigProps) ServerDeploymentConfig

type ServerDeploymentConfigProps

type ServerDeploymentConfigProps struct {
	// The physical, human-readable name of the Deployment Configuration.
	// Default: - automatically generated name.
	//
	DeploymentConfigName *string `field:"optional" json:"deploymentConfigName" yaml:"deploymentConfigName"`
	// Minimum number of healthy hosts.
	MinimumHealthyHosts MinimumHealthyHosts `field:"required" json:"minimumHealthyHosts" yaml:"minimumHealthyHosts"`
}

Construction properties of `ServerDeploymentConfig`.

Example:

deploymentConfig := codedeploy.NewServerDeploymentConfig(this, jsii.String("DeploymentConfiguration"), &ServerDeploymentConfigProps{
	DeploymentConfigName: jsii.String("MyDeploymentConfiguration"),
	 // optional property
	// one of these is required, but both cannot be specified at the same time
	MinimumHealthyHosts: codedeploy.MinimumHealthyHosts_Count(jsii.Number(2)),
})

type ServerDeploymentGroup

type ServerDeploymentGroup interface {
	awscdk.Resource
	IServerDeploymentGroup
	Application() IServerApplication
	AutoScalingGroups() *[]awsautoscaling.IAutoScalingGroup
	DeploymentConfig() IServerDeploymentConfig
	// The ARN of the Deployment Group.
	DeploymentGroupArn() *string
	// The name of the Deployment Group.
	DeploymentGroupName() *string
	// The environment this resource belongs to.
	//
	// For resources that are created and managed by the CDK
	// (generally, those created by creating new class instances like Role, Bucket, etc.),
	// this is always the same as the environment of the stack they belong to;
	// however, for imported resources
	// (those obtained from static methods like fromRoleArn, fromBucketName, etc.),
	// that might be different than the stack they were imported into.
	Env() *awscdk.ResourceEnvironment
	// The tree node.
	Node() constructs.Node
	// Returns a string-encoded token that resolves to the physical name that should be passed to the CloudFormation resource.
	//
	// This value will resolve to one of the following:
	// - a concrete value (e.g. `"my-awesome-bucket"`)
	// - `undefined`, when a name should be generated by CloudFormation
	// - a concrete name generated automatically during synthesis, in
	//   cross-environment scenarios.
	PhysicalName() *string
	// The service Role of this Deployment Group.
	Role() awsiam.IRole
	// The stack in which this resource is defined.
	Stack() awscdk.Stack
	// Associates an additional alarm with this Deployment Group.
	AddAlarm(alarm awscloudwatch.IAlarm)
	// Adds an additional auto-scaling group to this Deployment Group.
	AddAutoScalingGroup(asg awsautoscaling.AutoScalingGroup)
	// Apply the given removal policy to this resource.
	//
	// The Removal Policy controls what happens to this resource when it stops
	// being managed by CloudFormation, either because you've removed it from the
	// CDK application or because you've made a change that requires the resource
	// to be replaced.
	//
	// The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS
	// account for data recovery and cleanup later (`RemovalPolicy.RETAIN`).
	ApplyRemovalPolicy(policy awscdk.RemovalPolicy)
	GeneratePhysicalName() *string
	// Returns an environment-sensitive token that should be used for the resource's "ARN" attribute (e.g. `bucket.bucketArn`).
	//
	// Normally, this token will resolve to `arnAttr`, but if the resource is
	// referenced across environments, `arnComponents` will be used to synthesize
	// a concrete ARN with the resource's physical name. Make sure to reference
	// `this.physicalName` in `arnComponents`.
	GetResourceArnAttribute(arnAttr *string, arnComponents *awscdk.ArnComponents) *string
	// Returns an environment-sensitive token that should be used for the resource's "name" attribute (e.g. `bucket.bucketName`).
	//
	// Normally, this token will resolve to `nameAttr`, but if the resource is
	// referenced across environments, it will be resolved to `this.physicalName`,
	// which will be a concrete name.
	GetResourceNameAttribute(nameAttr *string) *string
	// Returns a string representation of this construct.
	ToString() *string
}

A CodeDeploy Deployment Group that deploys to EC2/on-premise instances.

Example:

var alb applicationLoadBalancer

listener := alb.AddListener(jsii.String("Listener"), &BaseApplicationListenerProps{
	Port: jsii.Number(80),
})
targetGroup := listener.AddTargets(jsii.String("Fleet"), &AddApplicationTargetsProps{
	Port: jsii.Number(80),
})

deploymentGroup := codedeploy.NewServerDeploymentGroup(this, jsii.String("DeploymentGroup"), &ServerDeploymentGroupProps{
	LoadBalancer: codedeploy.LoadBalancer_Application(targetGroup),
})

func NewServerDeploymentGroup

func NewServerDeploymentGroup(scope constructs.Construct, id *string, props *ServerDeploymentGroupProps) ServerDeploymentGroup

type ServerDeploymentGroupAttributes

type ServerDeploymentGroupAttributes struct {
	// The reference to the CodeDeploy EC2/on-premise Application that this Deployment Group belongs to.
	Application IServerApplication `field:"required" json:"application" yaml:"application"`
	// The physical, human-readable name of the CodeDeploy EC2/on-premise Deployment Group that we are referencing.
	DeploymentGroupName *string `field:"required" json:"deploymentGroupName" yaml:"deploymentGroupName"`
	// The Deployment Configuration this Deployment Group uses.
	// Default: ServerDeploymentConfig#OneAtATime.
	//
	DeploymentConfig IServerDeploymentConfig `field:"optional" json:"deploymentConfig" yaml:"deploymentConfig"`
}

Properties of a reference to a CodeDeploy EC2/on-premise Deployment Group.

Example:

var application serverApplication

deploymentGroup := codedeploy.ServerDeploymentGroup_FromServerDeploymentGroupAttributes(this, jsii.String("ExistingCodeDeployDeploymentGroup"), &ServerDeploymentGroupAttributes{
	Application: Application,
	DeploymentGroupName: jsii.String("MyExistingDeploymentGroup"),
})

See: ServerDeploymentGroup# import.

type ServerDeploymentGroupProps

type ServerDeploymentGroupProps struct {
	// 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.
	// See: https://docs.aws.amazon.com/codedeploy/latest/userguide/monitoring-create-alarms.html
	//
	// Default: [].
	//
	Alarms *[]awscloudwatch.IAlarm `field:"optional" json:"alarms" yaml:"alarms"`
	// The CodeDeploy EC2/on-premise Application this Deployment Group belongs to.
	// Default: - A new Application will be created.
	//
	Application IServerApplication `field:"optional" json:"application" yaml:"application"`
	// The auto-rollback configuration for this Deployment Group.
	// Default: - default AutoRollbackConfig.
	//
	AutoRollback *AutoRollbackConfig `field:"optional" json:"autoRollback" yaml:"autoRollback"`
	// The auto-scaling groups belonging to this Deployment Group.
	//
	// Auto-scaling groups can also be added after the Deployment Group is created
	// using the `#addAutoScalingGroup` method.
	//
	// [disable-awslint:ref-via-interface] is needed because we update userdata
	// for ASGs to install the codedeploy agent.
	// Default: [].
	//
	AutoScalingGroups *[]awsautoscaling.IAutoScalingGroup `field:"optional" json:"autoScalingGroups" yaml:"autoScalingGroups"`
	// The EC2/on-premise Deployment Configuration to use for this Deployment Group.
	// Default: ServerDeploymentConfig#OneAtATime.
	//
	DeploymentConfig IServerDeploymentConfig `field:"optional" json:"deploymentConfig" yaml:"deploymentConfig"`
	// The physical, human-readable name of the CodeDeploy Deployment Group.
	// Default: - An auto-generated name will be used.
	//
	DeploymentGroupName *string `field:"optional" json:"deploymentGroupName" yaml:"deploymentGroupName"`
	// All EC2 instances matching the given set of tags when a deployment occurs will be added to this Deployment Group.
	// Default: - No additional EC2 instances will be added to the Deployment Group.
	//
	Ec2InstanceTags InstanceTagSet `field:"optional" json:"ec2InstanceTags" yaml:"ec2InstanceTags"`
	// Whether to skip the step of checking CloudWatch alarms during the deployment process.
	// Default: - false.
	//
	IgnoreAlarmConfiguration *bool `field:"optional" json:"ignoreAlarmConfiguration" yaml:"ignoreAlarmConfiguration"`
	// Whether to continue a deployment even if fetching the alarm status from CloudWatch failed.
	// Default: false.
	//
	IgnorePollAlarmsFailure *bool `field:"optional" json:"ignorePollAlarmsFailure" yaml:"ignorePollAlarmsFailure"`
	// If you've provided any auto-scaling groups with the `#autoScalingGroups` property, you can set this property to add User Data that installs the CodeDeploy agent on the instances.
	// See: https://docs.aws.amazon.com/codedeploy/latest/userguide/codedeploy-agent-operations-install.html
	//
	// Default: true.
	//
	InstallAgent *bool `field:"optional" json:"installAgent" yaml:"installAgent"`
	// The load balancer to place in front of this Deployment Group.
	//
	// Can be created from either a classic Elastic Load Balancer,
	// or an Application Load Balancer / Network Load Balancer Target Group.
	// Default: - Deployment Group will not have a load balancer defined.
	//
	// Deprecated: - Use `loadBalancers` instead.
	LoadBalancer LoadBalancer `field:"optional" json:"loadBalancer" yaml:"loadBalancer"`
	// CodeDeploy supports the deployment to multiple load balancers.
	//
	// Specify either multiple Classic Load Balancers, or
	// Application Load Balancers / Network Load Balancers Target Groups.
	// Default: - Deployment Group will not have load balancers defined.
	//
	LoadBalancers *[]LoadBalancer `field:"optional" json:"loadBalancers" yaml:"loadBalancers"`
	// All on-premise instances matching the given set of tags when a deployment occurs will be added to this Deployment Group.
	// Default: - No additional on-premise instances will be added to the Deployment Group.
	//
	OnPremiseInstanceTags InstanceTagSet `field:"optional" json:"onPremiseInstanceTags" yaml:"onPremiseInstanceTags"`
	// The service Role of this Deployment Group.
	// Default: - A new Role will be created.
	//
	Role awsiam.IRole `field:"optional" json:"role" yaml:"role"`
}

Construction properties for `ServerDeploymentGroup`.

Example:

var alb applicationLoadBalancer

listener := alb.AddListener(jsii.String("Listener"), &BaseApplicationListenerProps{
	Port: jsii.Number(80),
})
targetGroup := listener.AddTargets(jsii.String("Fleet"), &AddApplicationTargetsProps{
	Port: jsii.Number(80),
})

deploymentGroup := codedeploy.NewServerDeploymentGroup(this, jsii.String("DeploymentGroup"), &ServerDeploymentGroupProps{
	LoadBalancer: codedeploy.LoadBalancer_Application(targetGroup),
})

type TimeBasedCanaryTrafficRouting added in v2.45.0

type TimeBasedCanaryTrafficRouting interface {
	TrafficRouting
	// The amount of time between additional traffic shifts.
	Interval() awscdk.Duration
	// The percentage to increase traffic on each traffic shift.
	Percentage() *float64
	// Return a TrafficRoutingConfig of type `TimeBasedCanary`.
	Bind(_scope constructs.Construct) *TrafficRoutingConfig
}

Define a traffic routing config of type 'TimeBasedCanary'.

Example:

config := codedeploy.NewLambdaDeploymentConfig(this, jsii.String("CustomConfig"), &LambdaDeploymentConfigProps{
	TrafficRouting: codedeploy.NewTimeBasedCanaryTrafficRouting(&TimeBasedCanaryTrafficRoutingProps{
		Interval: awscdk.Duration_Minutes(jsii.Number(15)),
		Percentage: jsii.Number(5),
	}),
	DeploymentConfigName: jsii.String("MyDeploymentConfig"),
})

func NewTimeBasedCanaryTrafficRouting added in v2.45.0

func NewTimeBasedCanaryTrafficRouting(props *TimeBasedCanaryTrafficRoutingProps) TimeBasedCanaryTrafficRouting

type TimeBasedCanaryTrafficRoutingProps added in v2.45.0

type TimeBasedCanaryTrafficRoutingProps struct {
	// The amount of time between traffic shifts.
	Interval awscdk.Duration `field:"required" json:"interval" yaml:"interval"`
	// The percentage to increase traffic on each traffic shift.
	Percentage *float64 `field:"required" json:"percentage" yaml:"percentage"`
}

Construction properties for `TimeBasedCanaryTrafficRouting`.

Example:

config := codedeploy.NewLambdaDeploymentConfig(this, jsii.String("CustomConfig"), &LambdaDeploymentConfigProps{
	TrafficRouting: codedeploy.NewTimeBasedCanaryTrafficRouting(&TimeBasedCanaryTrafficRoutingProps{
		Interval: awscdk.Duration_Minutes(jsii.Number(15)),
		Percentage: jsii.Number(5),
	}),
	DeploymentConfigName: jsii.String("MyDeploymentConfig"),
})

type TimeBasedLinearTrafficRouting added in v2.45.0

type TimeBasedLinearTrafficRouting interface {
	TrafficRouting
	// The amount of time between additional traffic shifts.
	Interval() awscdk.Duration
	// The percentage to increase traffic on each traffic shift.
	Percentage() *float64
	// Return a TrafficRoutingConfig of type `TimeBasedLinear`.
	Bind(_scope constructs.Construct) *TrafficRoutingConfig
}

Define a traffic routing config of type 'TimeBasedLinear'.

Example:

// 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"

timeBasedLinearTrafficRouting := awscdk.Aws_codedeploy.TimeBasedLinearTrafficRouting_AllAtOnce()

func NewTimeBasedLinearTrafficRouting added in v2.45.0

func NewTimeBasedLinearTrafficRouting(props *TimeBasedLinearTrafficRoutingProps) TimeBasedLinearTrafficRouting

type TimeBasedLinearTrafficRoutingProps added in v2.45.0

type TimeBasedLinearTrafficRoutingProps struct {
	// The amount of time between traffic shifts.
	Interval awscdk.Duration `field:"required" json:"interval" yaml:"interval"`
	// The percentage to increase traffic on each traffic shift.
	Percentage *float64 `field:"required" json:"percentage" yaml:"percentage"`
}

Construction properties for `TimeBasedLinearTrafficRouting`.

Example:

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import cdk "github.com/aws/aws-cdk-go/awscdk"
import "github.com/aws/aws-cdk-go/awscdk"

timeBasedLinearTrafficRoutingProps := &TimeBasedLinearTrafficRoutingProps{
	Interval: cdk.Duration_Minutes(jsii.Number(30)),
	Percentage: jsii.Number(123),
}

type TrafficRouting added in v2.45.0

type TrafficRouting interface {
	// Returns the traffic routing configuration.
	Bind(scope constructs.Construct) *TrafficRoutingConfig
}

Represents how traffic is shifted during a CodeDeploy deployment.

Example:

config := codedeploy.NewLambdaDeploymentConfig(this, jsii.String("CustomConfig"), &LambdaDeploymentConfigProps{
	TrafficRouting: codedeploy.NewTimeBasedCanaryTrafficRouting(&TimeBasedCanaryTrafficRoutingProps{
		Interval: awscdk.Duration_Minutes(jsii.Number(15)),
		Percentage: jsii.Number(5),
	}),
	DeploymentConfigName: jsii.String("MyDeploymentConfig"),
})

func AllAtOnceTrafficRouting_AllAtOnce added in v2.45.0

func AllAtOnceTrafficRouting_AllAtOnce() TrafficRouting

Shifts 100% of traffic in a single shift.

func AllAtOnceTrafficRouting_TimeBasedCanary added in v2.45.0

func AllAtOnceTrafficRouting_TimeBasedCanary(props *TimeBasedCanaryTrafficRoutingProps) TrafficRouting

Shifts a specified percentage of traffic, waits for a specified amount of time, then shifts the rest of traffic.

func AllAtOnceTrafficRouting_TimeBasedLinear added in v2.45.0

func AllAtOnceTrafficRouting_TimeBasedLinear(props *TimeBasedLinearTrafficRoutingProps) TrafficRouting

Keeps shifting a specified percentage of traffic until reaching 100%, waiting for a specified amount of time in between each traffic shift.

func TimeBasedCanaryTrafficRouting_AllAtOnce added in v2.45.0

func TimeBasedCanaryTrafficRouting_AllAtOnce() TrafficRouting

Shifts 100% of traffic in a single shift.

func TimeBasedCanaryTrafficRouting_TimeBasedCanary added in v2.45.0

func TimeBasedCanaryTrafficRouting_TimeBasedCanary(props *TimeBasedCanaryTrafficRoutingProps) TrafficRouting

Shifts a specified percentage of traffic, waits for a specified amount of time, then shifts the rest of traffic.

func TimeBasedCanaryTrafficRouting_TimeBasedLinear added in v2.45.0

func TimeBasedCanaryTrafficRouting_TimeBasedLinear(props *TimeBasedLinearTrafficRoutingProps) TrafficRouting

Keeps shifting a specified percentage of traffic until reaching 100%, waiting for a specified amount of time in between each traffic shift.

func TimeBasedLinearTrafficRouting_AllAtOnce added in v2.45.0

func TimeBasedLinearTrafficRouting_AllAtOnce() TrafficRouting

Shifts 100% of traffic in a single shift.

func TimeBasedLinearTrafficRouting_TimeBasedCanary added in v2.45.0

func TimeBasedLinearTrafficRouting_TimeBasedCanary(props *TimeBasedCanaryTrafficRoutingProps) TrafficRouting

Shifts a specified percentage of traffic, waits for a specified amount of time, then shifts the rest of traffic.

func TimeBasedLinearTrafficRouting_TimeBasedLinear added in v2.45.0

func TimeBasedLinearTrafficRouting_TimeBasedLinear(props *TimeBasedLinearTrafficRoutingProps) TrafficRouting

Keeps shifting a specified percentage of traffic until reaching 100%, waiting for a specified amount of time in between each traffic shift.

func TrafficRouting_AllAtOnce added in v2.45.0

func TrafficRouting_AllAtOnce() TrafficRouting

Shifts 100% of traffic in a single shift.

func TrafficRouting_TimeBasedCanary added in v2.45.0

func TrafficRouting_TimeBasedCanary(props *TimeBasedCanaryTrafficRoutingProps) TrafficRouting

Shifts a specified percentage of traffic, waits for a specified amount of time, then shifts the rest of traffic.

func TrafficRouting_TimeBasedLinear added in v2.45.0

func TrafficRouting_TimeBasedLinear(props *TimeBasedLinearTrafficRoutingProps) TrafficRouting

Keeps shifting a specified percentage of traffic until reaching 100%, waiting for a specified amount of time in between each traffic shift.

type TrafficRoutingConfig added in v2.45.0

type TrafficRoutingConfig struct {
	// The type of traffic shifting ( `TimeBasedCanary` or `TimeBasedLinear` ) used by a deployment configuration.
	Type *string `field:"required" json:"type" yaml:"type"`
	// A configuration that shifts traffic from one version of a Lambda function or ECS task set to another in two increments.
	// Default: none.
	//
	TimeBasedCanary *CanaryTrafficRoutingConfig `field:"optional" json:"timeBasedCanary" yaml:"timeBasedCanary"`
	// A configuration that shifts traffic from one version of a Lambda function or Amazon ECS task set to another in equal increments, with an equal number of minutes between each increment.
	// Default: none.
	//
	TimeBasedLinear *LinearTrafficRoutingConfig `field:"optional" json:"timeBasedLinear" yaml:"timeBasedLinear"`
}

Represents the structure to pass into the underlying CfnDeploymentConfig class.

Example:

// 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"

trafficRoutingConfig := &TrafficRoutingConfig{
	Type: jsii.String("type"),

	// the properties below are optional
	TimeBasedCanary: &CanaryTrafficRoutingConfig{
		CanaryInterval: jsii.Number(123),
		CanaryPercentage: jsii.Number(123),
	},
	TimeBasedLinear: &LinearTrafficRoutingConfig{
		LinearInterval: jsii.Number(123),
		LinearPercentage: jsii.Number(123),
	},
}

Source Files

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL