Add project attributes migration to GitLab Migration
What does this MR do and why?
Mentions #339416 (closed)
bulk_import_projects
feature flag that is currently off by default (and disabled on .com).
This MR adds Project Properties migration when using Group Migration that includes projects (https://docs.gitlab.com/ee/user/group/import/). Similar to other MRs from this series. This is suppose to work identical to file-based Project Import/Export.
List of migrated attributes:
description
visibility_level
archived
merge_requests_template
merge_requests_rebase_enabled
approvals_before_merge
reset_approvals_on_push
merge_requests_ff_only_enabled
issues_template
shared_runners_enabled
build_coverage_regex
build_allow_git_fetch
build_timeout
pending_delete
public_builds
last_repository_check_failed
only_allow_merge_if_pipeline_succeeds
has_external_issue_tracker
request_access_enabled
has_external_wiki
ci_config_path
only_allow_merge_if_all_discussions_are_resolved
printing_merge_request_link_enabled
auto_cancel_pending_pipelines
service_desk_enabled
delete_error
disable_overriding_approvers_per_merge_request
resolve_outdated_diff_discussions
jobs_cache_index
external_authorization_classification_label
pages_https_only
merge_requests_author_approval
merge_requests_disable_committers_approval
require_password_to_approve
remove_source_branch_after_merge
autoclose_referenced_issues
suggestion_commit_message
Screenshots or screen recordings
https://monosnap.com/file/h448vZGEhcldMt6NXqlqcYHJ2OMRID (recording is more than 10mb is size so could not upload it as an attachment).
How to set up and validate locally
-
Feature.enable(:bulk_import)
. -
Feature.enable(:bulk_import_projects)
. - Create a top level group and project in it.
- Update project attributes on general settings page
- Go to
/groups/new#import-group-pane
page and enter instance url and access token (needs to beapi
&read_repository
scope). - Select newly created group and click Import.
- Wait for Group import to complete and verify imported settings. They should be present and their values should be preserved.
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Edited by George Koltsov