Sha256: 3d9547b5959594e0986b024b896c7c7a81abd9863b6299b22c25f22016e0f3fa
Contents?: true
Size: 405 Bytes
Versions: 10
Compression:
Stored size: 405 Bytes
Contents
require 'carte/server' require 'json' $config = JSON.parse(File.read('config.json')) class Carte::Server configure do Mongoid.load! './mongoid.yml' set :carte, $config end end map('/') do use Rack::Deflater use Rack::Static, urls: [""], root: $config['root_dir'], index: $config['html_path'] run Rack::Directory.new $config['root_dir'] end map('/api') do run Carte::Server.new end
Version data entries
10 entries across 10 versions & 1 rubygems