log the upstream response header: Server in the access log

26 visualizzazioni
Passa al primo messaggio da leggere

RJoshi

da leggere,
22 set 2016, 19:45:1522/09/16
a openresty-en
Is there any way to log the upstream response header: Server  in the access log?

Robert Paprocki

da leggere,
22 set 2016, 21:40:1122/09/16
a openre...@googlegroups.com
You should be able to use &sent_http_server in your log_format directive. See http://nginx.org/en/docs/http/ngx_http_core_module.html#var_sent_http_


On Sep 22, 2016, at 16:45, RJoshi <rohit....@gmail.com> wrote:

Is there any way to log the upstream response header: Server  in the access log?

--
You received this message because you are subscribed to the Google Groups "openresty-en" group.
To unsubscribe from this group and stop receiving emails from it, send an email to openresty-en...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Robert Paprocki

da leggere,
22 set 2016, 21:43:1822/09/16
a openre...@googlegroups.com
Actually you'll probably need to prevent Nginx from redefining the Server header as well:

proxy_pass_header Server;

Sent from my iPhone
Rispondi a tutti
Rispondi all'autore
Inoltra
0 nuovi messaggi