gpt4 book ai didi

ruby-on-rails - RubyOnRails 启动服务器运行时报错

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

我正在尝试在 ubuntu 9.10 下运行 RoR 服务器:

>      ruby script/server 
> => Booting WEBrick
> => Rails 2.3.4 application starting on http://0.0.0.0:3000
> /var/lib/gems/1.8/gems/rails-2.3.4/lib/initializer.rb:271:in
> `require_frameworks': no such file to
> load -- net/https (RuntimeError)
> from /var/lib/gems/1.8/gems/rails-2.3.4/lib/initializer.rb:134:in
> `process'
> from /var/lib/gems/1.8/gems/rails-2.3.4/lib/initializer.rb:113:in
> `send'
> from /var/lib/gems/1.8/gems/rails-2.3.4/lib/initializer.rb:113:in
> `run'
> from /home/ockonal/Programming/RoR/demo/demo/config/environment.rb:9
> from /usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in
> `gem_original_require'
> from /usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in
> `require'
> from /var/lib/gems/1.8/gems/activesupport-2.3.4/lib/active_support/dependencies.rb:156:in
> `require'
> from /var/lib/gems/1.8/gems/activesupport-2.3.4/lib/active_support/dependencies.rb:521:in
> `new_constants_in'
> from /var/lib/gems/1.8/gems/activesupport-2.3.4/lib/active_support/dependencies.rb:156:in
> `require'
> from /var/lib/gems/1.8/gems/rails-2.3.4/lib/commands/server.rb:84
> from /usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in
> `gem_original_require'
> from /usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in
> `require'
> from script/server:3

我做错了什么?

最佳答案

您没有安装 Ruby SSL 支持,导致 Rails 在查找 net/https.rb 时失败。如果您使用默认的 Ubuntu Ruby 包,则需要安装 libopenssl-ruby1.8 包。

关于ruby-on-rails - RubyOnRails 启动服务器运行时报错,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/1734221/

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