gpt4 book ai didi

ruby-on-rails - 当我尝试访问 https ://localhost:3000 时收到 Rails 服务器的错误消息

转载 作者:太空宇宙 更新时间:2023-11-03 17:03:36 29 4
gpt4 key购买 nike

每当我执行“rails server”并尝试访问 https://localhost:3000 时,我都会收到以下错误消息。知道发生了什么事吗?

谢谢!

=> Booting WEBrick

=> Rails 4.0.2 application starting in development on http://localhost:3000

=> Run `rails server -h` for more startup options

=> Ctrl-C to shutdown server

[2014-02-04 14:00:34] INFO WEBrick 1.3.1

[2014-02-04 14:00:34] INFO ruby 2.0.0 (2013-11-22) [x86_64-darwin12.5.0]

[2014-02-04 14:00:34] INFO WEBrick::HTTPServer#start: pid=25445 port=3000

[2014-02-04 14:00:37] ERROR bad Request-Line `\x16\x03\x01\x00?\x01\x00\x00?\x03\x03R?8?Rcd?0j?`\\?6?>??f?&-??pB???B\x00\x00J\x00??$?#?'.

[2014-02-04 14:00:37] ERROR bad URI `"^;?\x00?D\x1D??׆?wјH?\x15?.\x10M?\x00\x00J\x00??$?#?'.

[2014-02-04 14:00:37] ERROR bad Request-Line `\x16\x03\x00\x00E\x01\x00\x00A\x03\x00R?8հBo?㦈r?\x19'.

最佳答案

您正在尝试通过不受支持的 HTTPS 进行连接。 WEBrick 期待纯 HTTP,因此它不知道如何解析加密请求。

除非开发中确实需要HTTPS,否则直接使用HTTP即可。如果您需要 HTTPS,可以这样做,但需要进行一些配置更改。例如,查看 this问题是如何使用 thin 来做到这一点。

关于ruby-on-rails - 当我尝试访问 https ://localhost:3000 时收到 Rails 服务器的错误消息,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21562381/

29 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com