Commit 1574ffca authored by Achilleas Pipinellis's avatar Achilleas Pipinellis

Port repository mirroring from EE

parent a10c5e72
# Repository mirroring # Repository mirroring
Repository Mirroring is a way to mirror repositories from external sources. Repository mirroring is a way to mirror repositories from external sources.
It can be used to mirror all branches, tags, and commits that you have It can be used to mirror all branches, tags, and commits that you have
in your repository. in your repository.
...@@ -34,7 +34,7 @@ A few things/limitations to consider: ...@@ -34,7 +34,7 @@ A few things/limitations to consider:
- The Git LFS objects will not be synced. You'll need to push/pull them - The Git LFS objects will not be synced. You'll need to push/pull them
manually. manually.
## Use-cases ## Use cases
- You migrated to GitLab but still need to keep your project in another source. - You migrated to GitLab but still need to keep your project in another source.
In that case, you can simply set it up to mirror to GitLab (pull) and all the In that case, you can simply set it up to mirror to GitLab (pull) and all the
...@@ -294,11 +294,12 @@ by using the **Update now** button which is exposed in various places: ...@@ -294,11 +294,12 @@ by using the **Update now** button which is exposed in various places:
## Bidirectional mirroring ## Bidirectional mirroring
> **Warning:** There is no bidirectional support without conflicts. If you CAUTION: **Warning:**
> configure a repository to pull and push to a second remote, there is no There is no bidirectional support without conflicts. If you
> guarantee that it will update correctly on both remotes. If you configure configure a repository to pull and push to a second remote, there is no
> a repository for bidirectional mirroring, you should consider when conflicts guarantee that it will update correctly on both remotes. If you configure
> occur who and how they will be resolved. a repository for bidirectional mirroring, you should consider when conflicts
occur who and how they will be resolved.
Rewriting any mirrored commit on either remote will cause conflicts and Rewriting any mirrored commit on either remote will cause conflicts and
mirroring to fail. This can be prevented by [only pulling protected branches]( mirroring to fail. This can be prevented by [only pulling protected branches](
...@@ -318,10 +319,11 @@ custom Git hooks][hooks] on the GitLab server. ...@@ -318,10 +319,11 @@ custom Git hooks][hooks] on the GitLab server.
### Mirroring with Perforce via GitFusion ### Mirroring with Perforce via GitFusion
> **Warning:** Bidirectional mirroring should not be used as a permanent CAUTION: **Warning:**
> configuration. There is no bidirectional mirroring without conflicts. Bidirectional mirroring should not be used as a permanent
> Refer to [Migrating from Perforce Helix][perforce] for alternative migration configuration. There is no bidirectional mirroring without conflicts.
> approaches. Refer to [Migrating from Perforce Helix][perforce] for alternative migration
approaches.
GitFusion provides a Git interface to Perforce which can be used by GitLab to GitFusion provides a Git interface to Perforce which can be used by GitLab to
bidirectionally mirror projects with GitLab. This may be useful in some bidirectionally mirror projects with GitLab. This may be useful in some
...@@ -339,10 +341,11 @@ limitations of GitFusion. ...@@ -339,10 +341,11 @@ limitations of GitFusion.
[ee-3326]: https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/3326 [ee-3326]: https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/3326
[ee-3350]: https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/3350 [ee-3350]: https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/3350
[ee-3453]: https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/3453 [ee-3453]: https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/3453
[ee-4559]: https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/4559
[ce-18715]: https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/18715 [ce-18715]: https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/18715
[perms]: ../user/permissions.md [perms]: ../user/permissions.md
[hooks]: ../administration/custom_hooks.html [hooks]: ../administration/custom_hooks.md
[deploy-key]: ../ssh/README.md#deploy-keys [deploy-key]: ../ssh/README.md#deploy-keys
[webhook]: ../user/project/integrations/webhooks.html#push-events [webhook]: ../user/project/integrations/webhooks.md#push-events
[pull-api]: ../api/projects.html#start-the-pull-mirroring-process-for-a-project [pull-api]: ../api/projects.md#start-the-pull-mirroring-process-for-a-project
[perforce]: ../user/project/import/perforce.html [perforce]: ../user/project/import/perforce.md
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment