Skip to content

Commit

Permalink
Use exact match modifier = for /robots.txt
Browse files Browse the repository at this point in the history
The equal sign in the location block forces an exact match
with the path requested and then stops searching for any
more matches.
  • Loading branch information
AbdulrhmnGhanem committed Aug 1, 2023
1 parent 5dc7a86 commit 06bfcbd
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions nginx/kitspace.template
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ server {

server_name @KITSPACE_DOMAIN;

location /robots.txt {
location = /robots.txt {
add_header Content-Type text/plain;
return 200 "@KITSPACE_ROBOTS_TXT";
}
Expand Down Expand Up @@ -35,7 +35,7 @@ server {

server_name gitea.@KITSPACE_DOMAIN;

location /robots.txt {
location = /robots.txt {
add_header Content-Type text/plain;
return 200 "@KITSPACE_ROBOTS_TXT";
}
Expand Down Expand Up @@ -73,7 +73,7 @@ server {

server_name meilisearch.@KITSPACE_DOMAIN;

location /robots.txt {
location = /robots.txt {
add_header Content-Type text/plain;
return 200 "@KITSPACE_ROBOTS_TXT";
}
Expand Down

0 comments on commit 06bfcbd

Please sign in to comment.