Skip to content
GitLab
Next
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • GitLab GitLab
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Locked Files
  • Issues 44,763
    • Issues 44,763
    • List
    • Boards
    • Service Desk
    • Milestones
    • Iterations
    • Requirements
  • Merge requests 1,329
    • Merge requests 1,329
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
    • Test Cases
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Container Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Metrics
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Code review
    • Insights
    • Issue
    • Repository
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • GitLab.orgGitLab.org
  • GitLabGitLab
  • Issues
  • #276930
Closed
Open
Issue created Nov 05, 2020 by Kassio Borges@kassio2️⃣Developer

Allow project import even when `shared_runners_enabled` conflicts with its group

Problem

About the new feature allowing to enable/disable shared runners and project import, If shared runners are disabled for a group on destination (or on a gitlab.com parent group), it does not allow projects to import, mainly because field shared_runners_enabled=<boolean> conflicts on import (by just being part of the exported archive) and returns:

"import_error": "Error importing repository into <group-full-path> - Validation failed: Shared runners enabled cannot be enabled because parent group does not allow it"
  • being rescued on this line - http://gitlab.com/gitlab-org/gitlab/blob/b228b1568657c2a5d5724e6c7eca899bd47193e2/lib/gitlab/import_export/importer.rb#L32-32
  • some issue importing file - http://gitlab.com/gitlab-org/gitlab/blob/b228b1568657c2a5d5724e6c7eca899bd47193e2/lib/gitlab/import_export/importer.rb#L48-48
  • validation introduced in !36080 (merged)

Proposed solution

  • Keep project value if Allow projects and subgroups to override the group setting is set, as it already does
  • Otherwise inherit group setting of disabled, if a project has enabled set
  • Keep project setting of enabled/disabled, if group setting is enabled.

Workaround

Either:

  • Ensure that shared runners is enabled on the parent group on the destination GitLab instance. Then retry the import.
  • Disable shared runners on the project on the source GitLab instance and then export the project again. Then retry the import.
Edited Oct 06, 2021 by Doug Stull
Assignee
Assign to
Time tracking