File tree Expand file tree Collapse file tree 1 file changed +9
-2
lines changed Expand file tree Collapse file tree 1 file changed +9
-2
lines changed Original file line number Diff line number Diff line change @@ -41,11 +41,18 @@ variables:
4141 REPO_NAME : $[ resources.repositories['azure-container-networking'].name ]
4242 REPO_TYPE : $[ resources.repositories['azure-container-networking'].type ]
4343 CHANGESET_COMMIT : $[ resources.repositories['self'].version ]
44+ # Local analysis is only enabled on PR branches
45+ Codeql.AnalyzeInPipeline : $[startsWith(variables['Build.SourceBranch'], 'refs/pull/')]
4446
4547extends :
4648 template : v1/1ES.Unofficial.PipelineTemplate.yml@1ESPipelineTemplates
4749 parameters :
48- pool :
49- name : " $(BUILD_POOL_NAME_DEFAULT)"
50+ codeql :
51+ # Enables CodeQL on the main branch
52+ compiled :
53+ enabled : true
54+ # Enables CodeQL on PR branches
55+ ${{ if startsWith(variables['Build.SourceBranch'], 'refs/pull/')) }} :
56+ enabledOnNonDefaultBranches : true
5057 stages :
5158 - template : /.pipelines/pipeline.yaml@azure-container-networking
You can’t perform that action at this time.
0 commit comments