send nginx log to journal
Some checks failed
Test Nix flake / Test nix flake (push) Has been cancelled
Some checks failed
Test Nix flake / Test nix flake (push) Has been cancelled
This commit is contained in:
parent
14fe8e912e
commit
6022b14de8
1 changed files with 46 additions and 26 deletions
|
|
@ -85,6 +85,9 @@ in
|
|||
enableACME = true;
|
||||
extraConfig = ''
|
||||
merge_slashes off; # Required to handle URL-encoded slashes
|
||||
proxy_set_header Forwarded "$proxy_forwarded_for_element;$proxy_forwarded_by_element;host=$host;proto=$scheme";
|
||||
error_log syslog:server=unix:/dev/log,tag=${builtins.replaceStrings [ "." ] [ "_" ] fqdn} warn;
|
||||
access_log syslog:server=unix:/dev/log vhost_combined;
|
||||
'';
|
||||
locations = {
|
||||
"/" = {
|
||||
|
|
@ -93,7 +96,6 @@ in
|
|||
proxyPass = "http://unix:${config.services.forgejo.settings.server.HTTP_ADDR}";
|
||||
extraConfig = ''
|
||||
client_max_body_size 512M;
|
||||
proxy_set_header Forwarded "$proxy_forwarded_for_element;$proxy_forwarded_by_element;host=$host;proto=$scheme";
|
||||
'';
|
||||
};
|
||||
"/metrics" = {
|
||||
|
|
@ -109,7 +111,6 @@ in
|
|||
recommendedProxySettings = true;
|
||||
proxyPass = "http://unix:${config.services.forgejo.settings.server.HTTP_ADDR}";
|
||||
extraConfig = ''
|
||||
proxy_set_header Forwarded "$proxy_forwarded_for_element;$proxy_forwarded_by_element;host=$host;proto=$scheme";
|
||||
limit_req zone=forgejo_archive burst=10 nodelay;
|
||||
limit_conn forgejo_archive_conn 2;
|
||||
limit_req_status 429;
|
||||
|
|
|
|||
Loading…
Reference in a new issue