Changing RedHat Default HTTP Doc location

modem

Verified User
Joined
Apr 7, 2004
Messages
396
Is it a smart idea to go into /etc/httpd.conf and change the location of the default apache document root from /var/www/html to /home/admin/domains/mydomain.com/public_html?

When I goto http://69.64.171.88 it loads the default apache html files showing "It worked!". I would rather like for it to point towards my main company webpage. I'm assuming all I need to do is change the DocumentRoot location inside httpd.conf? Or do I need to change other things like /var/www/cgi-bin to /home/admin/domains/mydomain.com/cgi-bin?
 
Yes, changing the DocumentRoot directive will do what you described if I understand you correctly.
Personally, just for consitency I would move all default directives to the same location such as the cgi-bin but it is not required.
 
Last edited:
Thanks! I was wondering if changing the directives would harm apache or DA in anyway. I changed just the DocumentRoot right now and so far it's working. :)
 
Im always working like this, works more secure for my additional configuration. Sure a good step :)
 
Back
Top