The only difference I’ve noted is that rails server starts the server on port 3000, while rackup starts the server on port 9292.
Are there any other differences?
Are there use cases for one instead of the other?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
rails serveris the command for starting your server (usually WEBrick) and is in rails.rackupis a command that comes with the rack middle and uses the settings in your config.ru and starts a server based off of those. This is a standard (it will work for other frameworks and rack-based applications) and is usually used in production servers.One difference of note is that if you start a server with
rails sthen you will see the output in the terminal.In my experience, in production,
rackupis used by phusion passenger so you wouldn’t wantrails sin that situation.As an aside, the port can be changed with both
rails serverandrackupusing the -p flag.