jcrosby / cloudkit

An Open Web JSON Appliance

This URL has Read+Write access

grempe (author)
Thu Jun 11 18:01:37 -0700 2009
jcrosby (committer)
Wed Jul 29 12:47:36 -0700 2009
cloudkit / examples / 5.ru
100644 10 lines (9 sloc) 0.421 kb
1
2
3
4
5
6
7
8
9
10
$:.unshift File.expand_path(File.dirname(__FILE__)) + '/../lib'
require 'cloudkit'
require 'rufus/tokyo' # gem install rufus-tokyo
CloudKit.setup_storage_adapter(Rufus::Tokyo::Table.new('cloudkit.tdb'))
use Rack::Session::Pool
use CloudKit::OAuthFilter
use CloudKit::OpenIDFilter
use CloudKit::Service, :collections => [:notes]
run lambda{|env| [200, {'Content-Type' => 'text/html', 'Content-Length' => '5'}, ['HELLO']]}