32 lines
736 B
Plaintext
32 lines
736 B
Plaintext
server {
|
|
access_log /var/log/nginx/git.zzls.xyz.log combined;
|
|
|
|
server_name git.zzls.xyz;
|
|
include configs/general.conf;
|
|
|
|
location / {
|
|
proxy_pass http://unix:/run/forgejo/forgejo.socket;
|
|
proxy_set_header Host $host;
|
|
proxy_set_header X-Real-IP $remote_addr;
|
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
proxy_set_header X-Forwarded-Proto $scheme;
|
|
client_max_body_size 64M;
|
|
}
|
|
|
|
# QUIC
|
|
add_header Alt-Svc 'h3=":443"; ma=86400';
|
|
|
|
listen 443 ssl;
|
|
listen 443 quic;
|
|
http2 on;
|
|
include configs/ssl.conf;
|
|
|
|
}
|
|
server {
|
|
if ($host = git.zzls.xyz) {
|
|
return 301 https://$host$request_uri;
|
|
}
|
|
listen 80;
|
|
server_name git.zzls.xyz;
|
|
}
|