OpenSSL error with Rails and Webpacker
1 min readNov 9, 2017
I had this problem with Rails 5.1 while developing with Vue.js and spend quite a while trying to fix it:
21:41:04 web.1 | 2017-11-08 21:41:04 -0500: Rack app error handling request { GET /packs/hello_vue-91f189c8d8210aaf6471.js }
21:41:04 web.1 | #<OpenSSL::SSL::SSLError: SSL_connect SYSCALL returned=5 errno=0 state=unknown state>
...
First, I thought it is a problem of webpacker and tried various environment variables following this git issue: pack_tags don’t pick up custom host when running webpack-dev-server. But even updating webpacker to 3.0.2 doesn't help.
Later, I try to google ssl error with Rails and found this PR: Add back Https. So this problem can be solved by simply turning https setting to true in config/webpacker.yml for development environment !!
Hope this help someone else.