Fix the validation ssh keys workflow
The current workflow did not end up copying the validation keys to the overcloud nodes, because the overcloud deployment action is asynchronous. So copy_ssh_keys runs right after the Heat call when the list of Nova servers is empty. So instead, we optionally pass the validation key into Heat directly at deployment time, not after. Change-Id: I5ceee2a1db077167253f7b3b7d6160f1efd0e447 Closes-Bug: #1635226 Depends-On: I861b9e2252a9c8122dcf7df261386f1ea5200c4f
This commit is contained in:
parent
d718bed681
commit
65b276d3ec
|
@ -108,20 +108,15 @@ workflows:
|
|||
|
||||
tasks:
|
||||
|
||||
add_validation_ssh_key:
|
||||
workflow: tripleo.validations.v1.add_validation_ssh_key_parameter container=<% $.container %>
|
||||
on-complete: deploy
|
||||
|
||||
deploy:
|
||||
action: tripleo.deployment.deploy timeout=<% $.timeout %> container=<% $.container %>
|
||||
on-success: test_validations_enabled
|
||||
on-success: send_message
|
||||
on-error: set_deployment_failed
|
||||
|
||||
test_validations_enabled:
|
||||
action: tripleo.validations.enabled
|
||||
on-success: copy_validation_ssh_keys
|
||||
on-error: send_message
|
||||
|
||||
copy_validation_ssh_keys:
|
||||
workflow: tripleo.validations.v1.copy_ssh_key
|
||||
on-complete: send_message
|
||||
|
||||
set_deployment_failed:
|
||||
on-success: send_message
|
||||
publish:
|
||||
|
|
|
@ -180,6 +180,38 @@ workflows:
|
|||
find_groups:
|
||||
action: tripleo.validations.list_groups
|
||||
|
||||
add_validation_ssh_key_parameter:
|
||||
input:
|
||||
- container
|
||||
- queue_name: tripleo
|
||||
|
||||
tasks:
|
||||
test_validations_enabled:
|
||||
action: tripleo.validations.enabled
|
||||
on-success: get_pubkey
|
||||
on-error: unset_validation_key_parameter
|
||||
|
||||
get_pubkey:
|
||||
action: tripleo.validations.get_pubkey
|
||||
on-success: set_validation_key_parameter
|
||||
publish:
|
||||
pubkey: <% task(get_pubkey).result %>
|
||||
|
||||
set_validation_key_parameter:
|
||||
action: tripleo.parameters.update
|
||||
input:
|
||||
parameters:
|
||||
node_admin_extra_ssh_keys: <% $.pubkey %>
|
||||
container: <% $.container %>
|
||||
|
||||
# NOTE(shadower): We need to clear keys from a previous deployment
|
||||
unset_validation_key_parameter:
|
||||
action: tripleo.parameters.update
|
||||
input:
|
||||
parameters:
|
||||
node_admin_extra_ssh_keys: ""
|
||||
container: <% $.container %>
|
||||
|
||||
copy_ssh_key:
|
||||
input:
|
||||
- overcloud_admin: heat-admin
|
||||
|
|
Loading…
Reference in New Issue