ubuntuusers.de

Nginx Config

Autor:
x8
Datum:
27. Juni 2011 13:44
Code:
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
user www-data;
worker_processes  4;

error_log  /var/log/nginx/error.log;
pid        /var/run/nginx.pid;

events {
    worker_connections  1024;
}

http {
    include       /etc/nginx/mime.types;
    #default_type  application/octet-stream;
    default_type   text/html;

    access_log  /var/log/nginx/access.log;

    sendfile        on;
    #tcp_nopush     on;

    #keepalive_timeout  0;
    keepalive_timeout   3;
    tcp_nodelay        on;

    gzip  on;
    gzip_comp_level 2;
    gzip_proxied any;
    gzip_types  text/plain text/html text/css application/x-javascript text/xml application/xml application/xml+rss text/javascript;

    # Nginx default value was 1 MB and therefore all uploads exceeding 1 MB was
    # getting "413 Request Entity Too Large" error.Script default is 64 MB.
    # Remember to change the settings for upload size in php.ini as well.
    client_max_body_size 64m;

    include /etc/nginx/conf.d/*.conf;
    include /etc/nginx/sites-available/*;
}
# Hier liegt das Problem
server {
	listen		80;
	server_name	localhost;
	root		/var/www;
}