diff options
author | Peter Leitzen <pleitzen@gitlab.com> | 2018-10-15 11:03:15 +0200 |
---|---|---|
committer | Peter Leitzen <pleitzen@gitlab.com> | 2018-10-16 09:16:43 +0200 |
commit | 3a3ec6f0213addb52abc29ee83e2d6a00e2292d3 (patch) | |
tree | 42d2840271155af848cbe22d20a50c5757f82fa2 /app/models/clusters/concerns | |
parent | 6ea674d1796488f784083eab53becb86330343cb (diff) | |
download | gitlab-ce-3a3ec6f0213addb52abc29ee83e2d6a00e2292d3.tar.gz |
Show available clusters when installed or updated
Before this commit updating Prometheus (e.g. adding alerts) made it
"updated" therefore not installed.
Diffstat (limited to 'app/models/clusters/concerns')
-rw-r--r-- | app/models/clusters/concerns/application_core.rb | 2 | ||||
-rw-r--r-- | app/models/clusters/concerns/application_status.rb | 4 |
2 files changed, 5 insertions, 1 deletions
diff --git a/app/models/clusters/concerns/application_core.rb b/app/models/clusters/concerns/application_core.rb index e3deedfb036..683b45331f6 100644 --- a/app/models/clusters/concerns/application_core.rb +++ b/app/models/clusters/concerns/application_core.rb @@ -15,7 +15,7 @@ module Clusters def set_initial_status return unless not_installable? - self.status = 'installable' if cluster&.application_helm_installed? + self.status = 'installable' if cluster&.application_helm_available? end def self.application_name diff --git a/app/models/clusters/concerns/application_status.rb b/app/models/clusters/concerns/application_status.rb index a9df59fc059..93bdf9c223d 100644 --- a/app/models/clusters/concerns/application_status.rb +++ b/app/models/clusters/concerns/application_status.rb @@ -66,6 +66,10 @@ module Clusters end end end + + def available? + installed? || updated? + end end end end |