diff options
author | Tiger <twatson@gitlab.com> | 2019-02-21 03:55:58 +0300 |
---|---|---|
committer | Tiger <twatson@gitlab.com> | 2019-07-31 04:00:11 +0300 |
commit | 0e6408ac1f176d8ef9ac08342018e5e01f578916 (patch) | |
tree | 27890cc538e4628683732c854fe4bce7cc9698f7 /app/models/clusters | |
parent | dcad4c161f9c19723e9c694f45ffa6d9aff9a622 (diff) |
Remove unused cluster configuration logic
All cluster resources are now created on demand when
a deployment job starts.
Diffstat (limited to 'app/models/clusters')
-rw-r--r-- | app/models/clusters/cluster.rb | 16 |
1 files changed, 0 insertions, 16 deletions
diff --git a/app/models/clusters/cluster.rb b/app/models/clusters/cluster.rb index 8c044c86c47..8bb44b0ce40 100644 --- a/app/models/clusters/cluster.rb +++ b/app/models/clusters/cluster.rb @@ -100,12 +100,6 @@ module Clusters scope :default_environment, -> { where(environment_scope: DEFAULT_ENVIRONMENT) } - scope :missing_kubernetes_namespace, -> (kubernetes_namespaces) do - subquery = kubernetes_namespaces.select('1').where('clusters_kubernetes_namespaces.cluster_id = clusters.id') - - where('NOT EXISTS (?)', subquery) - end - scope :with_knative_installed, -> { joins(:application_knative).merge(Clusters::Applications::Knative.available) } scope :preload_knative, -> { @@ -161,16 +155,6 @@ module Clusters return platform_kubernetes if kubernetes? end - def all_projects - if project_type? - projects - elsif group_type? - first_group.all_projects - else - Project.none - end - end - def first_project strong_memoize(:first_project) do projects.first |