Skip to content
Snippets Groups Projects
Commit a1d10bee authored by Pawel Chojnacki's avatar Pawel Chojnacki
Browse files

use find_or_initialize to fetch prometheus_service instance

parent ddc4ed63
No related branches found
No related tags found
No related merge requests found
Loading
Loading
@@ -13,7 +13,7 @@ module Clusters
state_machine :status do
after_transition any => [:installed] do |application|
application.cluster.projects.each do |project|
project.prometheus_service&.update(active: true)
project.find_or_initialize_service('prometheus').update(active: true)
end
end
end
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment