Pastebin launched a little side project called VERYVIRAL.com, check it out ;-) Want more features on Pastebin? Sign Up, it's FREE!

http-vhosts.conf

By: robertsky on Jul 22nd, 2012  |  syntax: None  |  size: 2.15 KB  |  views: 39  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. # Virtual Hosts
  2. #
  3. # Required modules: mod_log_config
  4.  
  5. # If you want to maintain multiple domains/hostnames on your
  6. # machine you can setup VirtualHost containers for them. Most configurations
  7. # use only name-based virtual hosts so the server doesn't need to worry about
  8. # IP addresses. This is indicated by the asterisks in the directives below.
  9. #
  10. # Please see the documentation at
  11. # <URL:http://httpd.apache.org/docs/2.4/vhosts/>
  12. # for further details before you try to setup virtual hosts.
  13. #
  14. # You may use the command line option '-S' to verify your virtual host
  15. # configuration.
  16.  
  17. #
  18. # VirtualHost example:
  19. # Almost any Apache directive may go into a VirtualHost container.
  20. # The first VirtualHost section is used for all requests that do not
  21. # match a ServerName or ServerAlias in any <VirtualHost> block.
  22. #
  23. #<VirtualHost *:80>
  24. #    ServerAdmin webmaster@dummy-host.example.com
  25. #    DocumentRoot "c:/Apache24/docs/dummy-host.example.com"
  26. #    ServerName dummy-host.example.com
  27. #    ServerAlias www.dummy-host.example.com
  28. #    ErrorLog "logs/dummy-host.example.com-error.log"
  29. #    CustomLog "logs/dummy-host.example.com-access.log" common
  30. #</VirtualHost>
  31.  
  32. #<VirtualHost *:80>
  33. #    ServerAdmin webmaster@dummy-host2.example.com
  34. #    DocumentRoot "c:/Apache24/docs/dummy-host2.example.com"
  35. #    ServerName dummy-host2.example.com
  36. #    ErrorLog "logs/dummy-host2.example.com-error.log"
  37. #    CustomLog "logs/dummy-host2.example.com-access.log" common
  38. #</VirtualHost>
  39.  
  40. NameVirtualHost *:80
  41.  
  42. <VirtualHost *:80>
  43.         ServerName tiger.dev
  44.         ServerAlias www.tiger.dev
  45.         DocumentRoot "C:\wamp\www"
  46.         ErrorLog "logs\errors.log"
  47.         <directory "C:\wamp\www">
  48.                 Options Indexes FollowSymLinks
  49.                 AllowOverride all
  50.                 Order Deny,Allow
  51.                 Deny from all
  52.         Allow from all
  53.         </directory>
  54. </VirtualHost>
  55.  
  56. <VirtualHost *:80>
  57.     ServerName tiger.dev
  58.     ServerAlias *.tiger.dev
  59.     VirtualDocumentRoot "C:\wamp\subdomains\%1"
  60.     ErrorLog "logs\errors.log"
  61.     <directory "C:\wamp\subdomains\%1">
  62.         Options Indexes FollowSymLinks
  63.         AllowOverride all
  64.         Order Deny,Allow
  65.                 Deny from all
  66.         Allow from all
  67.     </directory>
  68. </VirtualHost>