Report this

What is the reason for this report?

How to set Rails environment?

Posted on May 26, 2014

I have a 1-click installation of Ruby on Rails 4, NginX, and Ubuntu running on my droplet.

Unfortunately, I haven’t found a way to create my production database from my schema.rb file yet.

I think this is due to the fact that my Rails environment is still set to “development”. When I type “rake about” I get this:

Application root /home/rails Environment development Database adapter sqlite3

I would like to set my app to production mode, though. I would also like to use MySQL instead of SQLite.

How can this be done?

Typing “RAILS_ENV=production” seems to have no effect whatsoever.

Thanks for any help.

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Start building today

From GPU-powered inference and Kubernetes to managed databases and storage, get everything you need to build, scale, and deploy intelligent applications.