avoinministerio/avoinministerio — pull request #388 by darkcoin (2013-04-02 12:22:02+00:00)
Title: Heroku ruby2

ruby 2 on cedar :+1:

I see very bad smell with citizen observer

never use after_create to send emails to citizens

heroiku db:setup crashing on it

I made a hack with environment variable but it is ugly

send emails always within some action never in after ActiveRecord callbacks it can produce errors in preparing environment to work like travis, dev stack and so on

run the development heroku database with command

```
heroku run export DEPLOY_ON_HEROKU=yes && rake db:setup
```

it will turn off the observer mailings

for production env simple git push to heroku... would be enought :+1:

working example

http://fathomless-journey-3663.herokuapp.com/