2016-06-21 13:28:08 -04:00
|
|
|
# Project import/export
|
|
|
|
|
2016-06-22 05:31:07 -04:00
|
|
|
>**Notes:**
|
2016-06-21 14:07:52 -04:00
|
|
|
- This feature was [introduced][ce-3050] in GitLab 8.9
|
|
|
|
- Importing will not be possible if the import instance version is lower
|
|
|
|
than that of the exporter.
|
2016-06-22 05:05:34 -04:00
|
|
|
- For existing installations, the project import option has to be enabled in
|
|
|
|
application settings (`/admin/application_settings`) under 'Import sources'.
|
|
|
|
Ask your administrator if you don't see the **GitLab export** button when
|
|
|
|
creating a new project.
|
2016-06-21 14:07:52 -04:00
|
|
|
- You can find some useful raketasks if you are an administrator in the
|
2016-06-22 05:05:34 -04:00
|
|
|
[import_export](../../../administration/raketasks/project_import_export.md)
|
2016-06-21 14:07:52 -04:00
|
|
|
raketask.
|
2016-06-22 05:31:07 -04:00
|
|
|
- The exports are stored in a temporary [shared directory][tmp] and are deleted
|
|
|
|
every 24 hours by a specific worker.
|
2016-06-21 14:07:52 -04:00
|
|
|
|
2016-06-21 13:28:08 -04:00
|
|
|
Existing projects running on any GitLab instance or GitLab.com can be exported
|
|
|
|
with all their related data and be moved into a new GitLab instance.
|
|
|
|
|
|
|
|
## Exported contents
|
|
|
|
|
2016-06-21 14:07:52 -04:00
|
|
|
The following items will be exported:
|
2016-06-21 13:28:08 -04:00
|
|
|
|
2016-06-21 14:07:52 -04:00
|
|
|
- Project and wiki repositories
|
|
|
|
- Project uploads
|
|
|
|
- Project configuration including web hooks and services
|
|
|
|
- Issues with comments, merge requests with diffs and comments, labels, milestones, snippets,
|
|
|
|
and other project entities
|
2016-06-21 13:28:08 -04:00
|
|
|
|
2016-06-21 14:07:52 -04:00
|
|
|
The following items will NOT be exported:
|
2016-06-21 13:28:08 -04:00
|
|
|
|
2016-06-21 14:07:52 -04:00
|
|
|
- Build traces and artifacts
|
|
|
|
- LFS objects
|
2016-06-21 13:28:08 -04:00
|
|
|
|
2016-06-21 14:07:52 -04:00
|
|
|
## Exporting a project and its data
|
2016-06-21 13:28:08 -04:00
|
|
|
|
2016-06-22 05:15:28 -04:00
|
|
|
1. Go to the project settings page by clicking on **Edit Project**:
|
2016-06-21 13:28:08 -04:00
|
|
|
|
2016-06-21 14:07:52 -04:00
|
|
|
![Project settings button](img/settings_edit_button.png)
|
2016-06-21 13:28:08 -04:00
|
|
|
|
2016-06-22 05:15:28 -04:00
|
|
|
1. Scroll down to find the **Export project** button:
|
2016-06-21 13:28:08 -04:00
|
|
|
|
2016-06-21 14:07:52 -04:00
|
|
|
![export_1](./img/export_1.png)
|
2016-06-21 13:28:08 -04:00
|
|
|
|
2016-06-21 14:07:52 -04:00
|
|
|
1. Once the export is generated, you should receive an e-mail with a link to
|
2016-06-22 05:15:28 -04:00
|
|
|
download the file:
|
2016-06-21 13:28:08 -04:00
|
|
|
|
2016-06-21 14:07:52 -04:00
|
|
|
![export_3](./img/export_3.png)
|
2016-06-21 13:28:08 -04:00
|
|
|
|
2016-06-21 14:07:52 -04:00
|
|
|
1. Alternatively, you can come back to the project settings and download the
|
2016-06-22 05:15:28 -04:00
|
|
|
file from there, or generate a new export. Once the file available, the page
|
|
|
|
should show the **Download export** button:
|
2016-06-21 13:28:08 -04:00
|
|
|
|
2016-06-21 14:07:52 -04:00
|
|
|
![export_4](./img/export_4.png)
|
2016-06-21 13:28:08 -04:00
|
|
|
|
2016-06-21 14:07:52 -04:00
|
|
|
## Importing the project
|
2016-06-21 13:28:08 -04:00
|
|
|
|
2016-06-21 14:07:52 -04:00
|
|
|
1. The new GitLab project import feature is at the far right of the import
|
|
|
|
options when creating a New Project. Make sure you are in the right namespace
|
2016-06-22 05:15:28 -04:00
|
|
|
and you have entered a project name. Click on **GitLab export**:
|
2016-06-21 13:28:08 -04:00
|
|
|
|
2016-06-21 14:07:52 -04:00
|
|
|
![import_1](./img/import_1.png)
|
2016-06-21 13:28:08 -04:00
|
|
|
|
2016-06-21 14:07:52 -04:00
|
|
|
1. You can see where the project will be imported to. You can now select file
|
2016-06-22 05:15:28 -04:00
|
|
|
exported previously:
|
2016-06-21 13:28:08 -04:00
|
|
|
|
2016-06-21 14:07:52 -04:00
|
|
|
![import_2](./img/import_2.png)
|
2016-06-21 13:28:08 -04:00
|
|
|
|
2016-06-21 14:07:52 -04:00
|
|
|
1. Click on **Import project** to begin importing. Your newly imported project
|
2016-06-22 05:31:07 -04:00
|
|
|
page will appear soon.
|
2016-06-21 13:28:08 -04:00
|
|
|
|
|
|
|
[ce-3050]: https://gitlab.com/gitlab-org/gitlab-ce/issues/3050
|
2016-06-22 05:31:07 -04:00
|
|
|
[tmp]: ../../../development/shared_files.md
|