Skip to main content

deployments

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

Overview

Namedeployments
TypeResource
Idaws.m2.deployments

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
application_idstringThe unique identifier of the application. (pattern: <code>^\S{1,80}$</code>)
application_versionintegerThe application version.
creation_timestring (date-time)The timestamp when the deployment was created.
deployment_idstringThe unique identifier of the deployment. (pattern: <code>^\S{1,80}$</code>)
environment_idstringThe unique identifier of the runtime environment. (pattern: <code>^\S{1,80}$</code>)
statusstringThe status of the deployment. (Deploying, Succeeded, Failed, Updating Deployment)
status_reasonstringThe reason for the reported status.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_deploymentselectapplication_id, deployment_id, regionGets details of a specific deployment with a given deployment identifier.
list_deploymentsselectapplication_id, regionmaxResults, nextTokenReturns a list of all deployments of a specific application. A deployment is a combination of a specific application and a specific version of that application. Each deployment is mapped to a particular application version.
create_deploymentinsertapplication_id, region, applicationVersion, environmentIdCreates and starts a deployment to deploy an application into a runtime environment.

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
application_idstringThe application identifier.
deployment_idstringThe unique identifier for the deployment.
regionstringAWS region (default: us-east-1)
maxResultsintegerThe maximum number of objects to return.
nextTokenstringA pagination token returned from a previous call to this operation. This specifies the next item to return. To return to the beginning of the list, exclude this parameter.

SELECT examples

Gets details of a specific deployment with a given deployment identifier.

SELECT
application_id,
application_version,
creation_time,
deployment_id,
environment_id,
status,
status_reason
FROM aws.m2.deployments
WHERE application_id = '{{ application_id }}' -- required
AND deployment_id = '{{ deployment_id }}' -- required
AND region = '{{ region }}' -- required
;

INSERT examples

Creates and starts a deployment to deploy an application into a runtime environment.

INSERT INTO aws.m2.deployments (
applicationVersion,
clientToken,
environmentId,
application_id,
region
)
SELECT
{{ applicationVersion }} /* required */,
'{{ clientToken }}',
'{{ environmentId }}' /* required */,
'{{ application_id }}',
'{{ region }}'
RETURNING
deployment_id
;