Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStan Hu <stanhu@gmail.com>2017-12-09 01:48:52 +0300
committerStan Hu <stanhu@gmail.com>2017-12-09 01:56:43 +0300
commit78f7c3c8a2ac9f72b54e8e76005ef8810d1a068a (patch)
tree7a732ba640c04f19622798c2f087b86b0f779e2d /lib/gitlab/bare_repository_import
parent806a68a81f1baeed07c146b1b5d9eb77796c46ba (diff)
Fix gitlab:import:repos Rake task moving repositories into the wrong location
If the source import directory were different from the destination directory, GitLab would first create a blank repository and then erroneously move the original one into a subdirectory. Adding an import type prevents this the project from being initialized in the first place. It was accidentally removed in 1f917cbd49. Closes #40765
Diffstat (limited to 'lib/gitlab/bare_repository_import')
-rw-r--r--lib/gitlab/bare_repository_import/importer.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/gitlab/bare_repository_import/importer.rb b/lib/gitlab/bare_repository_import/importer.rb
index 196de667805..298409d8b5a 100644
--- a/lib/gitlab/bare_repository_import/importer.rb
+++ b/lib/gitlab/bare_repository_import/importer.rb
@@ -55,6 +55,7 @@ module Gitlab
name: project_name,
path: project_name,
skip_disk_validation: true,
+ import_type: 'gitlab_project',
namespace_id: group&.id).execute
if project.persisted? && mv_repo(project)