debug logging
Setting CI_DEBUG_TRACE to true, which makes a job log every shell command and every variable it can see.
The log shows every variable, so a debug log can leak secrets.
In more detail
It helps find out why a script behaves differently in the pipeline. The log then contains the values of all variables, so it can expose secrets, and GitLab restricts who can read such a log. Turn it on for one job, briefly, and off again.
Related terms
- masked variable — A CI/CD variable whose value GitLab replaces with [MASKED] wherever it appears in a job log.
- predefined CI/CD variables — Variables GitLab sets in every job, such as CI_COMMIT_BRANCH, CI_COMMIT_SHA and CI_REGISTRY_IMAGE, describing the pipeline, the commit and the project.
Taught in
- Debugging Pipelines: The Graph, The Errors, The Logs — GitLab Certified CI/CD Associate Exam Prep