diff --git a/app/models/ci/runner.rb b/app/models/ci/runner.rb index ac9f04bb3d4..5cec88660f8 100644 --- a/app/models/ci/runner.rb +++ b/app/models/ci/runner.rb @@ -120,8 +120,9 @@ module Ci raise ArgumentError, 'Transitioning a group runner to a project runner is not supported' end - self.projects << project + runner_project = project.runner_projects.create(runner_id: self.id) self.save! + runner_project end def display_name