mirror of
https://github.com/klaussilveira/gitlist.git
synced 2025-11-17 19:20:56 +01:00
43 lines
1.0 KiB
Plaintext
43 lines
1.0 KiB
Plaintext
server {
|
|
server_name MYSERVER;
|
|
access_log /var/log/nginx/MYSERVER.access_log main;
|
|
error_log /var/log/nginx/MYSERVER.error_log debug_http;
|
|
|
|
root /var/www/DIR;
|
|
index index.php;
|
|
|
|
# auth_basic "Restricted";
|
|
# auth_basic_user_file rhtpasswd;
|
|
|
|
location = /robots.txt {
|
|
allow all;
|
|
log_not_found off;
|
|
access_log off;
|
|
}
|
|
|
|
location ~* ^/index.php.*$ {
|
|
fastcgi_pass 127.0.0.1:9000;
|
|
include fastcgi.conf;
|
|
}
|
|
|
|
location / {
|
|
try_files $uri @gitlist;
|
|
}
|
|
|
|
location ~* \.(js|css|png|jpg|jpeg|gif|ico)$ {
|
|
add_header Vary "Accept-Encoding";
|
|
expires max;
|
|
try_files $uri @gitlist;
|
|
tcp_nodelay off;
|
|
tcp_nopush on;
|
|
}
|
|
|
|
# location ~* \.(git|svn|patch|htaccess|log|route|plist|inc|json|pl|po|sh|ini|sample|kdev4)$ {
|
|
# deny all;
|
|
# }
|
|
|
|
location @gitlist {
|
|
rewrite ^/.*$ /index.php;
|
|
}
|
|
}
|