Class ServerDeploymentGroup.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<ServerDeploymentGroup>
- Enclosing class:
ServerDeploymentGroup
ServerDeploymentGroup
.-
Method Summary
Modifier and TypeMethodDescriptionThe CloudWatch alarms associated with this Deployment Group.application
(IServerApplication application) The CodeDeploy EC2/on-premise Application this Deployment Group belongs to.autoRollback
(AutoRollbackConfig autoRollback) The auto-rollback configuration for this Deployment Group.autoScalingGroups
(List<? extends IAutoScalingGroup> autoScalingGroups) The auto-scaling groups belonging to this Deployment Group.build()
deploymentConfig
(IServerDeploymentConfig deploymentConfig) The EC2/on-premise Deployment Configuration to use for this Deployment Group.deploymentGroupName
(String deploymentGroupName) The physical, human-readable name of the CodeDeploy Deployment Group.ec2InstanceTags
(InstanceTagSet ec2InstanceTags) All EC2 instances matching the given set of tags when a deployment occurs will be added to this Deployment Group.ignorePollAlarmsFailure
(Boolean ignorePollAlarmsFailure) Whether to continue a deployment even if fetching the alarm status from CloudWatch failed.installAgent
(Boolean installAgent) If you've provided any auto-scaling groups with theautoScalingGroups(java.util.List<? extends software.amazon.awscdk.services.autoscaling.IAutoScalingGroup>)
property, you can set this property to add User Data that installs the CodeDeploy agent on the instances.loadBalancer
(LoadBalancer loadBalancer) The load balancer to place in front of this Deployment Group.onPremiseInstanceTags
(InstanceTagSet onPremiseInstanceTags) All on-premise instances matching the given set of tags when a deployment occurs will be added to this Deployment Group.The service Role of this Deployment Group.
-
Method Details
-
create
@Stability(Stable) public static ServerDeploymentGroup.Builder create(software.constructs.Construct scope, String id) - Parameters:
scope
- This parameter is required.id
- This parameter is required.- Returns:
- a new instance of
ServerDeploymentGroup.Builder
.
-
alarms
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
ServerDeploymentGroup.addAlarm(software.amazon.awscdk.services.cloudwatch.IAlarm)
method.Default: []
- Parameters:
alarms
- The CloudWatch alarms associated with this Deployment Group. This parameter is required.- Returns:
this
- See Also:
-
application
The CodeDeploy EC2/on-premise Application this Deployment Group belongs to.Default: - A new Application will be created.
- Parameters:
application
- The CodeDeploy EC2/on-premise Application this Deployment Group belongs to. This parameter is required.- Returns:
this
-
autoRollback
@Stability(Stable) public ServerDeploymentGroup.Builder autoRollback(AutoRollbackConfig autoRollback) The auto-rollback configuration for this Deployment Group.Default: - default AutoRollbackConfig.
- Parameters:
autoRollback
- The auto-rollback configuration for this Deployment Group. This parameter is required.- Returns:
this
-
autoScalingGroups
@Stability(Stable) public ServerDeploymentGroup.Builder autoScalingGroups(List<? extends IAutoScalingGroup> autoScalingGroups) The auto-scaling groups belonging to this Deployment Group.Auto-scaling groups can also be added after the Deployment Group is created using the
ServerDeploymentGroup.addAutoScalingGroup(software.amazon.awscdk.services.autoscaling.AutoScalingGroup)
method. [disable-awslint:ref-via-interface] is needed because we update userdata for ASGs to install the codedeploy agent.Default: []
- Parameters:
autoScalingGroups
- The auto-scaling groups belonging to this Deployment Group. This parameter is required.- Returns:
this
-
deploymentConfig
@Stability(Stable) public ServerDeploymentGroup.Builder deploymentConfig(IServerDeploymentConfig deploymentConfig) The EC2/on-premise Deployment Configuration to use for this Deployment Group.Default: ServerDeploymentConfig#OneAtATime
- Parameters:
deploymentConfig
- The EC2/on-premise Deployment Configuration to use for this Deployment Group. This parameter is required.- Returns:
this
-
deploymentGroupName
@Stability(Stable) public ServerDeploymentGroup.Builder deploymentGroupName(String deploymentGroupName) The physical, human-readable name of the CodeDeploy Deployment Group.Default: - An auto-generated name will be used.
- Parameters:
deploymentGroupName
- The physical, human-readable name of the CodeDeploy Deployment Group. This parameter is required.- Returns:
this
-
ec2InstanceTags
@Stability(Stable) public ServerDeploymentGroup.Builder ec2InstanceTags(InstanceTagSet ec2InstanceTags) 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.
- Parameters:
ec2InstanceTags
- All EC2 instances matching the given set of tags when a deployment occurs will be added to this Deployment Group. This parameter is required.- Returns:
this
-
ignorePollAlarmsFailure
@Stability(Stable) public ServerDeploymentGroup.Builder ignorePollAlarmsFailure(Boolean ignorePollAlarmsFailure) Whether to continue a deployment even if fetching the alarm status from CloudWatch failed.Default: false
- Parameters:
ignorePollAlarmsFailure
- Whether to continue a deployment even if fetching the alarm status from CloudWatch failed. This parameter is required.- Returns:
this
-
installAgent
If you've provided any auto-scaling groups with theautoScalingGroups(java.util.List<? extends software.amazon.awscdk.services.autoscaling.IAutoScalingGroup>)
property, you can set this property to add User Data that installs the CodeDeploy agent on the instances.Default: true
- Parameters:
installAgent
- If you've provided any auto-scaling groups with theautoScalingGroups(java.util.List<? extends software.amazon.awscdk.services.autoscaling.IAutoScalingGroup>)
property, you can set this property to add User Data that installs the CodeDeploy agent on the instances. This parameter is required.- Returns:
this
- See Also:
-
loadBalancer
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.
- Parameters:
loadBalancer
- The load balancer to place in front of this Deployment Group. This parameter is required.- Returns:
this
-
onPremiseInstanceTags
@Stability(Stable) public ServerDeploymentGroup.Builder onPremiseInstanceTags(InstanceTagSet onPremiseInstanceTags) 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.
- Parameters:
onPremiseInstanceTags
- All on-premise instances matching the given set of tags when a deployment occurs will be added to this Deployment Group. This parameter is required.- Returns:
this
-
role
The service Role of this Deployment Group.Default: - A new Role will be created.
- Parameters:
role
- The service Role of this Deployment Group. This parameter is required.- Returns:
this
-
build
- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<ServerDeploymentGroup>
- Returns:
- a newly built instance of
ServerDeploymentGroup
.
-