deployment_configs
Creates, updates, deletes, gets or lists a deployment_configs resource.
Overview
| Name | deployment_configs |
| Type | Resource |
| Id | aws.codedeploy.deployment_configs |
Fields
The following fields are returned by SELECT queries:
- get_deployment_config
- list_deployment_configs
| Name | Datatype | Description |
|---|---|---|
compute_platform | string | The destination platform type for the deployment (Lambda, Server, or ECS). (Server, Lambda, ECS) |
create_time | string (date-time) | The time at which the deployment configuration was created. |
deployment_config_id | string | The deployment configuration ID. |
deployment_config_name | string | The deployment configuration name. |
minimum_healthy_hosts | object | Information about the number or percentage of minimum healthy instances. |
traffic_routing_config | object | The configuration that specifies how the deployment traffic is routed. Used for deployments with a Lambda or Amazon ECS compute platform only. |
zonal_config | object | Information about a zonal configuration. |
| Name | Datatype | Description |
|---|---|---|
deployment_configs | string | A list of deployment configurations, including built-in configurations such as CodeDeployDefault.OneAtATime. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get_deployment_config | select | region | Gets information about a deployment configuration. | |
list_deployment_configs | select | region | Lists the deployment configurations with the user or Amazon Web Services account. | |
create_deployment_config | insert | region, deploymentConfigName | Creates a deployment configuration. | |
delete_deployment_config | delete | region | Deletes a deployment configuration. A deployment configuration cannot be deleted if it is currently in use. Predefined configurations cannot be deleted. |
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.
| Name | Datatype | Description |
|---|---|---|
region | string | AWS region (default: us-east-1) |
SELECT examples
- get_deployment_config
- list_deployment_configs
Gets information about a deployment configuration.
SELECT
compute_platform,
create_time,
deployment_config_id,
deployment_config_name,
minimum_healthy_hosts,
traffic_routing_config,
zonal_config
FROM aws.codedeploy.deployment_configs
WHERE region = '{{ region }}' -- required
;
Lists the deployment configurations with the user or Amazon Web Services account.
SELECT
deployment_configs
FROM aws.codedeploy.deployment_configs
WHERE region = '{{ region }}' -- required
;
INSERT examples
- create_deployment_config
- Manifest
Creates a deployment configuration.
INSERT INTO aws.codedeploy.deployment_configs (
deploymentConfigName,
minimumHealthyHosts,
trafficRoutingConfig,
computePlatform,
zonalConfig,
region
)
SELECT
'{{ deploymentConfigName }}' /* required */,
'{{ minimumHealthyHosts }}',
'{{ trafficRoutingConfig }}',
'{{ computePlatform }}',
'{{ zonalConfig }}',
'{{ region }}'
RETURNING
deployment_config_id
;
# Description fields are for documentation purposes
- name: deployment_configs
props:
- name: region
value: "{{ region }}"
description: Required parameter for the deployment_configs resource.
- name: deploymentConfigName
value: "{{ deploymentConfigName }}"
description: |
The name of the deployment configuration to create.
- name: minimumHealthyHosts
description: |
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, CodeDeploy converts the percentage to the equivalent number of instances 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.
value:
type_: "{{ type_ }}"
value: {{ value }}
- name: trafficRoutingConfig
description: |
The configuration that specifies how the deployment traffic is routed.
value:
type_: "{{ type_ }}"
timeBasedCanary:
canaryPercentage: {{ canaryPercentage }}
canaryInterval: {{ canaryInterval }}
timeBasedLinear:
linearPercentage: {{ linearPercentage }}
linearInterval: {{ linearInterval }}
- name: computePlatform
value: "{{ computePlatform }}"
description: |
The destination platform type for the deployment (Lambda, Server, or ECS).
valid_values: ['Server', 'Lambda', 'ECS']
- name: zonalConfig
description: |
Configure the ZonalConfig object if you want CodeDeploy to deploy your application to one Availability Zone at a time, within an Amazon Web Services Region. For more information about the zonal configuration feature, see zonal configuration in the CodeDeploy User Guide.
value:
firstZoneMonitorDurationInSeconds: {{ firstZoneMonitorDurationInSeconds }}
monitorDurationInSeconds: {{ monitorDurationInSeconds }}
minimumHealthyHostsPerZone:
type_: "{{ type_ }}"
value: {{ value }}
DELETE examples
- delete_deployment_config
Deletes a deployment configuration. A deployment configuration cannot be deleted if it is currently in use. Predefined configurations cannot be deleted.
DELETE FROM aws.codedeploy.deployment_configs
WHERE region = '{{ region }}' --required
;