Thanks a lot for your input!
Please review this commit and correct if necessary: https://github.com/torproject/webwml/pull/67
On Tue, 23 Oct 2018 18:43:26 -0400 Adam Quenneville adam.quenneville@freemirror.org wrote:
Hi all,
You can surely use mods if need be, but for Apache2, I've found it's easiest just to use the CustomLog directive:
CustomLog /path/to/desired/log/location "0.0.0.0 %l %u %t "%r" %>s %b"
This just makes every user show up as 0.0.0.0. Which makes it plug and play with something like AWstats, or any other log-analysis software.
Simple and fast. Works for us.
Adam
On 2018-10-23 6:13 PM, Alexander Dietrich wrote:
nginx logging is documented here: https://nginx.org/en/docs/http/ngx_http_log_module.html
The default log format is given as:
log_format combined '$remote_addr - $remote_user [$time_local] ' '"$request" $status $body_bytes_sent ' '"$http_referer" "$http_user_agent"';
So if you wanted to suppress IP and user information, while staying compatible with the Common Log Format, and drop the HTTP Referer and User-Agent fields, you could add these lines to your nginx.conf:
log_format privacy '- - - [$time_local] "$request" $status $body_bytes_sent'; access_log /var/log/nginx/access.log privacy;
You may need to change the second line if your nginx log files are not in /var/log/nginx.
Kind regards, Alexander