user2049259 user2049259 - 1 year ago 104
Ruby Question

How to push seeds.rb to existing rails app (on Heroku)?

I store all my app's data in seeds.rb locally. However, after I pushing everything to Heroku, the app works well, but without any data. I do not want to re-input the mass data again, so does anyone have any ways to help me?

Answer Source

If you push the app to heroku, you can seed the database with the following command.

heroku run rake db:seed
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download