IP address logging of a reverse proxy
Note that using a reverse proxy in front of Grafana Pyroscope can make it difficult to troubleshoot errors.
You can use the following settings to log the IP address passed along by the reverse proxy in headers such as X-Forwarded-For.
-server.log-source-ips-enabledSet this to
trueto add IP address logging when aForwarded,X-Real-IP, orX-Forwarded-Forheader is used. A field calledsourceIPsis added to error logs when data is pushed into Grafana Pyroscope.-server.log-source-ips-headerThe header field stores the source IP addresses and is used only if
-server.log-source-ips-enabledistrue, and if-server.log-source-ips-regexis set. If you do not set these flags, the defaultForwarded,X-Real-IP, orX-Forwarded-Forheaders are searched.-server.log-source-ips-regexA regular expression that is used to match the source IPs. The regular expression must contain at least one capturing group, the first of which is returned. This flag is used only if
-server.log-source-ips-enabledistrueand if-server.log-source-ips-headeris set.


