简体   繁体   中英

Problems with Rails Server: WEBrick appears to boot, but localhost:3000 and variations do not load

I navigate to my app and do the following:

rails server -b localhost
=> Booting WEBrick
=> Rails 3.1.1 application starting in development on http://localhost:3000

However, when I navigate to http://localhost:3000 in any browser, I get a cannot display error. Same issue when using 127.0.0.1:3000 or 0.0.0.1:3000

If I go simply to http://localhost then I see a directory listing of my app.

Any ideas and suggestions would be welcome.

I dont think you can bind to a hostname, only an ip. try -b 127.0.0.1 and the navigate to localhost:3000 which should point to 127.0.0.1

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM