diff options
author | Shinya Maeda <shinya@gitlab.com> | 2017-11-07 18:34:59 +0900 |
---|---|---|
committer | Shinya Maeda <shinya@gitlab.com> | 2017-11-07 18:34:59 +0900 |
commit | d89d514e89916a08b2692ada242afc732d10fdc0 (patch) | |
tree | 2e69d464f6b3d03f8177ee0c3bd0bb85a1af1e46 /app/models/clusters | |
parent | 6228b65ff1503e2a3496544c15961139e1fb6cd4 (diff) | |
parent | 3bf2abaa1cc26b8658d870e85d4fc9e60e621944 (diff) | |
download | gitlab-ce-d89d514e89916a08b2692ada242afc732d10fdc0.tar.gz |
Merge branch '38464-k8s-apps' of https://gitlab.com/gitlab-org/gitlab-ce into 38464-k8s-apps
Diffstat (limited to 'app/models/clusters')
-rw-r--r-- | app/models/clusters/concerns/application_status.rb | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/app/models/clusters/concerns/application_status.rb b/app/models/clusters/concerns/application_status.rb index 40140cb71cb..e73abfa9055 100644 --- a/app/models/clusters/concerns/application_status.rb +++ b/app/models/clusters/concerns/application_status.rb @@ -12,20 +12,20 @@ module Clusters state :installing, value: 2 state :installed, value: 3 + event :make_scheduled do + transition %i(installable errored) => :scheduled + end + event :make_installing do - transition any - [:installing] => :installing + transition %i(scheduled) => :installing end event :make_installed do - transition any - [:installed] => :installed + transition %i(installing) => :installed end event :make_errored do - transition any - [:errored] => :errored - end - - event :make_scheduled do - transition %i(installable errored) => :scheduled + transition any => :errored end before_transition any => [:scheduled] do |app_status, _| |