mirror of
https://gitlab.com/components/sast.git
synced 2025-06-30 07:28:29 +02:00
Update file sast.yml
This commit is contained in:
parent
843eb13140
commit
0cee4e10b3
1 changed files with 3 additions and 21 deletions
|
@ -43,7 +43,7 @@ spec:
|
||||||
SAST_EXCLUDED_PATHS: "$DEFAULT_SAST_EXCLUDED_PATHS"
|
SAST_EXCLUDED_PATHS: "$DEFAULT_SAST_EXCLUDED_PATHS"
|
||||||
COMPILE: $[[ inputs.use_precompiled_artifacts ]]
|
COMPILE: $[[ inputs.use_precompiled_artifacts ]]
|
||||||
dependencies: $[[ inputs.spotbugs_dependencies ]]
|
dependencies: $[[ inputs.spotbugs_dependencies ]]
|
||||||
script:
|
script:
|
||||||
- /analyzer run
|
- /analyzer run
|
||||||
artifacts:
|
artifacts:
|
||||||
access: 'developer'
|
access: 'developer'
|
||||||
|
@ -130,10 +130,6 @@ spec:
|
||||||
- '**/application*.yaml'
|
- '**/application*.yaml'
|
||||||
- '**/bootstrap*.yaml'
|
- '**/bootstrap*.yaml'
|
||||||
|
|
||||||
.pmd-apex-exist-rules:
|
|
||||||
exists:
|
|
||||||
- '**/*.cls'
|
|
||||||
|
|
||||||
gitlab-advanced-sast:
|
gitlab-advanced-sast:
|
||||||
extends: .sast-analyzer
|
extends: .sast-analyzer
|
||||||
image:
|
image:
|
||||||
|
@ -191,23 +187,9 @@ pmd-apex-sast:
|
||||||
rules:
|
rules:
|
||||||
- if: '"$[[ inputs.excluded_analyzers ]]" =~ /pmd-apex/'
|
- if: '"$[[ inputs.excluded_analyzers ]]" =~ /pmd-apex/'
|
||||||
when: never
|
when: never
|
||||||
|
|
||||||
# The following 3 blocks of rules define whether the job runs in a an *MR pipeline* or a *branch pipeline*
|
|
||||||
# when an MR exists. If the job has additional rules to observe they should be added in the blocks 1 and 3
|
|
||||||
# to cover both the *MR pipeline* and the *branch pipeline* workflows.
|
|
||||||
|
|
||||||
# 1. Run the job in an *MR* pipeline if MR pipelines for AST are enabled and there's an open merge request.
|
|
||||||
- if: '"$[[ inputs.enable_mr_pipelines ]]" == "true" &&
|
|
||||||
$CI_PIPELINE_SOURCE == "merge_request_event"'
|
|
||||||
exists: !reference [.pmd-apex-exist-rules, exists]
|
|
||||||
|
|
||||||
# 2. Don't run the job in a *branch pipeline* if *MR pipelines* for AST are enabled and there's an open merge request.
|
|
||||||
- if: '"$[[ inputs.enable_mr_pipelines ]]" == "true" &&
|
|
||||||
$CI_OPEN_MERGE_REQUESTS'
|
|
||||||
when: never
|
|
||||||
# 3. Finally, run the job in a *branch pipeline* (When MR pipelines are disabled for AST, or it is enabled but no open MRs exist for the branch).
|
|
||||||
- if: $CI_COMMIT_BRANCH
|
- if: $CI_COMMIT_BRANCH
|
||||||
exists: !reference [.pmd-apex-exist-rules, exists]
|
exists:
|
||||||
|
- '**/*.cls'
|
||||||
|
|
||||||
security-code-scan-sast:
|
security-code-scan-sast:
|
||||||
extends: .sast-analyzer
|
extends: .sast-analyzer
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue