Compare commits
3 Commits
8d95a2d60a
...
main
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
e33a6bb9a3 | ||
|
|
3b253fb978 | ||
|
|
b2e9e12ebb |
21
dotfiles/nginx.conf
Normal file → Executable file
21
dotfiles/nginx.conf
Normal file → Executable file
@@ -1,19 +1,10 @@
|
|||||||
# Include before server
|
#sub_path_only rewrite ^/$ / permanent;
|
||||||
#map $term $root {
|
location /lists/idx {
|
||||||
# 1 /var/www/awesm/terminal;
|
alias $root/;
|
||||||
# default /var/www/awesm/html;
|
|
||||||
#}
|
|
||||||
#
|
|
||||||
#map $http_user_agent $autoindex_type {
|
|
||||||
# "~*curl*" jsonp;
|
|
||||||
# default html;
|
|
||||||
#}
|
|
||||||
|
|
||||||
#sub_path_only rewrite ^/$ / permanentm
|
index false;
|
||||||
location = /lists o
|
|
||||||
alias $root;
|
|
||||||
autoindex on;
|
autoindex on;
|
||||||
|
autoindex_localtime off;
|
||||||
autoindex_format jsonp;
|
autoindex_format jsonp;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -29,6 +20,7 @@ location /style {
|
|||||||
}
|
}
|
||||||
|
|
||||||
location = / {
|
location = / {
|
||||||
|
add_header x-loc "/ exact";
|
||||||
root $root;
|
root $root;
|
||||||
|
|
||||||
try_files /index /index.html;
|
try_files /index /index.html;
|
||||||
@@ -36,6 +28,7 @@ location = / {
|
|||||||
|
|
||||||
#location ~* ^/lists {
|
#location ~* ^/lists {
|
||||||
location / {
|
location / {
|
||||||
|
add_header x-loc "/ wild";
|
||||||
root $root;
|
root $root;
|
||||||
|
|
||||||
try_files $uri $uri.html /redirect?q=$uri;
|
try_files $uri $uri.html /redirect?q=$uri;
|
||||||
|
|||||||
20
dotfiles/nginx_mod.conf
Executable file
20
dotfiles/nginx_mod.conf
Executable file
@@ -0,0 +1,20 @@
|
|||||||
|
map $http_user_agent $term {
|
||||||
|
"~*curl*" 1;
|
||||||
|
"~*wget*" 1;
|
||||||
|
default 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
map $term $pretty {
|
||||||
|
0 "pretty";
|
||||||
|
default "";
|
||||||
|
}
|
||||||
|
|
||||||
|
map $term $root {
|
||||||
|
1 /var/www/awesm/terminal;
|
||||||
|
default /var/www/awesm/html;
|
||||||
|
}
|
||||||
|
|
||||||
|
map $http_user_agent $autoindex_type {
|
||||||
|
"~*curl*" jsonp;
|
||||||
|
default html;
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user