Class: AuthProxy::Proxy
- Inherits:
-
Object
- Object
- AuthProxy::Proxy
- Defined in:
- lib/auth_proxy/proxy.rb
Instance Method Summary collapse
- #call(env) ⇒ Object
-
#initialize(options = {}) ⇒ Proxy
constructor
A new instance of Proxy.
Constructor Details
#initialize(options = {}) ⇒ Proxy
Returns a new instance of Proxy.
3 4 5 6 7 8 9 10 11 |
# File 'lib/auth_proxy/proxy.rb', line 3 def initialize(={}) @app = Rack::ReverseProxy.new do preserve_host: true .each do |path, host| reverse_proxy path, host, replace_response_host: true end end end |
Instance Method Details
#call(env) ⇒ Object
13 14 15 |
# File 'lib/auth_proxy/proxy.rb', line 13 def call(env) @app.call(env) end |