If I specify port number separately the specified port number working.
rails s -p 3005 now its working with localhost:3005
But when i use - rails s - it running as localhost:3000.
why ruby-on-rails choosing default port is 3000.
It really doesn't matter which port (as long as it's above 1024 (those below are privileged ports and you must be root to use them).
If you don't like port 3000 you can change it How to change Rails 3 server default port in develoment?
The Rails server has a few default options, one of which is port 3000. If you don't explicitly set one of these settings, it will use the defaults defined there.
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