Sha256: b21ceb9ff42e3f90ad2fd488b48f7c0ce1d130e862a65b91a064f398a4dd5d38

Contents?: true

Size: 518 Bytes

Versions: 16

Compression:

Stored size: 518 Bytes

Contents

#!/usr/bin/env rackup

::Dir.chdir(::File.dirname(__FILE__)+'/..')
$:.unshift './lib'
require 'rubygems'
require 'test/db'
require 'backend_api'
require 'example/basic_admin'

use ::Rack::ContentLength
map '/' do
  run proc{ |env|
    [200,{'Content-Type'=>'text/html'}, ["Here is the Front-end. Real action is in: <a href='/admin'>/admin</a>."]]
  }
end

map '/admin' do
  use ::Rack::Config do |env|
    env['basic_admin.models'] = [:Author, :Haiku]
  end
  use BackendAPI
  run ::Rack::Builder.app(&BASIC_ADMIN)
end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
rack-backend-api-0.3.5 example/config.ru
rack-backend-api-0.3.4 example/config.ru
rack-backend-api-0.3.3 example/config.ru
rack-backend-api-0.3.2 example/config.ru
rack-backend-api-0.3.1 example/config.ru
rack-backend-api-0.3.0 example/config.ru
rack-backend-api-0.2.3 example/config.ru
rack-backend-api-0.2.2 example/config.ru
rack-backend-api-0.2.1 example/config.ru
rack-backend-api-0.2.0 example/config.ru
rack-backend-api-0.1.0 example/config.ru
rack-backend-api-0.0.5 example/config.ru
rack-backend-api-0.0.4 example/config.ru
rack-backend-api-0.0.3 example/config.ru
rack-backend-api-0.0.2 example/config.ru
rack-backend-api-0.0.1 example/config.ru