diff options
author | James Edwards-Jones <jedwardsjones@gitlab.com> | 2017-04-04 02:19:04 +0100 |
---|---|---|
committer | James Edwards-Jones <jedwardsjones@gitlab.com> | 2017-04-04 02:19:04 +0100 |
commit | 3bb3a6886f3b206a2ec089d6b1e8854615daa0b8 (patch) | |
tree | b3b712e972df4d8adf6c242c8e10abdbafd27f84 | |
parent | 1e15444ae6dda02744db42d08c817252953c7b1f (diff) | |
download | gitlab-ce-3bb3a6886f3b206a2ec089d6b1e8854615daa0b8.tar.gz |
Attempt to fix import/export of push_access_levels for protected tags
-rw-r--r-- | lib/gitlab/import_export/import_export.yml | 2 | ||||
-rw-r--r-- | lib/gitlab/import_export/relation_factory.rb | 3 | ||||
-rw-r--r-- | spec/lib/gitlab/import_export/all_models.yml | 5 |
3 files changed, 9 insertions, 1 deletions
diff --git a/lib/gitlab/import_export/import_export.yml b/lib/gitlab/import_export/import_export.yml index ab74c8782f6..7bf5568a8ee 100644 --- a/lib/gitlab/import_export/import_export.yml +++ b/lib/gitlab/import_export/import_export.yml @@ -46,6 +46,8 @@ project_tree: - protected_branches: - :merge_access_levels - :push_access_levels + - protected_tags: + - :push_access_levels - :project_feature # Only include the following attributes for the models specified. diff --git a/lib/gitlab/import_export/relation_factory.rb b/lib/gitlab/import_export/relation_factory.rb index 9d269c5d384..b1d8e385f2e 100644 --- a/lib/gitlab/import_export/relation_factory.rb +++ b/lib/gitlab/import_export/relation_factory.rb @@ -7,8 +7,9 @@ module Gitlab triggers: 'Ci::Trigger', builds: 'Ci::Build', hooks: 'ProjectHook', - merge_access_levels: 'ProtectedBranch::MergeAccessLevel', #TODO: Tags + merge_access_levels: 'ProtectedBranch::MergeAccessLevel', push_access_levels: 'ProtectedBranch::PushAccessLevel', + #TODO: How to add?- push_access_levels: 'ProtectedTag::PushAccessLevel', labels: :project_labels, priorities: :label_priorities, label: :project_label }.freeze diff --git a/spec/lib/gitlab/import_export/all_models.yml b/spec/lib/gitlab/import_export/all_models.yml index ddeb71730e7..83503c73e75 100644 --- a/spec/lib/gitlab/import_export/all_models.yml +++ b/spec/lib/gitlab/import_export/all_models.yml @@ -111,10 +111,14 @@ protected_branches: - project - merge_access_levels - push_access_levels +protected_tags: +- project +- push_access_levels merge_access_levels: - protected_branch push_access_levels: - protected_branch +- protected_tag project: - taggings - base_tags @@ -169,6 +173,7 @@ project: - snippets - hooks - protected_branches +- protected_tags - project_members - users - requesters |