Forgejo: Log with real IP address
This commit is contained in:
parent
469fcbcbe8
commit
c62cb63dbc
1 changed files with 8 additions and 0 deletions
|
@ -126,6 +126,14 @@ in
|
|||
extraConfig = ''
|
||||
# Maximum upload file size for git-lfs
|
||||
client_max_body_size 100M;
|
||||
|
||||
set_real_ip_from 127.0.0.1;
|
||||
set_real_ip_from ::1;
|
||||
real_ip_header proxy_protocol;
|
||||
proxy_set_header X-Real-IP $proxy_protocol_addr;
|
||||
proxy_set_header X-Fowarded-For $proxy_protocol_addr;
|
||||
|
||||
access_log /var/log/nginx/access.${domain}.log combined_realip;
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue