Skip to content

Set feature flag and create GraphQL app for Run Pipeline form

Mireya Andres requested to merge run-pipeline-graphql-ff into master

What does this MR do and why?

For #363660 (closed)

This sets up the foundation for migrating the Run Pipeline form to GraphQL. The GraphQL app is disabled behind the run_pipeline_graphql feature flag.

At the moment, legacy_pipeline_new_form.vue is just a copy of pipeline_new_form.vue.

No new changes were added. Apollo will be implemented in the actual migration MR in !96542 (merged).

MR Breakdown

The migration will be broken down into the following steps:

Implementation MR
Set up feature flag and GraphQL app 👈 You are here!
Migrate app to GQL and fetch predefined variables !96542 (merged)
Rollout feature flag #372310 (closed)

Screenshots or screen recordings

Run Pipeline Form should still work as normal.

Screen_Shot_2022-08-31_at_14.11.33

How to set up and validate locally

The following should work with the feature flage run_pipeline_graphql enabled and disabled.

  1. Add the following to you .gitlab-ci.yml config file:

    stages:
      - test
    
    variables:
      FOO:
        value: "BAR"
        description: "Environment variable declared from the CI config."
    
    declare-config-vars:
      stage: test
      script:
        - echo $FOO
        - echo $TEST_VAR
  2. Go to CI/CD > Pipelines then click on the Run Pipeline button on the upper right corner.

  3. Verify that the variable FOO is pre-filled in the form with the value BAR

  4. Add a new variable in the form called TEST_VAR.

  5. Click on the Run Pipeline button. This will create the pipeline with your variables and redirect you to the newly created pipeline.

  6. Wait for the pipeline to finish then check the job logs. The correct variable values should be printed in the logs.

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Mireya Andres

Merge request reports

Loading