Dependency scanning job isn't writing to json file

I’ve got a simple dependency_scan job using npm install/audit following the instructions here -


  • template: Jobs/Dependency-Scanning.gitlab-ci.yml

stage: test
- npm install
dependency_scanning: gl-dependency-scanning-report.json
allow_failure: true`

It’s not writing to the json file and it’s outputting seemingly quite popular warning -

Uploading artifacts... gl-dependency-scanning-report.json: found 1 matching artifact files and directories WARNING: Upload request redirected location= new-url= WARNING: Retrying... context=artifacts-uploader error=request redirected Uploading artifacts as "dependency_scanning" to coordinator... 201 Created id=6951641315 responseStatus=201 Created token=glcbt-65 Cleaning up project directory and file based variables

Is it not possible to do this, and, how do I avoid these warnings?

Versions GitLab Enterprise Edition 17.1.0-pre fe0a1083c72

You have overridden the script which is used in the dependency scanning template to run the analyzer.

Try using before_script instead.

ahhhh, now I get it, wasn’t sure what you. meant in you post on my bug report, thnx!