【发布时间】:2022-01-16 23:38:59
【问题描述】:
我想在 Windows on Rails 6 上使用 SSL 启动 Puma (v.5.2.2)。
当我执行时:
bundle exec puma
我收到以下错误:
Puma compiled without SSL support (RuntimeError)
我已经安装了 openssl:
>openssl version
OpenSSL 1.1.1j 16 Feb 2021
在文件 puma.rb 中,我插入了:
ssl_bind '0.0.0.0', 3000, {
key: 'mykey.key',
cert: 'mykey.crt',
verify_mode: 'none'
}
我生成了 mykey.key 和 mykey.crt 并将它们放在 Rails 根文件夹中。
我已经尝试过,但没有成功:
-
我在安装openssl后重新安装了Puma
-
我使用以下命令运行服务器:
rails s -b "ssl://localhost:3000?key=mykey.key&cert=mykey.crt" -
我试过 Puma 4.x.x 版
【问题讨论】:
标签: ruby-on-rails puma