Interview Prep/CI/CD/Jenkins Credentials, Plugins and Controller Issues

Build log is full of `[Pipeline] // withCredentials` but secrets show as `****` inside curl output; the API rejects them.

IntermediateTroubleshootingJenkins Credentials, Plugins and Controller Issues
Answer

Likely causes → Token contains trailing newline or whitespace copied into the credential; wrong secret type.

Diagnose → printf '%s' "$TOKEN" | wc -c and | od -c.

Fix → Re-create the credential without trailing newline; use Secret text for tokens.

Prevent → Add a token validity check as the first step.

All CI/CD questions

More on Jenkins Credentials, Plugins and Controller Issues