summaryrefslogtreecommitdiff
path: root/app/models/clusters/cluster.rb
diff options
context:
space:
mode:
authorClement Ho <ClemMakesApps@gmail.com>2018-01-08 12:59:19 -0600
committerClement Ho <ClemMakesApps@gmail.com>2018-01-08 12:59:19 -0600
commit606b5094c15f36ebd9d697440446c48b54d40e6c (patch)
treeddb7bf3dfa8d925c38307bca0ff8837cc9d3741f /app/models/clusters/cluster.rb
parent7f7a18c0c37a11b1eba2ac5575087b7b85c3ec5f (diff)
parent1d7b46062feb1d93dd3efaf6ba4d5d934068342c (diff)
downloadgitlab-ce-improve-table-pagination-spec.tar.gz
Merge branch 'master' into improve-table-pagination-specimprove-table-pagination-spec
Diffstat (limited to 'app/models/clusters/cluster.rb')
-rw-r--r--app/models/clusters/cluster.rb7
1 files changed, 5 insertions, 2 deletions
diff --git a/app/models/clusters/cluster.rb b/app/models/clusters/cluster.rb
index 55419189282..5ecbd4cbceb 100644
--- a/app/models/clusters/cluster.rb
+++ b/app/models/clusters/cluster.rb
@@ -6,7 +6,8 @@ module Clusters
APPLICATIONS = {
Applications::Helm.application_name => Applications::Helm,
- Applications::Ingress.application_name => Applications::Ingress
+ Applications::Ingress.application_name => Applications::Ingress,
+ Applications::Prometheus.application_name => Applications::Prometheus
}.freeze
belongs_to :user
@@ -21,6 +22,7 @@ module Clusters
has_one :application_helm, class_name: 'Clusters::Applications::Helm'
has_one :application_ingress, class_name: 'Clusters::Applications::Ingress'
+ has_one :application_prometheus, class_name: 'Clusters::Applications::Prometheus'
accepts_nested_attributes_for :provider_gcp, update_only: true
accepts_nested_attributes_for :platform_kubernetes, update_only: true
@@ -62,7 +64,8 @@ module Clusters
def applications
[
application_helm || build_application_helm,
- application_ingress || build_application_ingress
+ application_ingress || build_application_ingress,
+ application_prometheus || build_application_prometheus
]
end