motionbank / piecemaker2-api

An api at the core of piecemaker
7 stars 0 forks source link

API logging on Heroku fails #112

Open fjenett opened 9 years ago

fjenett commented 9 years ago

Not sure if this is just a config problem …

$ heroku run rake db:create_super_admin[prod] -a piecemaker2-api-public
Running `rake db:create_super_admin[prod]` attached to terminal... up, run.7825
rake aborted!
Errno::ENOENT: No such file or directory - /app/log/api.log
/app/config/environment.rb:8:in `new'
/app/config/environment.rb:8:in `<top (required)>'
/app/Rakefile:130:in `require'
/app/Rakefile:130:in `block in <top (required)>'
/app/Rakefile:137:in `block (2 levels) in <top (required)>'
Tasks: TOP => environment
(See full trace by running task with --trace)
dasantonym commented 9 years ago

afaik heroku does not provide a 100% writeable filesystem. you'd need to write to one of the designated locations:

https://devcenter.heroku.com/articles/read-only-filesystem https://devcenter.heroku.com/articles/dynos#ephemeral-filesystem

fjenett commented 9 years ago

Yes, we already have a check in the environment.yml but after initialising the logger … duh!