snippetbashTip
rails server — Serve the Rails app in the current directory using the Puma web server, which comes bundled with Rai
Viewed 0 times
therailscommandrails serverservecliapp
Problem
How to use the
rails server command: Serve the Rails app in the current directory using the Puma web server, which comes bundled with Rails. More information: <https://guides.rubyonrails.org/command_line.html#bin-rails-server>.Solution
rails server — Serve the Rails app in the current directory using the Puma web server, which comes bundled with Rails. More information: <https://guides.rubyonrails.org/command_line.html#bin-rails-server>.Run the web server:
rails serverRun the web server on a specified port:
rails server {{[-p|--port]}} {{port_number}}Run the web server on a specified IP address:
rails server {{[-b|--binding]}} {{ip_address}}Run the web server on a specified environment:
rails server {{[-e|--environment]}} {{environment}}Display help:
rails server {{[-h|--help]}}Code Snippets
Run the web server
rails serverRun the web server on a specified port
rails server {{[-p|--port]}} {{port_number}}Run the web server on a specified IP address
rails server {{[-b|--binding]}} {{ip_address}}Run the web server on a specified environment
rails server {{[-e|--environment]}} {{environment}}Display help
rails server {{[-h|--help]}}Context
tldr-pages: common/rails server
Revisions (0)
No revisions yet.