Skip to content

Commit

Permalink
Change prometheus namespace
Browse files Browse the repository at this point in the history
  • Loading branch information
Mooli Tayer committed Nov 9, 2017
1 parent d857281 commit e2dc118
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions app/controllers/ems_container_controller.rb
Expand Up @@ -14,8 +14,8 @@ class EmsContainerController < ApplicationController

OPENSHIFT_ROUTES = {
"hawkular" => %w(hawkular-metrics openshift-infra),
"prometheus" => %w(prometheus prometheus),
"prometheus_alerts" => %w(alerts prometheus)
"prometheus" => %w(prometheus openshift-metrics),
"prometheus_alerts" => %w(alerts openshift-metrics)
}.freeze

def self.model
Expand Down
4 changes: 2 additions & 2 deletions spec/controllers/ems_container_controller_spec.rb
Expand Up @@ -103,7 +103,7 @@

# set kubeclient to return a mock route.
allow(Kubeclient::Client).to receive(:new).and_return(mock_client)
expect(mock_client).to receive(:get_route).with('prometheus', 'prometheus')
expect(mock_client).to receive(:get_route).with('prometheus', 'openshift-metrics')
.and_return(RecursiveOpenStruct.new(:spec => {:host => "prometheus-metrics.example.com"}))

ret = JSON.parse(controller.send(:update_ems_button_detect))
Expand All @@ -122,7 +122,7 @@

# set kubeclient to return a mock route.
allow(Kubeclient::Client).to receive(:new).and_return(mock_client)
expect(mock_client).to receive(:get_route).with('alerts', 'prometheus')
expect(mock_client).to receive(:get_route).with('alerts', 'openshift-metrics')
.and_return(RecursiveOpenStruct.new(:spec => {:host => "prometheus-alerts.example.com"}))

ret = JSON.parse(controller.send(:update_ems_button_detect))
Expand Down

0 comments on commit e2dc118

Please sign in to comment.