Follow-up work for Ci::Workloads abstraction
Extracted from discussions at !176742 (comment 2315155725)
TODO
-
Prevent the creation of a normal pipeline when creating the new branch for a workload. See also !176742 (comment 2352831812) -
Add validations to our Workloadclass -
Refactor other code paths to use Workload:-
On-demand DAST scan (triggers a once-off job) -
On-demand DAST validation (triggers a once-off job) -
Container Scan when new container image is pushed to the repository -
Slash commands for chatops
-
-
Extract lowest common denominator API for above use cases. Consider a Ci::Workloads::SimplifiedWorkload < Ci::Workloads::Workloadthat takes a minimal API and constructs theci_jobfor you -
Implement a POC for how we might run this on top of CI step runner to prove out the flexibility of this approach and set boundaries for the APIs -
Implement a POC which decouples the features from the Pipeline object. Try to always use a Workload as an intermediate object (possibly via foreign key) to access whatever we need from the Pipeline. -
Make expand: falsedefault for all YAML variables -
We have Pipeline.disable_variables_sourceswhich disables variables for specific pipeline sources but we should ideally disable it by default for all workloads to reduce coupling with CI variables. -
Simplify the allow/deny code paths for all CI variables . See the conversation started at !176742 (comment 2351213490)
Edited by Dylan Griffith (ex GitLab)