It has been a while since I have had to do this so I am a bit rusty. Please excuse any errors.
Here are some Apache documentation links:
Here are some other reousrces that seem to be good:
It seems like the default installation of Apache needs less configuration since earlier versions. It may be safe to assume that it will answer to requests on the server IP address and port 80.
There are several configuration files to be considered. You can find them in
/etc/local/apache2, and the directories
sites-enabled under the
sites-available/default file is the default configuration for your server. If you create no other sites, then this is the only site that will be served. If you only have one site, it is okay to modify this file. Common modifications would be to change the
<directory /var/www/> directive to change the directory and to change the
AllowOverride from None to All to allow the use of .htaccess files. It would be fine to expect to deploy a website within the
/var/www/ directory and it should work.
Otherwise, if you want to host more than one site, then in the
/etc/apache2/sites-available directory, create a site configuration file often named using the following scheme
domain-name.tld.conf. Here is an example configuration:
SuexecUserGroup "#<user id>" "#<group id>"
CustomLog /home/mydomain.com/log/mydomain.com_access_log combined
AddHandler cgi-script .php
DirectoryIndex index.php index.html
Options -Indexes +IncludesNOEXEC +FollowSymLinks
allow from all
<user id> and
<group id> need to be replaced with the user id and group id of the user that owns the site. The
log, directories have to be created in the
/home directory and
chmod may need to be used to change the ownership and permissions of these directories.
When you are done, create a symbolic link with the same name of the config file you created in the
sites-enabled directory pointing to the configuration file you just created.
That should do it. If I missed a step or something needs to be explained better let me know. I will add more or change anything I need to help.