lifecycle_executions
Creates, updates, deletes, gets or lists a lifecycle_executions resource.
Overview
| Name | lifecycle_executions |
| Type | Resource |
| Id | aws.imagebuilder.lifecycle_executions |
Fields
The following fields are returned by SELECT queries:
- get_lifecycle_execution
- list_lifecycle_executions
| Name | Datatype | Description |
|---|---|---|
end_time | string (date-time) | The timestamp when the lifecycle runtime instance completed. |
lifecycle_execution_id | string | Identifies the lifecycle policy runtime instance. (pattern: <code>^lce-[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$</code>) |
lifecycle_policy_arn | string | The Amazon Resource Name (ARN) of the lifecycle policy that ran. (pattern: <code>^arn:aws(?:-[a-z]+)*:imagebuilder:[a-z]{2,}(?:-[a-z]+)+-[0-9]+:(?:[0-9]{12}|aws):lifecycle-policy/[a-z0-9-_]+$</code>) |
resources_impacted_summary | object | Contains information about associated resources that are identified for action by the runtime instance of the lifecycle policy. |
start_time | string (date-time) | The timestamp when the lifecycle runtime instance started. |
state | object | Runtime state that reports if the policy action ran successfully, failed, or was skipped. |
| Name | Datatype | Description |
|---|---|---|
end_time | string (date-time) | The timestamp when the lifecycle runtime instance completed. |
lifecycle_execution_id | string | Identifies the lifecycle policy runtime instance. (pattern: <code>^lce-[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$</code>) |
lifecycle_policy_arn | string | The Amazon Resource Name (ARN) of the lifecycle policy that ran. (pattern: <code>^arn:aws(?:-[a-z]+)*:imagebuilder:[a-z]{2,}(?:-[a-z]+)+-[0-9]+:(?:[0-9]{12}|aws):lifecycle-policy/[a-z0-9-_]+$</code>) |
resources_impacted_summary | object | Contains information about associated resources that are identified for action by the runtime instance of the lifecycle policy. |
start_time | string (date-time) | The timestamp when the lifecycle runtime instance started. |
state | object | Runtime state that reports if the policy action ran successfully, failed, or was skipped. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get_lifecycle_execution | select | lifecycleExecutionId, region | Get the runtime information that was logged for a specific runtime instance of the lifecycle policy. | |
list_lifecycle_executions | select | region | Get the lifecycle runtime history for the specified resource. | |
cancel_lifecycle_execution | exec | region, lifecycleExecutionId, clientToken | Cancel a specific image lifecycle policy runtime instance. |
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 |
|---|---|---|
lifecycleExecutionId | string | Use the unique identifier for a runtime instance of the lifecycle policy to get runtime details. |
region | string | AWS region (default: us-east-1) |
SELECT examples
- get_lifecycle_execution
- list_lifecycle_executions
Get the runtime information that was logged for a specific runtime instance of the lifecycle policy.
SELECT
end_time,
lifecycle_execution_id,
lifecycle_policy_arn,
resources_impacted_summary,
start_time,
state
FROM aws.imagebuilder.lifecycle_executions
WHERE lifecycleExecutionId = '{{ lifecycleExecutionId }}' -- required
AND region = '{{ region }}' -- required
;
Get the lifecycle runtime history for the specified resource.
SELECT
end_time,
lifecycle_execution_id,
lifecycle_policy_arn,
resources_impacted_summary,
start_time,
state
FROM aws.imagebuilder.lifecycle_executions
WHERE region = '{{ region }}' -- required
;
Lifecycle Methods
- cancel_lifecycle_execution
Cancel a specific image lifecycle policy runtime instance.
EXEC aws.imagebuilder.lifecycle_executions.cancel_lifecycle_execution
@region='{{ region }}' --required
@@json=
'{
"lifecycleExecutionId": "{{ lifecycleExecutionId }}",
"clientToken": "{{ clientToken }}"
}'
;