[FE] Update rule mode for template: latest and target options
Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.
Why are we doing this work
- When
templateis set tolatestand the scan execution condition is set totarget_default/target_protected, onlymerge_request_event/pushare supportedpipeline_sources - Currently the UI removes all other
pipeline_sources - Allow the rule mode to allow users to update the template and have the conditions automatically update as to not put the users in a misconfigured state
scan_execution_policy:
- name: Any target default branch
description: ''
enabled: true
actions:
- scan: secret_detection
template: default
variables:
SECURE_ENABLE_LOCAL_CONFIGURATION: 'false'
rules:
- type: pipeline
branch_type: target_default
pipeline_sources:
including:
- api
skip_ci:
allowed: true
I think this is the expected behaviour because the latest template always use merge request pipeline to run the security scan (docs) and creating a pipeline through API does not trigger a merge request pipeline.
Relevant links
Non-functional requirements
-
Documentation: -
Feature flag: -
Performance: -
Testing:
Implementation plan
-
frontend when the action is updated, update the condition
Verification steps
Edited by 🤖 GitLab Bot 🤖