Manuals / CI/CD Pipelines / Chapter 5
B · Security & Config · intermediate · Week 3 · Chapter 5 of 12
Artifacts, reports & debugging CI
When CI fails, artifacts (test reports, screenshots, traces) tell the story. Upload on failure; retention policies matter.
Path progress35%
Step 1 of 4
Upload test report
actions/upload-artifact@v4 with if: failure() — HTML report, screenshots, logs.
Example
- uses: actions/upload-artifact@v4
if: failure()
with:
name: test-report
path: reports/
retention-days: 14Do this now
Configure artifact upload on test failure. Download from Actions UI.
Was this step clear?
Chapter learning outcomes
- upload-artifact
- Download artifacts
- Retention days
- Re-running jobs
Clear these before you leave
Side quest
Failure postmortem
Template in CI.md: incident, root cause, fix, prevention.