i am trying the gitlab default secret detection option.
here is Gitlab CI
file i am trying
include:
- template: Security/Secret-Detection.gitlab-ci.yml
stages:
- test
test:
stage: test
artifacts:
reports:
secret_detection: gl-secret-detection-report.json
script:
- pwd
- ls
- cat gl-secret-detection-report.json
i am not getting the file as artifacts.
error i am getting is :
cat: can't open 'gl-secret-detection-report.json': No such file or directory
Cleaning up file based variables
00:01
ERROR: Job failed: exit code 1
however in default stage of Gitlab it is creating the file
Uploading artifacts for successful job
00:03
Uploading artifacts...
gl-secret-detection-report.json: found 1 matching files and directories
Uploading artifacts as "secret_detection" to coordinator... ok id=1asdfas239 responseStatus=201 Created token=jT28Z-ot
Cleaning up file based variables
00:00
Job succeeded
so secret_detection
stage is working which is default using template.