H2O

the optimized HTTP/1.x, HTTP/2 server
Powered by Oktavia

Configure > Proxy Directives

This document describes the configuration directives of the proxy handler.

"proxy.reverse.url"

Description:

Forwards the requests to the specified URL, and proxies the response.

Example. Forwarding the requests to application server running on 127.0.0.1:8080
proxy.reverse.url: "http://127.0.0.1:8080/"

At the moment, only HTTP is supported. If you want load balancing multiple backends, replace 127.0.0.1 with hostname witch returns IP addresses via DNS or /etc/hosts.

Level:
path

"proxy.preserve-host"

Description:

A boolean flag (ON or OFF) designating whether or not to pass Host header from incoming request to upstream.

Level:
global, host, path
Default:
proxy.preserve-host: OFF

"proxy.timeout.io"

Description:

Sets the upstream I/O timeout in milliseconds.

Level:
global, host, path
Default:
proxy.timeout.io: 30000

"proxy.timeout.keepalive"

Description:

Sets the upstream timeout for idle connections in milliseconds.

Upstream connection becomes non-persistent if the value is set to zero. The value should be set to something smaller than that being set at the upstream server.

Level:
global, host, path
Default:
proxy.timeout.keepalive: 2000