don't check DB when precompiling assets

this is necessary on heroku, where the environment config is not available when precompiling

* it's not tested yet
* maybe this should be a more general solution that covers more cases? maybe it should check if currently inside *any* rake task?