Global InfraGlobal Infra Cloud

change-pipeline (chgp)

Manage changes from GitLab pipelines.

Edit

Manage changes from GitLab pipelines. This command is designed to be called from CI/CD pipelines to track change management workflows.

Subcommands

SubcommandDescription
createCreate a new change (or attach a pipeline to an existing one)
approveApprove a change
implementStart implementation of a change
completeMark a change as done

Flags

Command-level flags

These flags apply to all change-pipeline subcommands:

FlagEnv VarRequiredDefaultDescription
--gitlab-urlCI_SERVER_URLYesGitLab instance URL
--gitlab-project-idCI_PROJECT_IDYesGitLab project id
--gitlab-shaCI_COMMIT_SHAYesGit commit SHA
--gitlab-pipeline-idCI_PIPELINE_IDYesGitLab pipeline id
--gitlab-merge-request-idCI_MERGE_REQUEST_IDNoGitLab merge request id
--gitlab-merge-request-iidCI_MERGE_REQUEST_IIDNoGitLab merge request iid
--gitlab-pipeline-urlCI_PIPELINE_URLYesGitLab pipeline URL
--workflowCHANGE_WORKFLOWNotagWorkflow type: tag or merge request

create flags

FlagAliasEnv VarRequiredDefaultDescription
--template-file--tfCHANGE_TEMPLATE_FILENo.change.ymlPath to YAML template file
--nameCHANGE_NAMEYesChange name
--processCHANGE_PROCESS_IDYesChange process
--platformCHANGE_PLATFORMYesTargeted platform
--descriptionCHANGE_DESCRIPTIONNoChange description
--impactCHANGE_IMPACTNoChange impact
--componentsCHANGE_COMPONENTSNoComponents (comma separated)
--tenantCHANGE_TENANTNoTenant linked to the change
--implementorsCHANGE_IMPLEMENTORSNoImplementor emails (comma separated)
--communication-planCHANGE_COMMUNICATION_PLANNoCommunication plan
--monitoring-planCHANGE_MONITORING_PLANNoMonitoring plan
--change-planCHANGE_CHANGE_PLANNoDescription of the change plan
--test-planCHANGE_TEST_PLANNoTest plan
--rollback-planCHANGE_ROLLBACK_PLANNoRollback plan
--start-timeCHANGE_START_TIMENoScheduled start time (RFC 3339)
--end-timeCHANGE_END_TIMENoScheduled end time (RFC 3339)
--dataCHANGE_DATANoJSON data for the change
--data-file-pathCHANGE_DATA_FILE_PATHNoPath to JSON data file
--data-allow-json-schema-errorsCHANGE_DATA_ALLOW_JSON_SCHEMA_ERRORSNotrueAllow JSON schema errors
--idCHANGE_IDNoExisting change id to attach pipeline to

.change.yml Template File

Instead of passing every flag, you can define change parameters in a .change.yml file at the root of your repository. Flags and env vars take precedence over template values.

name: "Firewall upgrade v2.14"
process: "standard"
platform: "prod-emea"
description: "Upgrade firewall firmware to version 2.14.0"
impact: "Temporary connectivity loss (< 5 min)"
components: "firewall,network"
tenant: "acme-prod"
implementors:
  - "alice@example.com"
  - "bob@example.com"
communication_plan: "Slack message to #ops-changes"
monitoring_plan: "Monitor firewall dashboard for 1 hour"
change_plan: "Upgrade firewall firmware to v2.14.0"
test_plan: "Run connectivity tests after upgrade"
rollback_plan: "Downgrade to v2.13.0 if tests fail"
data:
  firmware_version: "2.14.0"
  previous_version: "2.13.0"

Examples

# Create a change from CI (env vars auto-populated by GitLab)
gi chgp create --name "Deploy v1.5" --process standard --platform prod-emea

# Create using a template file
gi chgp create --template-file .change.yml

# Attach pipeline to an existing change
gi chgp create --name "Deploy v1.5" --process standard --platform prod-emea --id CHG-12345

# Approve, implement, and complete a change
gi chgp approve
gi chgp implement
gi chgp complete

On this page