gblache / plate

A Heroku-deployable boilerplate Django project with Google auth, a JS framework using CoffeeScript, RequireJS, Backbone, Handlebars and Bootstrap.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

What is this?

This is a boilerplate Django project with:

  • A base user system using django-social-auth, with the Google OAuth2 login implemented.
  • A JS framework using CoffeeScript, RequireJS, Backbone, Handlebars and Bootstrap.
  • A build and deploy process.

Installing dependencies

pip install -r requirements.txt

Configuring

Look in plate/settings_env and edit the local.py and heroku.py settings as needed.

Get your Google OAuth2 credentials here: https://code.google.com/apis/console/

Be sure to set the redirect url to: http://YOUR_DOMAIN/complete/google-oauth2/

Working with CoffeeScript

This project uses CoffeeScript, the .coffee files are located in static/coffee.

To recursively watch the coffee dir for changes run this command: coffee -o plate/static/js/ -cw plate/static/coffee/

Setting up Heroku

  • heroku create
  • git push heroku master
  • heroku config:add DJANGO_ENV=heroku
  • heroku run python manage.py syncdb

Deployment

You'll need to create and commit your built static assets before you deploy.

  • ./manage.py compile_javascript
  • ./manage.py compile_css

Requirements

TODO

  • Handle rejected auth requests and login errors.
  • Better handling of view loading errors.
  • Support for different layouts.
  • Add unique constraints on email.

About

A Heroku-deployable boilerplate Django project with Google auth, a JS framework using CoffeeScript, RequireJS, Backbone, Handlebars and Bootstrap.


Languages

Language:JavaScript 98.5%Language:Python 1.2%Language:CoffeeScript 0.3%