<p>A very basic installation of Apache can be done very quickly and easily if you just want to get your website up and running as quickly as possible. Before we install it, we will make sure our system is up to date with the following commands.</p>
<preclass="inset">
$ sudo apt-get update
$ sudo apt-get upgrade -y
$ sudo apt-get dist-upgrade -y</pre>
<p>We can then install apache with the command</p>
<preclass="inset">
sudo apt install apache2 -y</pre>
<p>I have skipped some steps here, in that my IP address and domain are already set up and I have configured port forwarding to point to the IP address of my Rapsberry Pi so I can now go to the domain (osztromok.com) and see the apache default page which shows that apache is installed and working correctly.</p>
<p>The default location for this page is</p>
<preclass="inset">
/var/www/html</pre>
<p>All that is required now to get the website up and running is to delete the default apache page and then copy the files for my site over to this folder. The new website is now ready to go and can be viewed in any standard browser.</p>
<p>For more information on configuring Apache please see my notes on the LinkedIn course <ahref="https://www.linkedin.com/learning/apache-web-server-administration">Apache Web Server: Administration</a> which can be found <ahref="http://osztromok.com/webdevelopment/apachewebserveradmin/configuring.html">here</a>.</p>
<p>For reference, the official documentation for Apache is at <ahref="http://httpd.apache.org/docs/current/configuring.html">apache.org</a>.</p>
<p>The main configuration for Apache is in</p>
<preclass="inset">
/etc/apache2/apache2.conf</pre>
<p>We will start off by making some changes to the configuration in order to provide better security.</p>