Answer the question
In order to leave comments, you need to log in
How to run a Rails console on a production server?
I go via ssh to the production in the ~/app/current directory, I try to run: It bundle exec rails c RAILS_ENV=production
gives a standard help like:
Usage:
rails new APP_PATH [options]
Options:
-r, [--ruby=PATH]
Answer the question
In order to leave comments, you need to log in
Most likely you have not added bin files to the repository.
One-time try to solve the problem like this - in the current folder on the production server:
And then start the console
Or run it locally bundle exec rake rails:update:bin
, add the files and the bin folder to the repository (check your .gitingore).
Deploy and then try to launch the console.
You can also add the gem https://github.com/ydkn/capistrano-rails-console for quick access to the console.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question