I am currently learning Ruby on Rails on my Win10 machine, and the server refuses to run.
$ rails server
Could not find server ''. (Rails::Command::Base::CorrectableError)
Run `bin/rails server --help` for more options.
I tried to find an answer, but can not find one. Yes I am in the project root.
For people running Ruby 3.0, since Webrick isn't shipped by default anymore, if you still want to use it, you need to add it to your Gemfile:
gem 'webrick', '~> 1.7'
Rails does not find a server to use, it happened to me upgrading a Rails 5.x to 6.x project. The way to solve was to add on my Gemfile:
gem 'puma', '~> 5.2'
Of course you could try different servers like unicorn
or thin
as @jvillian shared on his article.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With