ncr / rack-proxy

A request/response rewriting HTTP proxy. A Rack app.
MIT License
269 stars 94 forks source link

Requests Hanging #70

Closed richsoni closed 7 years ago

richsoni commented 7 years ago

I am using the example code:

# test.ru
require 'rack-proxy'
class Foo < Rack::Proxy

  def rewrite_env(env)
    env["HTTP_HOST"] = "example.com"

    env
  end

  def rewrite_response(triplet)
    status, headers, body = triplet

    headers["X-Foo"] = "Bar"

    triplet
  end

end

run Rack::Proxy.new(ssl_verify_none: true)

and, running rackup test.ru

I did some digging and it looks like the http.start is hanging.

I have not been able to find anything anywhere else about this. Has anyone run into this issue?

richsoni commented 7 years ago

If you dont provide a rack.backend. It will make the request on :9292