I tried following these fairly simple instructions for integrating Static Application Security Testing (SAST) into my Android CI/CD pipeline on Gitlab. However, I got the following error when using the CI lint tool:
sast job: chosen stage does not exist; available stages are .pre, stg_build, stg_test, .post
Here is the simplest version of my .gitlab-ci.yml that reproduces the error:
include:
- template: Security/SAST.gitlab-ci.yml
variables:
SAST_EXPERIMENTAL_FEATURES: "true"
stages:
- stg_build
- stg_test
I found a similar error in GitLab: chosen stage does not exist but that was about trying to use an environment variable as a stage name.
How do I prevent this error and get SAST working for my merge requests on Gitlab?