Dec
6
2011
6
2011
Block Google from Dev Server
I was having a problem where Google was indexing sites on my development server, I wanted to just lock down the entire server from Google and other bots without having to change the robots.txt file of each site, as when I push them to live I would have had to change it back and undoubtly one day would have forgotten.
To do this I placed the following in my httpd.conf file:
<Directory />
RewriteEngine on
RewriteCond %{HTTP_USER_AGENT} google|googlebot|bing|slurp [NC]
RewriteRule .? - [G]
</Directory>
Tags: httpd.conf
Related Posts
Tech Cloud
0x800A1391
2003 Server
adwords
adwords editor
Amazon
Apache
APC
Axigen
Backup
CentOS
Date
EC2
error 211
Error 1907
Fedora
google
Google Sitemap Generator
htaccess
HTML5
httpd.conf
iphone
Jira
mail
mailx
mkfs
MSSQL
MySql
MySql Server
Nutch
Office 2007
PHP
Rackspace Cloud
S3
Solr
strtotime
Subversion
Time
Tomcat
URL Rewrite
virus
vsftpd
Website Optimiser
Wordpress
XML
Zend

An article by medialam




