summaryrefslogtreecommitdiff
path: root/doc/user/project/settings/import_export.md
blob: a460ff453dbf82694bc8f3ad4ab0b010b20d68df (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
# Project import/export

>**Notes:**
  - 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.
  - 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.
  - You can find some useful raketasks if you are an administrator in the
    [import_export](../../../administration/raketasks/project_import_export.md)
    raketask.
  - The exports are stored in a temporary [shared directory][tmp] and are deleted
    every 24 hours by a specific worker.

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

The following items will be exported:

- 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

The following items will NOT be exported:

- Build traces and artifacts
- LFS objects

## Exporting a project and its data

1. Go to the project settings page by clicking on **Edit Project**:

    ![Project settings button](img/settings_edit_button.png)

1. Scroll down to find the **Export project** button:

    ![export_1](./img/export_1.png)

1. Once the export is generated, you should receive an e-mail with a link to
   download the file:

    ![export_3](./img/export_3.png)

1. Alternatively, you can come back to the project settings and download the
   file from there, or generate a new export. Once the file available, the page
   should show the **Download export** button:

    ![export_4](./img/export_4.png)

## Importing the project

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
   and you have entered a project name. Click on **GitLab export**:

    ![import_1](./img/import_1.png)

1. You can see where the project will be imported to. You can now select file
   exported previously:

    ![import_2](./img/import_2.png)

1. Click on **Import project** to begin importing. Your newly imported project
   page will appear soon.

[ce-3050]: https://gitlab.com/gitlab-org/gitlab-ce/issues/3050
[tmp]: ../../../development/shared_files.md