---
sourceDocument: Brazil IT Service Management
sourceDocumentLink: https://www.servicenow.com/docs/r/it-service-management

 Release :

    - brazil

ft:locale :

    - en-US

ft:publication_title :

    - Brazil IT Service Management

ft:clusterId :

    - itsm

bundleId :

    - itsm

workflow :

    - Technology


---

# GitLab pull request configurations

# GitLab pull request configurations {#ariaid-title1}

Release version: Brazil  
Updated September 10, 2026  
![](https://www.servicenow.com/docs/portal-asset/ico-clock) 2 minutes to read
Summarize  
![AI sparkle icon](https://servicenow.com/docs/portal-asset/ai-sparkle-icon) Summarized using AI  
This content was generated using new OpenAI-powered functionality. Results are provided on an as is basis and are not guaranteed to be accurate or complete.  

## Summary of GitLab pull request configurations

This configuration enables integration of GitLab pull (merge) request pipeline executions with ServiceNow DevOps Change Velocity.
It allows tracking of GitLab merge request metadata linked to changes, facilitating change acceleration, policy enforcement, review, and approval before deployment to production.
Show full answer Show less  

## Key Features

* Supports create, update, close, re-open, and merge of pull requests.
* Pull request pipeline executions are integrated with change acceleration workflows in GitLab pipelines.
* Pull request details can be used within change approval policies in DevOps Change Velocity.
* Status synchronization: GitLab pipeline status automatically updates based on pull request status after change creation.
* Automatic pausing and resuming of pipelines during change approval.
* Default email format for users is \<username\>@noreply.gitlab.com.
* Supports comments on merge requests; only the latest comment is shown.
* Up to 100 commits are displayed in DevOps Change Velocity; more must be viewed directly in GitLab.

## Configuration and Enablement

* Enable tracking of GitLab pull (merge) requests in DevOps Change Velocity using the property **Enable to track GitLab pull (merge) requests**, which is enabled by default. Disabling this property stops tracking.
* Requirements for change approval tracking and pipeline linking:
  * Use GitLab Docker for change tracking (see documentation on implementing custom pipeline actions with Docker).
  * In GitLab project settings (Cloud: **Settings \> Merge requests** , On-premises 13.x: **Settings \> General \> Merge requests** ), select **Pipelines must succeed** to block merges until change approval.
  * Add specific rules in the GitLab pipeline YAML (.yml) file at either pipeline or job level to detect merge request events, using conditions on `$CIPIPELINESOURCE` for 'mergerequestevent'.

## Practical Outcomes for ServiceNow Customers

By configuring GitLab pull request integration as described, ServiceNow customers can:

* Ensure that code merges are governed by change approval policies within DevOps Change Velocity, improving governance and risk control.
* Track merge request lifecycle and pipeline execution statuses seamlessly between GitLab and ServiceNow.
* Automate pipeline pausing/resuming based on change approval status, reducing manual intervention.
* Leverage merge request metadata and comments within change records for enhanced visibility and auditability.  
GitLab pull (merge) request pipeline executions, which goes through change acceleration before moving to production, can be tracked in DevOps Change Velocity. This integration also collects GitLab merge requests meta data to persist in DevOps Change Velocity. The data is linked with the change created in the merge request pipeline execution and can be used for applying change policies, review, and approval.
* Create, update, close, re-open, and merge of pull requests are supported.
* Pull request pipeline execution for change acceleration in GitLab pipelines is supported. Pull request details will be available for use in the change approval policy.
* Status of GitLab pipeline is updated with the pull request status automatically after the change creation. The pipeline is paused and resumed automatically.
* Email ids are defaulted to the format \<user_name\>@noreply.gitlab.com.
* Comments are supported as part of merge request support. Create and update to pull requests are supported, while delete and edit are not supported.
* Maximum of 100 commits will be shown in DevOps Change Velocity. If you need to access more than 100, you must refer your GitLab instance. Only the latest comment is populated.
{#gitlab-pull-request-config__ul_o4n_1n3_51c}

## Settings to enable pull (merge) requests for change approval {#gitlab-pull-request-config__section_xbk_tf3_51c}

The DevOps property Enable to track GitLab pull (merge) requests. If not enabled, then pull (merge) requests and related events will be ignored enables the tracking of pull (merge) requests from GitLab in DevOps Change Velocity.  
Note:  
The property is enabled by default. If you don't want the merge (pull) requests to be tracked, you must disable it.

When enabled, the pull (merge) request changes will be reflected in DevOps Change Velocity. When disabled, DevOps Change Velocity ignores the pull request events.  
For pull request and orchestration pipeline linking and to enable change approval tracking, the following are required:

* Use GitLab Docker for change tracking. For detailed information, see [Implement custom actions for pipelines using Docker image](https://www.servicenow.com/docs/oIV2FYmWT5DYMxpbQMBzDQ "Use the ServiceNow custom actions to collect data related to change request creation, Sonar scan, artifact registration, and package registration in your pipeline with the help of the generic Docker Container Image.").
* From your GitLab project,
  1. Navigate to
     * For GitLab cloud: SettingsMerge requests.
     * For On premises (13.x): SettingsGeneralMerge requests.
     {#gitlab-pull-request-config__ul_tzw_xg3_51c}
  2. Select the Pipelines must succeed check box.

     With this selection, only if the change is approved, you can proceed with the merge request. That is, when the check box is selected, pull requests will
     be blocked until the change is approved.

  3. Select Save changes.
  {#gitlab-pull-request-config__ol_snt_ch3_51c}
* Navigate to your project and open the .yml file.  
  To the .yml file, add the following rule at the pipeline level or at specific job levels.

      rules:
       - if: $CI_PIPELINE_SOURCE == 'merge_request event'
       - if: $CI_PIPELINE_SOURCE != 'merge_request_event'

  Example for pipeline level:

      workflow:
        rules:
        - if: $CI_PIPELINE_SOURCE == 'merge_request_event'
        - if: $CI_PIPELINE_SOURCE != 'merge_request_event' 

  Example for job level:

      changeapproval:
         stage: changeapproval
         script:
           - sndevopscli create change -p '{"changeStepDetails":{"timeout":3600,"interval":100},"attributes":{"short_description":"Automated Software Deployment","description":"Automated Software Deployment.","assignment_group":"a715cd759f2002002920bde8132e7018","implementation_plan":"Software update is tested and results can be found in Test Summaries Tab.","backout_plan":"When software fails in production, the previous software release will be re-deployed.","test_plan":"Testing if the software was successfully deployed or not"}}'
         rules:
         - if: $CI_PIPELINE_SOURCE == 'merge_request_event'
         - if: $CI_PIPELINE_SOURCE != 'merge_request_event'

{#gitlab-pull-request-config__ul_wkm_x1j_51c}

*[\>]: and then


