Sha256: 204f277f291bc7ea0667d555fe8e3a86c4a34ebe362f532322ce68c399782e50
Contents?: true
Size: 829 Bytes
Versions: 1
Compression:
Stored size: 829 Bytes
Contents
require 'rubygems' ROOT_DIR = File.dirname(__FILE__) $LOAD_PATH.unshift("#{ROOT_DIR}/lib") $LOAD_PATH.unshift("#{ROOT_DIR}/server") require 'sinatra/base' require 'extensions/object' require 'app' require 'extensions/hash' require 'mirage/client' module Mirage class Server < Sinatra::Base configure do options = Hash[*ARGV] set :defaults, options["defaults"] set :port, options["port"] $0="Mirage Server port #{settings.port}" set :show_exceptions, false set :logging, true set :dump_errors, true set :server, 'thin' set :views, "#{ROOT_DIR}/views" set :bind, '0.0.0.0' log_file = File.open('mirage.log', 'a') log_file.sync=true use Rack::CommonLogger, log_file enable :logging end end end Mirage::Server.run! :server => 'thin'
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
mirage-on-thin-3.0.8 | mirage_server.rb |