Sha256: e9f8a376885efe5aa09eaca4174dfd544c5e344518a6a3ff3c22bed47700fd6e
Contents?: true
Size: 932 Bytes
Versions: 5
Compression:
Stored size: 932 Bytes
Contents
$:.unshift File.dirname(__FILE__) require 'rubygems' require 'sinatra/base' require 'erb' require 'json' require 'rhoconnect_api' module RhoconnectConsole class << self ROOT_DIR = File.dirname(File.expand_path(__FILE__)) unless defined? ROOT_DIR def root_path(*args) File.join(ROOT_DIR, *args) end end class Server < Sinatra::Base set :views, RhoconnectConsole::root_path("app","views") set :public, RhoconnectConsole::root_path("app","public") set :static, true use Rack::Session::Cookie HEROKU_NAV = ENV['INSTANCE_ID'] ? RestClient.get('http://nav.heroku.com/v1/providers/header') : nil before do headers['Expires'] = 'Sun, 19 Nov 1978 05:00:00 GMT' headers['Cache-Control'] = 'no-store, no-cache, must-revalidate' headers['Pragma'] = 'no-cache' end end end Dir[File.join(File.dirname(__FILE__),"app/**/*.rb")].each do |file| require file end
Version data entries
5 entries across 5 versions & 1 rubygems