Getting rails console on an amazon aws server when using rvm

Email this to someoneShare on Google+Share on FacebookTweet about this on TwitterShare on LinkedIn


You would like to get access to your rails application console on an Amazon ec2 instance, and you are also using rvm.


  • Login with ssh to your server as normal:
  • Go to your application’s current folder:
  • Run the following replacing the environment with your specific environment (ie production,beta,staging etc):
  • Gab Riel

    Im getting the following output:
    rails new APP_PATH [options]

    -r, [–ruby=PATH] # Path to the Ruby binary of your choice
    # Default: /home/deploy/.rvm/rubies/ruby-2.3.3/bin/ruby
    -m, [–template=TEMPLATE] # Path to some application template (can be a filesystem path or URL)

    and a bunch more options.
    How do I get access to rails c where I can query the db, run ruby code etc.

  • kosmasc


    you are using rails new, that creates a new application.

    You should be using rails c to access the rails console.