Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
StopInstances:
Type: Task
Resource: ${self:custom.function-arn}-StopInstances
Next: WaitForInstancesStop
WaitForInstancesStop:
Type: Wait
Seconds: 15
Next: CheckInstancesStopped
CheckInstancesStopped:
Type: Task
Resource: ${self:custom.function-arn}-CheckInstancesStopped
Next: EvaluateInstancesStopped
EvaluateInstancesStopped:
Type: Choice
Choices:
- Variable: '$.instanceShutdownStatus'
StringEquals: 'FAILED'
Next: StopInstancesFailure
- Variable: '$.instanceShutdownStatus'
StringEquals: 'SUCCESS'
Next: DetachVolumes
Default: WaitForInstancesStop
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.