Running rails project on another machine - ruby-on-rails-3

I am developing a website on rails. I tried to move my project on another machine and start the rails server but the server doesn't start. Instead when I enter the command rails s in terminal it creates various files. Please let me know the steps I should follow to run my project on another machine. I have rails installed there.

sounds like the other machine has rails 2 (instead of 3) installed, where running rails <something> would generate a new rails app called <something>

Related

Rails not found in specific rails project folder

I've installed rails using rvm. I've loaded rvm using ~/.bahsrc.
rails is working fine.
which rails
/home/user/.rvm/gems/ruby-2.1.0/bin/rails
but in that rails project folder which command says
/home/dinesh/.rvm/gems/ruby-2.0.0-p353#something/bin/rails
How's this happening? How to make my rails work in that folder?
If you are in the root of a rails project you may use
./script/rails --version # (or whatever rails command you want to call)
to be sure to use the rails version that corresponds to your project. Usually rails magic will apply inside a rails project and "happen" to find the correct version of rails, but there seems to be a number of things that can go wrong about that.

Why won't my new Ruby on Rails site start in development?

I'm using user-per-app configuration on an Ubuntu server running ruby 1.9.3 and rails 3.2.8.
When I create a new site using rails new test_app in the home directory of one user (my main user) and then run rails s from the app directory I get
Rails 3.2.8 application starting in development on http://0.0.0.0:3000
but when I su to another user and run the same commands in the home directory of that user, I get
Rails 3.2.8 application starting in production on http://0.0.0.0:3000
and the same thing even if I run
rails s -e development
No matter what I do as the other user, I cannot get WEBrick to start in development. What's going on here?
This must be my day to post Stack Exchange questions and then find the answer myself within moments.
Obviously there was something different about these two users and I just could not figure out what it was. The difference between users ended up being that as the failing user I was playing around with #wayne-e-seguin 's SM framework. The default installation of this sets the environment and RAILS_ENV to production. Setting those to "development" in ~/.smrc did the trick.

Running multiple Rails projects on Ubuntu

I'm brand new to Rails. I have one Rails project on my machine, but I'd like to create a 2nd project from scratch and I'm having trouble figuring out where and how to set it up. Specifically:
My current project is located in the Projects/project1 directory. I'd like to have it located in Projects/project2. Do just reinstall Rails into that directory?
I still need access to project1. How do I switch back and forth between the two projects in terms of browser access? Will it be a separate server? Do I have to edit a file to switch?
Anything else you think I might need to know in order to manage multiple projects. Please assume that I know nothing about the setup as I'm just getting started.
My current project is located in the Projects/project1 directory. I'd like to have it located in Projects/project2. Do just reinstall Rails into that directory?
Just create a new Rails project in that directory by running rails new:
$ cd Projects
$ rails new project2
You'll have a new (empty) Rails application in project2.
I still need access to project1. How do I switch back and forth between the two projects in terms of browser access? Will it be a separate server? Do I have to edit a file to switch?
Assuming you're running local servers via rails server, you can specify which port your server is running on via -p.
Given a Rails project, you can listen on localhost:3001 by executing
$ ./script/rails server -p 3001
To run multiple Rails projects locally, make sure they're all running on a unique port.
Anything else you think I might need to know in order to manage multiple projects. Please assume that I know nothing about the setup as I'm just getting started.
Depending on your platform, you should look into Pow or Passenger which automate the process of deploying multiple Rails apps to a single server.

How to create a new Rails 3 project in aptana 3? and also turn the perspective to the rails or ruby

I have aptana 3 and is updated.
How to create a new project and setup a server for this to work?
Here is the doc on creating Rails project and starting a server in Aptana Studio 3: http://wiki.appcelerator.org/display/tis/Rails+Development. There is no Rails or Ruby specific perspective any more, just the Web perspective. Also some of the Rails specific views in RadRails 2 are deprecated, as there is now a built-in Terminal view where the rails commands could be run.

ruby on rails server command

I've started to learn ruby on rails , I've got a problem with server, in the tutorial when they use "rails server" it shows port number and some other information about server, but when I use "rails server" in windows , it shows me the options of "rails" command
have any ideas where's the problem?
thanks
Before start the rails server, you have to create your project
rails new projectname
and then you have to go your project's folder and try to start server
cd projectname/
rails server