Subdomain help
I have a client who has us serving a development box in house. I've set it up and allowed the outside world to access it through the router. Now, my question is. We've set up subdomain.ourdomain.com to point to our servers IP address and it works fine. But how do i set it up so that it automatically gets directed to a specific directory? I'm guessing it has something to do with DNS? How do I get redhat 8 to take any requests coming from subdomain.ourdomain.com and send it to /var/html/thisdirectory instead of /var/html ?
|
Im going to assume that youre using apache and are talking about serving web pages. If so, then you want Virtual Hosts.
Apache's docs on this are here. http://httpd.apache.org/docs-2.0/vhosts/ |
So basically just add in:
<VirtualHost *> DocumentRoot /var/html/thisdirectory ServerName subdomain.ourdomain.com </VirtualHost> ???? |
Yes. Here is an example one of mine:
Code:
<VirtualHost *> green_dragon37 |
All times are GMT -5. The time now is 05:35 PM. |