Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
branch: master
Fetching contributors…

Cannot retrieve contributors at this time

executable file 19 lines (15 sloc) 0.59 kb
#!/usr/bin/env python
import sys
from brubeck.request_handling import Brubeck
from brubeck.templating import TornadoRendering, load_tornado_env
class DemoHandler(TornadoRendering):
def get(self):
name = self.get_argument('name', 'dude')
context = {
'name': name,
}
return self.render_template('success.html', **context)
app = Brubeck(mongrel2_pair=('ipc://127.0.0.1:9999', 'ipc://127.0.0.1:9998'),
handler_tuples=[(r'^/brubeck', DemoHandler)],
template_loader=load_tornado_env('./templates/tornado'))
app.run()
Jump to Line
Something went wrong with that request. Please try again.