From 1f071d3e73d5ca4ce61c5a37468c9f92081686f8 Mon Sep 17 00:00:00 2001 From: Adam Hall Date: Thu, 21 Nov 2024 16:37:59 +1030 Subject: [PATCH] Add X-Forwarded-For header to json logs and remove server version from response headers --- packages/graphql-mesh-server/assets/nginx/nginx.conf | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/graphql-mesh-server/assets/nginx/nginx.conf b/packages/graphql-mesh-server/assets/nginx/nginx.conf index aaf09b07..aacc1feb 100644 --- a/packages/graphql-mesh-server/assets/nginx/nginx.conf +++ b/packages/graphql-mesh-server/assets/nginx/nginx.conf @@ -13,13 +13,15 @@ http { '"body_bytes_sent":"$body_bytes_sent",' '"request_time":"$request_time",' '"http_referer":"$http_referer",' - '"http_user_agent":"$http_user_agent"' + '"http_user_agent":"$http_user_agent",' + '"http_x_forwarded_for":"$http_x_forwarded_for"' '}'; gzip on; gzip_proxied any; gzip_types text/plain application/json; gzip_min_length 1000; + server_tokens off; server { listen 80;