2025-01-25 21:34:13 -08:00
|
|
|
# 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 server`
|
|
|
|
|
|
|
|
- Run the web server on a specified port:
|
|
|
|
|
2025-04-22 06:20:48 +03:00
|
|
|
`rails server {{[-p|--port]}} {{port_number}}`
|
2025-01-25 21:34:13 -08:00
|
|
|
|
|
|
|
- Run the web server on a specified IP address:
|
|
|
|
|
2025-04-22 06:20:48 +03:00
|
|
|
`rails server {{[-b|--binding]}} {{ip_address}}`
|
2025-01-25 21:34:13 -08:00
|
|
|
|
|
|
|
- Run the web server on a specified environment:
|
|
|
|
|
2025-04-22 06:20:48 +03:00
|
|
|
`rails server {{[-e|--environment]}} {{environment}}`
|
2025-01-25 21:34:13 -08:00
|
|
|
|
|
|
|
- Display help:
|
|
|
|
|
2025-04-22 06:20:48 +03:00
|
|
|
`rails server {{[-h|--help]}}`
|