tkalfaoglu
Silver Pleskian
I have this code for our main site to stop the pesky crawlers in our main site's hosting settings:
Apache & nginx Settings for kalfaoglu.net :
and for nginx:
I would like to make this applied to all sites we host. How do I go about making this globally for every site we host/will host?
Many thanks, -t
Apache & nginx Settings for kalfaoglu.net :
Code:
RewriteEngine On
RewriteCond %{HTTP_USER_AGENT} (SemrushBot|PetalBot|DotBot|gumgum-bot|postmanruntime|ag_dm_spider|scrapy|chimebot|trendkite-akashic-crawler|ZoominfoBot|Sogou|ALittle|Keybot|Buck|curl|webpr
osbot|RestSharp|Snap|SemrushBot|AhrefsBot|DataForSeoBot|Sogou|trendkite-akashic-crawler|cortex|ALittle|Go-http-client|RestSharp) [NC]
RewriteRule .* - [F,L]
and for nginx:
Code:
if ($http_user_agent ~ (SemrushBot|PetalBot|DotBot|gumgum-bot|postmanruntime|ag_dm_spider|scrapy|chimebot|trendkite-akashic-crawler|ZoominfoBot|Sogou|ALittle|Keybot|Buck|curl|webprosbot|RestSharp|Snap|SemrushBot|AhrefsBot|Da
taForSeoBot|Sogou|trendkite-akashic-crawler|cortex|ALittle|Go-http-client|RestSharp|MJ12bot)) {
return 403;
}
I would like to make this applied to all sites we host. How do I go about making this globally for every site we host/will host?
Many thanks, -t