Created
January 10, 2014 17:45
-
-
Save shovon/8359005 to your computer and use it in GitHub Desktop.
Nginx server settings, where only requests to example.com will be processed, and everything else will simply result in a no response.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
server { | |
listen 80 default_server; | |
return 444; | |
} | |
server { | |
listen 80; | |
server_name example.com; | |
root /var/www/example.com; | |
index index.html; | |
location / { | |
try_files $uri $uri/ =404; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment