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:
Diffstat (limited to 'app/models/clusters/applications/runner.rb')
-rw-r--r--app/models/clusters/applications/runner.rb31
1 files changed, 1 insertions, 30 deletions
diff --git a/app/models/clusters/applications/runner.rb b/app/models/clusters/applications/runner.rb
index 59a9251d6b7..b57a24dead0 100644
--- a/app/models/clusters/applications/runner.rb
+++ b/app/models/clusters/applications/runner.rb
@@ -3,7 +3,7 @@
module Clusters
module Applications
class Runner < ApplicationRecord
- VERSION = '0.34.0'
+ VERSION = '0.35.0'
self.table_name = 'clusters_applications_runners'
@@ -50,34 +50,6 @@ module Clusters
private
- def ensure_runner
- runner || create_and_assign_runner
- end
-
- def create_and_assign_runner
- transaction do
- Ci::Runner.create!(runner_create_params).tap do |runner|
- update!(runner_id: runner.id)
- end
- end
- end
-
- def runner_create_params
- attributes = {
- name: 'kubernetes-cluster',
- runner_type: cluster.cluster_type,
- tag_list: %w[kubernetes cluster]
- }
-
- if cluster.group_type?
- attributes[:runner_namespaces] = [::Ci::RunnerNamespace.new(namespace: group)]
- elsif cluster.project_type?
- attributes[:runner_projects] = [::Ci::RunnerProject.new(project: project)]
- end
-
- attributes
- end
-
def gitlab_url
Gitlab::Routing.url_helpers.root_url(only_path: false)
end
@@ -85,7 +57,6 @@ module Clusters
def specification
{
"gitlabUrl" => gitlab_url,
- "runnerToken" => ensure_runner.token,
"runners" => { "privileged" => privileged }
}
end