How do I change the root directory of an apache server?

Posted by Spencer Cooley on Stack Overflow See other posts from Stack Overflow or by Spencer Cooley
Published on 2011-05-05T01:46:55Z Indexed on 2014/06/07 15:25 UTC
Read the original article Hit count: 390

Filed under:
|

Does anyone know how to change the document root of the Apache server? I basically want localhost to come from /users/spencer/projects directory instead of /var/www.

Edit

I ended up figuring it out. Some suggested I change the httpd.conf file, but I ended up finding a file in /etc/apache2/sites-available/default and changed the root directory from /var/www to /home/myusername/projects_folder and that worked.

© Stack Overflow or respective owner

Related posts about linux

Related posts about lamp