2014-10-25 02:50:40 +00:00
|
|
|
class ApiConfigsController < ApiController
|
|
|
|
|
|
|
|
|
|
respond_to :json
|
|
|
|
|
|
|
|
|
|
def index
|
|
|
|
|
configs =
|
|
|
|
|
{
|
2015-05-11 14:50:45 +00:00
|
|
|
websocket_gateway_uri: APP_CONFIG.websocket_gateway_uri,
|
|
|
|
|
websocket_gateway_uri_ssl: APP_CONFIG.websocket_gateway_uri_ssl
|
2014-10-25 02:50:40 +00:00
|
|
|
}
|
2020-05-09 13:22:19 +00:00
|
|
|
|
2014-10-25 02:50:40 +00:00
|
|
|
render :json => configs, :status => 200
|
|
|
|
|
end
|
|
|
|
|
|
2020-05-09 13:22:19 +00:00
|
|
|
# should be nginx cached on 5 minutes
|
|
|
|
|
def client
|
|
|
|
|
configs =
|
|
|
|
|
{
|
2020-09-19 16:52:31 +00:00
|
|
|
top_message: GenericState.top_message,
|
|
|
|
|
event_page_top_logo_url: GenericState.event_page_top_logo_url
|
2020-05-09 13:22:19 +00:00
|
|
|
}
|
2014-10-25 02:50:40 +00:00
|
|
|
|
2020-05-09 13:22:19 +00:00
|
|
|
render :json => configs, :status => 200
|
|
|
|
|
end
|
2014-10-25 02:50:40 +00:00
|
|
|
end
|