Search code examples
ruby-on-railsruby-1.8.7ruby-enterprise-edition

Can't get server running in Rails 2.3.18


I've inherited a pretty old Rails app (running v2.3.18 on Ruby Enterprise 1.8.7) and I'm trying to get it up and running locally.

After installing the gems and performing migrations I'm trying to startup the server with rails server as I'm used to, but unfortunately it doesn't start the server but instead generates duplicates the current directory to a /server directory.

It looks like this:

➜  my_app $ rails server
      create
      create  app/controllers
      create  app/helpers
      create  app/models
      create  app/views/layouts
      create  config/environments
      create  config/initializers
      create  config/locales
      ... etc ...

In fact, anything I run after rails just duplicates the code to a new directory with that name. So rails blah would duplicate the entire project to /blah.

I've never encountered this before in newer versions of Ruby/Rails. I'd appreciate any help in fixing this!

If it makes a difference, I'm using rbenv to manage my Ruby version.


Solution

  • Try running ruby ./script/server or ./script/server start instead of rails server

    See https://stackoverflow.com/a/7526664/2113461