b14c0f727e
The update abort is not reliable, and could mess up a TripleO stack beyond repair. Since this has a potential for data loss, I would suggest this be removed without a deprecation period. Depends-On: Ieec4f01e38768eafb3df1f06340bdd3e220d30bd Change-Id: I752e061979d667c1fb2b115c1a7339002e1824d5
77 lines
2.1 KiB
YAML
77 lines
2.1 KiB
YAML
---
|
|
version: '2.0'
|
|
name: tripleo.package_update.v1
|
|
description: TripleO update workflows
|
|
|
|
workflows:
|
|
|
|
# Updates a workload cloud stack
|
|
package_update_plan:
|
|
description: Take a container and perform a package update with possible breakpoints
|
|
|
|
input:
|
|
- container
|
|
- timeout: 240
|
|
- queue_name: tripleo
|
|
|
|
tasks:
|
|
update:
|
|
action: tripleo.package_update.update_stack container=<% $.container %> timeout=<% $.timeout %>
|
|
on-success: send_message
|
|
on-error: set_update_failed
|
|
|
|
set_update_failed:
|
|
on-success: send_message
|
|
publish:
|
|
status: FAILED
|
|
message: <% task(update).result %>
|
|
|
|
send_message:
|
|
action: zaqar.queue_post
|
|
input:
|
|
queue_name: <% $.queue_name %>
|
|
messages:
|
|
body:
|
|
type: tripleo.package_update.v1.package_update_plan
|
|
payload:
|
|
status: <% $.get('status', 'SUCCESS') %>
|
|
message: <% $.get('message', '') %>
|
|
execution: <% execution() %>
|
|
on-success:
|
|
- fail: <% $.get('status') = "FAILED" %>
|
|
|
|
# Clear an update breakpoint
|
|
clear_breakpoints:
|
|
description: Clear any pending breakpoints and continue with update
|
|
|
|
input:
|
|
- stack_id
|
|
- refs
|
|
- queue_name: tripleo
|
|
|
|
tasks:
|
|
clear:
|
|
action: tripleo.package_update.clear_breakpoints stack_id=<% $.stack_id %> refs=<% $.refs %>
|
|
on-success: send_message
|
|
on-error: set_clear_breakpoints_failed
|
|
|
|
set_clear_breakpoints_failed:
|
|
on-success: send_message
|
|
publish:
|
|
status: FAILED
|
|
message: <% task(clear).result %>
|
|
|
|
send_message:
|
|
action: zaqar.queue_post
|
|
input:
|
|
queue_name: <% $.queue_name %>
|
|
messages:
|
|
body:
|
|
type: tripleo.package_update.v1.clear_breakpoints
|
|
payload:
|
|
status: <% $.get('status', 'SUCCESS') %>
|
|
message: <% $.get('message', '') %>
|
|
execution: <% execution() %>
|
|
on-success:
|
|
- fail: <% $.get('status') = "FAILED" %>
|