Can't launch `rails server`
See original GitHub issueHere’s my server json file:
{
"cwd": "/Users/daniel/Dev/nylon/nylonmag",
"cmd": "rails server",
"env": {
"PATH": "/Users/daniel/.rvm/gems/ruby-2.0.0-p481/bin:/Users/daniel/.rvm/gems/ruby-2.0.0-p481@global/bin:/Users/daniel/.rvm/rubies/ruby-2.0.0-p481/bin:/Users/daniel/.composer/vendor/bin:/usr/local/opt/php56/bin:/Users/daniel/.go/bin:/Applications/VMware:Fusion.app/Contents/Library:/usr/local/MacGPG2/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/sbin:/usr/sbin:/sbin:/Users/daniel/.rvm/bin",
"PORT": 3000
}
}
And here’s the error I get:
Can't connect to server on port 3000. Server crashed or timeout of 5000ms exceeded. Retry or check logs.
sh -c rails server
/Users/daniel/.rvm/rubies/ruby-2.0.0-p481/lib/ruby/site_ruby/2.0.0/rubygems/dependency.rb:298:in `to_specs': Could not find 'railties' (>= 0) among 15 total gem(s) (Gem::LoadError)
from /Users/daniel/.rvm/rubies/ruby-2.0.0-p481/lib/ruby/site_ruby/2.0.0/rubygems/dependency.rb:309:in `to_spec'
from /Users/daniel/.rvm/rubies/ruby-2.0.0-p481/lib/ruby/site_ruby/2.0.0/rubygems/core_ext/kernel_gem.rb:53:in `gem'
from /Users/daniel/.rvm/gems/ruby-2.0.0-p481/bin/rails:22:in `
'
from /Users/daniel/.rvm/gems/ruby-2.0.0-p481/bin/ruby_executable_hooks:15:in `eval'
from /Users/daniel/.rvm/gems/ruby-2.0.0-p481/bin/ruby_executable_hooks:15:in `
'
I have way more than 15 gems installed, including the one it’s looking for:
*** LOCAL GEMS ***
actionmailer (3.2.12)
actionpack (4.2.5, 3.2.12)
actionview (4.2.5)
active_admin_editor (1.1.0)
activeadmin (0.6.0)
activemodel (3.2.12)
activerecord (3.2.12)
activeresource (3.2.12)
activesupport (4.2.5, 3.2.12)
arbre (1.0.1)
arel (3.0.2)
awesome_print (1.6.1)
aws-s3 (0.6.3)
aws-sdk (1.19.0)
aws_cf_signer (0.1.3)
bcrypt-ruby (3.1.2)
better_errors (1.0.1)
bigdecimal (1.2.0)
binding_of_caller (0.7.2)
bourbon (3.1.8)
browser (0.2.1)
builder (3.2.2, 3.0.4)
bundler (1.6.2)
bundler-unload (1.0.2)
cachebar (1.1.1)
climate_control (0.0.3)
cloudinary (1.1.0)
cocaine (0.5.0)
coderay (1.1.0)
coffee-rails (3.2.2)
coffee-script (2.2.0)
coffee-script-source (1.6.3)
crass (1.0.2)
daemons (1.1.9)
debug_inspector (0.0.2)
devise (2.2.4)
domain_name (0.5.24)
ejs (1.1.1)
erubis (2.7.0)
eventmachine (1.0.3)
execjs (2.0.2)
executable-hooks (1.3.2)
faraday (0.8.8)
faraday_middleware (0.9.0)
fastercsv (1.5.5)
formtastic (2.2.1)
gem-wrappers (1.2.7, 1.2.4)
haml (4.0.3)
haml-rails (0.4)
has_scope (0.6.0.rc)
hashie (2.0.5)
hike (1.2.3)
http-cookie (1.0.2)
httparty (0.8.3)
i18n (0.7.0)
inherited_resources (1.4.1)
instagram (0.10.0)
io-console (0.4.2)
journey (1.0.4)
jquery-rails (2.0.3)
json (1.8.0, 1.7.7)
just-datetime-picker (0.0.6)
kaminari (0.14.1)
loofah (2.1.0.rc2)
mail (2.4.4)
meta_search (1.1.3)
mime-types (1.25)
mini_portile2 (2.1.0)
minitest (5.8.3, 4.3.2)
multi_json (1.8.2)
multi_xml (0.5.5)
multipart-post (1.2.0)
mysql2 (0.4.2, 0.3.13)
netrc (0.10.3)
newrelic_rpm (3.11.2.286)
nokogiri (1.6.8.rc2, 1.5.11)
orm_adapter (0.4.0)
paperclip (3.4.2)
paperclip-ffmpeg (1.0.0)
paperclip-meta (0.4.3)
polyamorous (0.5.0)
polyglot (0.3.3)
psych (2.0.0)
rack (1.6.4, 1.4.5)
rack-cache (1.2)
rack-ssl (1.3.3)
rack-test (0.6.2)
rails (3.2.12)
rails-deprecated_sanitizer (1.0.3)
rails-dom-testing (1.0.7)
rails-html-sanitizer (1.0.2)
railties (3.2.12)
rainbow (2.0.0)
rake (10.4.2, 0.9.6)
rdoc (4.0.0, 3.12.2)
redis (3.2.1)
redis-namespace (1.5.1)
responders (1.0.0)
rest-client (1.8.0)
retryable-rb (1.1.0)
rubygems-bundler (1.4.4)
rubypress (1.1.0)
rvm (1.11.3.9)
sass (3.4.21, 3.2.12)
sass-rails (3.2.6)
scss_lint (0.43.2)
sitemap_generator (5.0.2)
sprockets (2.2.2)
ssl_requirement (0.1.0)
test-unit (2.0.0.0)
thin (1.5.1)
thor (0.18.1)
thread_safe (0.3.5)
tilt (1.4.1)
tinymce-rails (4.0.26)
treetop (1.4.15)
tzinfo (1.2.2, 0.3.38)
uglifier (2.2.1)
unf (0.1.4)
unf_ext (0.0.7.1)
uuidtools (2.1.4)
warden (1.2.3)
Issue Analytics
- State:
- Created 8 years ago
- Comments:7 (3 by maintainers)
Top Results From Across the Web
ruby - Can't run rails server - Stack Overflow
I'm working on getting my first rails application, but for whatever reason, when I run the command $rails server , my terminal throws...
Read more >Rails server Rails 3.0.3 - rails server wont start - rubyonrails-talk
First step might be to see if you can find this file in some other location, and copy it here so that it...
Read more >How to Start Rails Server? - Codecademy Forums
You can check to see what directory you are in by typing “pwd” in the terminal. The second thing you want to make...
Read more >Can't launch rails server because of yarn integrity check
What is the expected result? When I run the debugger, it should start up the server. What happens instead? It fails to start...
Read more >[Fix] Rails server is already running - Prabin Poudel
This error means that the server is already running in the port you are trying to start the rails server on; normally 3000....
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
I use RVM (and foreman, though that’s less relevant) for my Ruby projects and I managed to get mine to start using the command:
I may end up adding other environment variables, but
GEM_HOME
andPATH
were enough for me for now.For anyone still stuck, the following worked for me:
hotel add 'rails server --port $PORT -b 127.0.0.1'