Skip to content

Instantly share code, notes, and snippets.

@MTRNord
Created October 20, 2014 12:32
Show Gist options
  • Save MTRNord/49f63f2f1254ac55c1bd to your computer and use it in GitHub Desktop.
Save MTRNord/49f63f2f1254ac55c1bd to your computer and use it in GitHub Desktop.
nginx conf ohne php
http {
include mime.types;
default_type application/octet-stream;
sendfile on;
keepalive_timeout 2;
server {
#WICHTIGES
listen ip_des_des_server:80;
server_name domain_des_vhost1;
charset utf-8;
root /pfad/zum/web/dir;
location / {
index index.html index.htm;
}
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root html;
}
error_log /pfad/zur/error.log;
access_log /pfad/zur/access.log combined;
#UNWICHTIGES
location ~ /\. {
deny all;
access_log off;
log_not_found off;
}
location = /favicon.ico {
log_not_found off;
access_log off;
}
location = /robots.txt {
allow all;
log_not_found off;
access_log off;
}
}
}
http {
include mime.types;
default_type application/octet-stream;
sendfile on;
keepalive_timeout 2;
server {
#WICHTIGES
listen ip_des_des_server:80;
server_name domain_des_vhost2;
charset utf-8;
root /pfad/zum/web/dir;
location / {
index index.html index.htm;
}
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root html;
}
error_log /pfad/zur/error.log;
access_log /pfad/zur/access.log combined;
#UNWICHTIGES
location ~ /\. {
deny all;
access_log off;
log_not_found off;
}
location = /favicon.ico {
log_not_found off;
access_log off;
}
location = /robots.txt {
allow all;
log_not_found off;
access_log off;
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment