Skip to main content

deployment_groups

Creates, updates, deletes, gets or lists a deployment_groups resource.

Overview

Namedeployment_groups
TypeResource
Idaws.codedeploy.deployment_groups

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
deployment_groups_infoarrayInformation about the deployment groups.
error_messagestringInformation about errors that might have occurred during the API call.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
batch_get_deployment_groupsselectregionGets information about one or more deployment groups.
get_deployment_groupselectregionGets information about a deployment group.
list_deployment_groupsselectregionLists the deployment groups for an application registered with the Amazon Web Services user or Amazon Web Services account.
create_deployment_groupinsertregion, applicationName, deploymentGroupName, serviceRoleArnCreates a deployment group to which application revisions are deployed.
update_deployment_groupupdateregion, applicationName, currentDeploymentGroupNameChanges information about a deployment group.
delete_deployment_groupdeleteregionDeletes a deployment group.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
regionstringAWS region (default: us-east-1)

SELECT examples

Gets information about one or more deployment groups.

SELECT
deployment_groups_info,
error_message
FROM aws.codedeploy.deployment_groups
WHERE region = '{{ region }}' -- required
;

INSERT examples

Creates a deployment group to which application revisions are deployed.

INSERT INTO aws.codedeploy.deployment_groups (
applicationName,
deploymentGroupName,
deploymentConfigName,
ec2TagFilters,
onPremisesInstanceTagFilters,
autoScalingGroups,
serviceRoleArn,
triggerConfigurations,
alarmConfiguration,
autoRollbackConfiguration,
outdatedInstancesStrategy,
deploymentStyle,
blueGreenDeploymentConfiguration,
loadBalancerInfo,
ec2TagSet,
ecsServices,
onPremisesTagSet,
tags,
terminationHookEnabled,
region
)
SELECT
'{{ applicationName }}' /* required */,
'{{ deploymentGroupName }}' /* required */,
'{{ deploymentConfigName }}',
'{{ ec2TagFilters }}',
'{{ onPremisesInstanceTagFilters }}',
'{{ autoScalingGroups }}',
'{{ serviceRoleArn }}' /* required */,
'{{ triggerConfigurations }}',
'{{ alarmConfiguration }}',
'{{ autoRollbackConfiguration }}',
'{{ outdatedInstancesStrategy }}',
'{{ deploymentStyle }}',
'{{ blueGreenDeploymentConfiguration }}',
'{{ loadBalancerInfo }}',
'{{ ec2TagSet }}',
'{{ ecsServices }}',
'{{ onPremisesTagSet }}',
'{{ tags }}',
{{ terminationHookEnabled }},
'{{ region }}'
RETURNING
deployment_group_id
;

UPDATE examples

Changes information about a deployment group.

UPDATE aws.codedeploy.deployment_groups
SET
applicationName = '{{ applicationName }}',
currentDeploymentGroupName = '{{ currentDeploymentGroupName }}',
newDeploymentGroupName = '{{ newDeploymentGroupName }}',
deploymentConfigName = '{{ deploymentConfigName }}',
ec2TagFilters = '{{ ec2TagFilters }}',
onPremisesInstanceTagFilters = '{{ onPremisesInstanceTagFilters }}',
autoScalingGroups = '{{ autoScalingGroups }}',
serviceRoleArn = '{{ serviceRoleArn }}',
triggerConfigurations = '{{ triggerConfigurations }}',
alarmConfiguration = '{{ alarmConfiguration }}',
autoRollbackConfiguration = '{{ autoRollbackConfiguration }}',
outdatedInstancesStrategy = '{{ outdatedInstancesStrategy }}',
deploymentStyle = '{{ deploymentStyle }}',
blueGreenDeploymentConfiguration = '{{ blueGreenDeploymentConfiguration }}',
loadBalancerInfo = '{{ loadBalancerInfo }}',
ec2TagSet = '{{ ec2TagSet }}',
ecsServices = '{{ ecsServices }}',
onPremisesTagSet = '{{ onPremisesTagSet }}',
terminationHookEnabled = {{ terminationHookEnabled }}
WHERE
region = '{{ region }}' --required
AND applicationName = '{{ applicationName }}' --required
AND currentDeploymentGroupName = '{{ currentDeploymentGroupName }}' --required
RETURNING
hooks_not_cleaned_up;

DELETE examples

Deletes a deployment group.

DELETE FROM aws.codedeploy.deployment_groups
WHERE region = '{{ region }}' --required
;