So I worked out that Spring was my problem. If the ENV['DATABASE_URL'] or
any other setting is not set then Spring still starts and keeps running
with things unset.
I lost far too much time wondering why I could see my ENV variables in
Rails Console but database.yml wasn't getting set.
spring
I've decided to use dotenv-rails and this seems to have remedied things.
Perhaps it was an eval order issue.
I did have ENV populated with all values I expected to see, they just
weren't in the configurations.
Thanks
On Thursday, April 2, 2015 at 10:44:56 PM UTC+10, Frederick Cheung wrote:
>
>
On Thursday, April 2, 2015 at 9:15:00 AM UTC+1, Stuart Fraser wrote:
>
> I have noticed in Rails 4.2 the following in rails console
>
> #database.yml
> ...
> development:
> <<: *default
> database: project_development
> username: root
> password: <%= ENV['PASSWORD'] %>
>
> development_rep
3 matches
Mail list logo