feat(nginx): add robots.txt
This commit is contained in:
parent
b77383586d
commit
3a3bbe2ab7
|
@ -5,8 +5,9 @@ metadata:
|
||||||
annotations:
|
annotations:
|
||||||
nginx.ingress.kubernetes.io/proxy-body-size: 10m
|
nginx.ingress.kubernetes.io/proxy-body-size: 10m
|
||||||
nginx.ingress.kubernetes.io/server-snippet: |
|
nginx.ingress.kubernetes.io/server-snippet: |
|
||||||
if ($http_user_agent ~* "BLEXBot|SemrushBot|AhrefsBot" ) {
|
location = /robots.txt {
|
||||||
return 403;
|
add_header Content-Type text/plain;
|
||||||
|
return 200 "User-agent: Amazonbot\nDisallow: /\n\nUser-agent: BLEXBot\nDisallow: /\n\nUser-agent: SemrushBot\nDisallow: /\n\nUser-agent: AhrefsBot\nDisallow: /\n\nUser-agent: DotBot\nDisallow: /\n\nUser-agent: BingBot\nCrawl-delay: 30\n";
|
||||||
}
|
}
|
||||||
spec:
|
spec:
|
||||||
ingressClassName: nginx
|
ingressClassName: nginx
|
||||||
|
|
Loading…
Reference in New Issue