The title pretty much sums it up. Do I need to have a default vhost in Apache or Nginx?

link|improve this question

47% accept rate
feedback

2 Answers

up vote 3 down vote accepted

I typically set my default virtual host as a "go away" with a 403 forbidden response/message:

<VirtualHost *>
 ServerName nohost
 ErrorDocument 403 "The website you requested was not found on this server"
 RewriteEngine on
 RewriteRule . - [F]
</VirtualHost>
link|improve this answer
feedback

No, you don't both support single server installation. It's just helpful if you're running multiple sites from the same server.

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.