Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OpenSSL::SSL::SSLError when running Rails API locally #67

Closed
belgoros opened this issue Jun 18, 2019 · 2 comments
Closed

OpenSSL::SSL::SSLError when running Rails API locally #67

belgoros opened this issue Jun 18, 2019 · 2 comments

Comments

@belgoros
Copy link

I started a Rails API app with falcon serve -p 3000 and got:

1m43s    error: <Async::Task:0x3fe3dc8012e0 failed> [pid=9900]
               |   OpenSSL::SSL::SSLError: SSL_accept returned=1 errno=0 state=error: http request
               |   → /Users/Serguei/.rvm/gems/ruby-2.6.1/gems/async-io-1.23.1/lib/async/io/generic.rb:208 in `accept_nonblock'
               |     /Users/Serguei/.rvm/gems/ruby-2.6.1/gems/async-io-1.23.1/lib/async/io/generic.rb:208 in `async_send'
               |     /Users/Serguei/.rvm/gems/ruby-2.6.1/gems/async-io-1.23.1/lib/async/io/generic.rb:54 in `block in wrap_blocking_method'
               |     /Users/Serguei/.rvm/gems/ruby-2.6.1/gems/async-io-1.23.1/lib/async/io/ssl_socket.rb:139 in `block in accept'
               |     /Users/Serguei/.rvm/gems/ruby-2.6.1/gems/async-1.18.0/lib/async/task.rb:204 in `block in make_fiber'

What am i missing?

macOS 10.14.5
Ruby 2.6.1.
Rails 5.2.2

Maybe related to #59 ?

@belgoros
Copy link
Author

It will work when binding to a specific host/port as follows:

falcon serve -b http://localhost:3000

Is it a right way to go ?

@ioquatix
Copy link
Member

falcon uses https by default, you are tying in http://

Browsers won't use http/2 over http, so that's why https is the default.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants