Interview Prep/CI/CD/Jenkins Build and Agent Failures

A pipeline using `archiveArtifacts` fails with `ERROR: No artifacts found that match the file pattern`.

BeginnerTroubleshootingJenkins Build and Agent Failures
Answer

Likely causes → Build output path differs; the build failed earlier; the file is outside the workspace.

Diagnose → ls -R in the workspace before archiving.

Fix → Correct the Ant-style pattern (target/*.jar).

Prevent → Print the artifact path as part of the build step.

All CI/CD questions Roadmap: CI/CD fundamentals

More on Jenkins Build and Agent Failures