Skip to content

Commit e67b484

Browse files
committed
CI: Collect diagnostic information at end of aio jobs
Use the new diagnostics.yml playbook.
1 parent a6d4a84 commit e67b484

File tree

1 file changed

+21
-2
lines changed

1 file changed

+21
-2
lines changed

.github/workflows/stackhpc-all-in-one.yml

Lines changed: 21 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -179,6 +179,7 @@ jobs:
179179
OS_APPLICATION_CREDENTIAL_SECRET: ${{ secrets.OS_APPLICATION_CREDENTIAL_SECRET }}
180180

181181
- name: Terraform Apply
182+
id: tf_apply
182183
run: |
183184
for attempt in $(seq 5); do
184185
if terraform apply -auto-approve; then
@@ -355,6 +356,7 @@ jobs:
355356
if: inputs.upgrade
356357

357358
- name: Tempest tests
359+
id: tempest
358360
run: |
359361
mkdir -p tempest-artifacts
360362
docker run -t --rm \
@@ -366,11 +368,28 @@ jobs:
366368
env:
367369
KAYOBE_AUTOMATION_SSH_PRIVATE_KEY: ${{ steps.ssh_key.outputs.ssh_key }}
368370

371+
- name: Collect diagnostic information
372+
id: diagnostics
373+
run: |
374+
mkdir -p diagnostics
375+
sudo -E docker run -t --rm \
376+
-v $(pwd):/stack/kayobe-automation-env/src/kayobe-config \
377+
-v $(pwd)/diagnostics:/stack/diagnostics \
378+
-e KAYOBE_ENVIRONMENT -e KAYOBE_VAULT_PASSWORD -e KAYOBE_AUTOMATION_SSH_PRIVATE_KEY \
379+
$KAYOBE_IMAGE \
380+
/stack/kayobe-automation-env/src/kayobe-config/.automation/pipeline/playbook-run.sh '$KAYOBE_CONFIG_PATH/ansible/diagnostics.yml'
381+
env:
382+
KAYOBE_AUTOMATION_SSH_PRIVATE_KEY: ${{ steps.ssh_key.outputs.ssh_key }}
383+
if: ${{ !cancelled() && steps.tf_apply.outcome == 'success' }}
384+
369385
- name: Upload test result artifacts
370386
uses: actions/upload-artifact@v4
371387
with:
372-
name: tempest-results-${{ inputs.os_distribution }}-${{ inputs.os_release }}-${{ inputs.neutron_plugin }}${{ inputs.upgrade && '-upgrade' }}
373-
path: tempest-artifacts/*
388+
name: test-results-${{ inputs.os_distribution }}-${{ inputs.os_release }}-${{ inputs.neutron_plugin }}${{ inputs.upgrade && '-upgrade' || '' }}
389+
path: |
390+
diagnostics/
391+
tempest-artifacts/
392+
if: ${{ !cancelled() && (steps.tempest.outcome == 'success' || steps.diagnostics.outcome == 'success') }}
374393

375394
- name: Fail if any Tempest tests failed
376395
run: |

0 commit comments

Comments
 (0)