GitLab
GitLab CI/CD: MR Preview Environments
- Applies to
- Gatewayruntime for API, AI, and MCP gateways
- Hosting
- Managed EdgeManaged DedicatedSelf-HostedDiffers
1 difference by hosting option
Self-Hosted
Add --self-hosted-endpoint with your management API hostname to each zuplo deploy and zuplo delete command so it targets your cluster. See zuplo deploy.
Deploy preview environments for merge requests and clean up when they close.
.gitlab-ci.yml
The deploy job passes --branch with the merge request's source branch,
CI_MERGE_REQUEST_SOURCE_BRANCH_NAME, and falls back to CI_COMMIT_REF_NAME
when the pipeline isn't a merge request pipeline. The cleanup job only runs for
merge request pipelines, deleting the environment by the same branch name after
tests pass.
Next Steps
- Implement multi-stage deployment for production
Last modified on