continueServiceDeployment
abstract suspend fun continueServiceDeployment(input: ContinueServiceDeploymentRequest): ContinueServiceDeploymentResponse
Continues or rolls back an Amazon ECS service deployment that is paused at a lifecycle hook.
When a service deployment reaches a lifecycle stage that has a PAUSE hook configured, the deployment pauses and waits for an explicit action. Use this API to either continue the deployment to the next stage or roll back to the previous service revision.
To find the hookId of the paused hook, call DescribeServiceDeployments and inspect the lifecycleHookDetails field.
Samples
// This example continues a service deployment that is paused at a lifecycle hook, using the CONTINUE
// action to proceed to the next deployment stage.
val resp = ecsClient.continueServiceDeployment {
serviceDeploymentArn = "arn:aws:ecs:us-east-1:123456789012:service-deployment/MyCluster/MyService/r9i43YFjvgF_xlg7m2eJ1r"
hookId = "ABCDEFGHIJKLMNOPQRSTUVWXYZ234567"
action = DeploymentLifecycleHookAction.fromValue("CONTINUE")
}Content copied to clipboard
// This example rolls back a service deployment that is paused at a lifecycle hook, using the ROLLBACK
// action to revert to the previous service revision.
val resp = ecsClient.continueServiceDeployment {
serviceDeploymentArn = "arn:aws:ecs:us-east-1:123456789012:service-deployment/MyCluster/MyService/r9i43YFjvgF_xlg7m2eJ1r"
hookId = "ABCDEFGHIJKLMNOPQRSTUVWXYZ234567"
action = DeploymentLifecycleHookAction.fromValue("ROLLBACK")
}Content copied to clipboard