taler-deployment

Deployment scripts and configuration files
Log | Files | Refs | README

nginx.conf (1862B)


      1 user nginx;
      2 worker_processes 4;
      3 pid /var/run/nginx.pid;
      4 
      5 events {
      6 	worker_connections 768;
      7 	# multi_accept on;
      8 }
      9 
     10 http {
     11 
     12 	##
     13 	# Basic Settings
     14 	##
     15 
     16 	sendfile on;
     17 	tcp_nopush on;
     18 	tcp_nodelay on;
     19 	keepalive_timeout 65;
     20 	types_hash_max_size 2048;
     21 	server_tokens off;
     22 
     23 	# server_names_hash_bucket_size 64;
     24 	# server_name_in_redirect off;
     25 
     26 	include /etc/nginx/mime.types;
     27 	default_type application/octet-stream;
     28 
     29 	##
     30 	# Logging Settings
     31 	##
     32 
     33         log_format main '$remote_addr - $remote_user [$time_local] $host '
     34             '"$request" $status $body_bytes_sent '
     35             '"$http_referer" "$http_user_agent"';
     36 
     37     client_body_temp_path /var/run/nginx/body_temp;
     38     proxy_temp_path /var/run/nginx/proxy_temp;
     39     fastcgi_temp_path /var/run/nginx/fastcgi_temp;
     40     uwsgi_temp_path /var/run/nginx/uwsgi_temp;
     41     scgi_temp_path /var/run/nginx/scgi_temp;
     42     access_log /var/log/nginx/access.log main;
     43     error_log /var/log/nginx/error.log notice;
     44 
     45 	##
     46 	# Gzip Settings
     47 	##
     48 
     49 	gzip on;
     50 	gzip_disable "msie6";
     51 
     52 	# gzip_vary on;
     53 	# gzip_proxied any;
     54 	# gzip_comp_level 6;
     55 	# gzip_buffers 16 8k;
     56 	# gzip_http_version 1.1;
     57 	# gzip_types text/plain text/css application/json application/x-javascript text/xml application/xml application/xml+rss text/javascript;
     58 
     59         # This isn't entirely correct since it does
     60         # not consider the weighting of languages, but
     61         # for now it's good enough.
     62         map $http_accept_language $index_redirect_uri {
     63           default "en";
     64           # prefer language that's first in the list
     65           ~^en "en";
     66           ~^de "de";
     67           ~^fr "fr";
     68           ~^es "it";
     69           # if none matches, take one later in the list
     70           ~,en "en";
     71           ~,de "de";
     72           ~,fr "fr";
     73           ~,es "it";
     74         }
     75 
     76 	##
     77 	# Virtual Host Configs
     78 	##
     79 
     80 	include conf.d/*.conf;
     81 	include sites-enabled/*.site;
     82 }