What you want is to set up virtual hosting
on your webserver. There is a separate section in the Apache documentation that describes how to do this. Boiled down, you need to make 3 changes to what you now have (assuming that you are not yet doing virtual hosting).
1. Create a <VirtualHost> container for your current website. You might want to move the pages to a subfolder, say /var/www/html/bar
. This container should specify port 80.
2. Create a <VirtualHost> container for your new stuff. It should probably be in a different folder (mine are all of the form /var/www/html/foo
. This container should specify port 8080
3. Edit your httpd.conf file (maybe in /etc/httpd/conf/httpd.conf), so that it not only listens on the standard port (80), but also on your special port:
As an alternative to this, you can use Name-Based Virtual Hosting; in this scheme, you need to have a way of allowing users to map different DNS names to your IP address; then the Apache server matches the name in the request against the VirtualHost ServerName. If your users are on the public Internet, this means registering a second DNS name that resolves to the same IP address as your first site name. If your users are only on a private net, then you can set up a private DNS server that will supply the correct name-to-address resolution for those users.