Mirroring
Operations workflow page for the GitLab mirroring setup
Process
To setup mirroring in a secure and scalable way, use the following steps:
- Login as the
gl-support-bot
user - Navigate to the source project
- Add a new mirror
- Git repository URL:
ssh://gitlab.com/full/path/to/project.git
- Mirror direction:
Push
- Authentication method:
SSH public key
- Username:
git
- Keep divergent refs: unchecked
- Mirror branches:
Mirror only protected branches
- Git repository URL:
- Copy SSH public key from new mirror
- Navigate to the target project
- Add a new deploy key (under
Settings > Repository > Deploy Keys
)- Title:
full/path/to/project
- Key: The value copied in step 4
- Grant write permissions to this key: checked
- Expiration date (optional): leave it blank
- Title:
- Navigate to the source project
- Force an update on the mirror (under
Settings > Repository > Mirroring repositories
)
Last modified May 20, 2025: Adding mirroring information (
c8424fbd
)