Advertisement
rockdrilla

sample

Jun 29th, 2016
499
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Nginx 3.49 KB | None | 0 0
  1. # nginx -T
  2. nginx: the configuration file /etc/nginx/nginx.conf syntax is ok
  3. nginx: configuration file /etc/nginx/nginx.conf test is successful
  4. # configuration file /etc/nginx/nginx.conf:
  5. user www-data;
  6.  
  7. worker_processes auto;
  8. worker_priority 10;
  9. worker_rlimit_nofile 2048;
  10.  
  11. pid /run/nginx.pid;
  12.  
  13. timer_resolution 20ms;
  14.  
  15. pcre_jit on;
  16.  
  17. include /etc/nginx/modules-enabled/*.conf;
  18.  
  19. events {
  20.     use epoll;
  21.     worker_connections 512;
  22. }
  23.  
  24. http {
  25.     open_file_cache max=2048 inactive=60;
  26.     open_file_cache_errors off;
  27. ##  open_file_cache_min_uses 1;
  28. ##  open_file_cache_valid 60s;
  29.  
  30.     output_buffers 4 32k;
  31.  
  32.     aio threads;
  33.     directio 1m;
  34.  
  35.     sendfile on;
  36.  
  37.     tcp_nopush on;
  38.     tcp_nodelay on;
  39.  
  40.     postpone_output 1000;
  41.  
  42.     keepalive_timeout 120;
  43.  
  44.     server_tokens off;
  45.     server_names_hash_bucket_size 64;
  46.     server_name_in_redirect off;
  47.  
  48.     types_hash_max_size 2048;
  49.  
  50.     include /etc/nginx/mime.types;
  51.     default_type application/octet-stream;
  52.  
  53.     log_format  main_ext
  54.         '$remote_addr - $remote_user [$time_local] "$request" '
  55.         '$status '
  56.         '$body_bytes_sent '
  57.         '"$http_referer" '
  58.         '"$http_user_agent" '
  59.         '"$http_x_forwarded_for" '
  60.         'rt=$request_time '
  61.         'ua="$upstream_addr" '
  62.         'us="$upstream_status" '
  63.         'ut="$upstream_response_time" '
  64.         'ul="$upstream_response_length" '
  65.         'cs=$upstream_cache_status'
  66.     ;
  67.  
  68. ##  access_log off;
  69.     access_log /var/log/nginx/access.log main_ext;
  70.     log_subrequest on;
  71.  
  72. ##  error_log /var/log/nginx/error.log;
  73.     error_log /var/log/nginx/error.log info;
  74.     log_not_found off;
  75.  
  76.     ### limit HTTP 'Content-Range' / 'Accept-Range'
  77.     max_ranges 2;
  78.  
  79.     include /etc/nginx/conf.d/*.conf;
  80.     include /etc/nginx/sites-enabled/*;
  81. }
  82.  
  83. # configuration file /etc/nginx/conf.d/http:gzip.conf:
  84.     gzip on;
  85.     gunzip on;
  86.  
  87.     gzip_disable "msie6";
  88.     gzip_vary on;
  89.     gzip_proxied any;
  90.     gzip_comp_level 6;
  91.     gzip_http_version 1.1;
  92.     gzip_types text/plain text/css application/json application/javascript text/xml application/xml application/xml+rss text/javascript;
  93.  
  94.     gzip_buffers    32 8k;
  95.     gunzip_buffers  32 8k;
  96.  
  97. # configuration file /etc/nginx/sites-enabled/http:minsk-energo:
  98. server {
  99.     listen 80 default_server bind deferred;
  100.     server_name _ "" " ";
  101.  
  102.     include snippets/loc.deny.dotfiles;
  103.  
  104.     location / {
  105.         include uwsgi_params;
  106.         uwsgi_pass unix:///run/uwsgi/EmcosWebServices.sock;
  107.     }
  108. }
  109.  
  110. # configuration file /etc/nginx/snippets/loc.deny.dotfiles:
  111. location ~ /\. {
  112.     include snippets/area.internal;
  113. }
  114.  
  115. # configuration file /etc/nginx/snippets/area.internal:
  116. ### to use within `location'
  117. access_log     off;
  118. error_log      off;
  119. log_not_found  off;
  120. internal;
  121.  
  122. # configuration file /etc/nginx/uwsgi_params:
  123.  
  124. uwsgi_param  QUERY_STRING       $query_string;
  125. uwsgi_param  REQUEST_METHOD     $request_method;
  126. uwsgi_param  CONTENT_TYPE       $content_type;
  127. uwsgi_param  CONTENT_LENGTH     $content_length;
  128.  
  129. uwsgi_param  REQUEST_URI        $request_uri;
  130. uwsgi_param  PATH_INFO          $document_uri;
  131. uwsgi_param  DOCUMENT_ROOT      $document_root;
  132. uwsgi_param  SERVER_PROTOCOL    $server_protocol;
  133. uwsgi_param  REQUEST_SCHEME     $scheme;
  134. uwsgi_param  HTTPS              $https if_not_empty;
  135.  
  136. uwsgi_param  REMOTE_ADDR        $remote_addr;
  137. uwsgi_param  REMOTE_PORT        $remote_port;
  138. uwsgi_param  SERVER_PORT        $server_port;
  139. uwsgi_param  SERVER_NAME        $server_name;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement