When I run bundle exec rails console production
or rails console production
via SSH on the server in the Current
folder of the Capistrano deploy I get:
Usage:
rails new APP_PATH [options]
Options:
(...)
with an explanation to start a new app. Locally it works. Why can't I start a console remotely?
I'm assuming that you updated to rails 4
from version 3 and your app can't find the executables in the bin
directory. Run this to see your rails version:
$ rails -v
If your rails
version is 4 or above, try running this:
$ rake rails:update:bin
Source: Rails 4 Release Notes
6.1 Notable changes
- Your app's executables now live in the
bin/
dir. Runrake rails:update:bin
to getbin/bundle
,bin/rails
, andbin/rake
.