Module: Rox::Core::Environment
- Defined in:
- lib/rox/core/consts/environment.rb
Class Method Summary collapse
- .analytics_path ⇒ Object
- .api_path ⇒ Object
- .cdn_path ⇒ Object
- .notifications_path ⇒ Object
- .reset(rox_options = nil) ⇒ Object
- .roxy_internal_path ⇒ Object
- .set_platform(rox_options) ⇒ Object
- .state_api_path ⇒ Object
- .state_cdn_path ⇒ Object
Class Method Details
.analytics_path ⇒ Object
47 48 49 |
# File 'lib/rox/core/consts/environment.rb', line 47 def self.analytics_path @analytics_path end |
.api_path ⇒ Object
35 36 37 |
# File 'lib/rox/core/consts/environment.rb', line 35 def self.api_path @api_path end |
.cdn_path ⇒ Object
31 32 33 |
# File 'lib/rox/core/consts/environment.rb', line 31 def self.cdn_path @cdn_path end |
.notifications_path ⇒ Object
51 52 53 |
# File 'lib/rox/core/consts/environment.rb', line 51 def self.notifications_path @notifications_path end |
.reset(rox_options = nil) ⇒ Object
6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 |
# File 'lib/rox/core/consts/environment.rb', line 6 def self.reset( = nil) @roxy_internal_path = 'device/request_configuration' if !&..nil? @cdn_path = &.&.get_config_cloud_endpoint @api_path = &.&.get_config_api_endpoint @state_cdn_path = &.&.send_state_cloud_endpoint @state_api_path = &.&.send_state_api_endpoint @analytics_path = &.&.analytics_endpoint @notifications_path = &.&.push_notification_endpoint else case ENV['ROLLOUT_MODE'] when 'QA' setQA when 'LOCAL' setLOCAL else setDefault() end end end |
.roxy_internal_path ⇒ Object
27 28 29 |
# File 'lib/rox/core/consts/environment.rb', line 27 def self.roxy_internal_path @roxy_internal_path end |
.set_platform(rox_options) ⇒ Object
55 56 57 58 59 60 61 62 63 |
# File 'lib/rox/core/consts/environment.rb', line 55 def self.set_platform() @cdn_path = 'https://rox-conf.cloudbees.io' @state_cdn_path = 'https://rox-state.cloudbees.io' alternative_api_url = &.&.server_url || 'https://api.cloudbees.io' @api_path = "#{alternative_api_url}/device/get_configuration" @state_api_path = "#{alternative_api_url}/device/update_state_store" @analytics_path = &.&.analytics_url || 'https://fm-analytics.cloudbees.io' @notifications_path = 'https://sdk-notification-service.cloudbees.io/sse' end |
.state_api_path ⇒ Object
43 44 45 |
# File 'lib/rox/core/consts/environment.rb', line 43 def self.state_api_path @state_api_path end |
.state_cdn_path ⇒ Object
39 40 41 |
# File 'lib/rox/core/consts/environment.rb', line 39 def self.state_cdn_path @state_cdn_path end |