Advertisement
Guest User

Untitled

a guest
Jan 24th, 2017
98
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.15 KB | None | 0 0
  1. Listen 8000
  2.  
  3. <IfModule ssl_module>
  4. Listen 443
  5. </IfModule>
  6.  
  7. <IfModule mod_gnutls.c>
  8. Listen 443
  9. </IfModule>
  10.  
  11. server {
  12. listen 80 default_server;
  13. listen [::]:80 default_server;
  14.  
  15. root /var/www/html;
  16.  
  17. # Add index.php to the list if you are using PHP
  18. index index.php index.html index.htm index.nginx-debian.html;
  19.  
  20. server_name 127.0.0.1;
  21.  
  22. location / {
  23. # First attempt to serve request as file, then
  24. # as directory, then fall back to displaying a 404.
  25. try_files $uri $uri/ =404;
  26. proxy_pass http://127.0.0.1:8000;
  27. include /etc/nginx/proxy_params;
  28. }
  29.  
  30. location ~* .(js|css|jpg|jpeg|gif|png|svg|ico|pdf|html|htm)$ {
  31. expires 30d;
  32. }
  33.  
  34. }
  35.  
  36. location @proxy {
  37. proxy_pass http://127.0.0.1:8000;
  38. include /etc/nginx/proxy_params;
  39. }
  40. location ~* .php$ {
  41. proxy_pass http://127.0.0.1:8000;
  42. include /etc/nginx/proxy_params;
  43. }
  44. }
  45.  
  46. user www-data;
  47. worker_processes auto;
  48. pid /run/nginx.pid;
  49.  
  50. events {
  51. worker_connections 768;
  52. # multi_accept on;
  53. }
  54.  
  55. http {
  56.  
  57. ##
  58. # Basic Settings
  59. ##
  60.  
  61. sendfile on;
  62. tcp_nopush on;
  63. tcp_nodelay on;
  64. keepalive_timeout 65;
  65. types_hash_max_size 2048;
  66. # server_tokens off;
  67.  
  68. # server_names_hash_bucket_size 64;
  69. # server_name_in_redirect off;
  70.  
  71. include /etc/nginx/mime.types;
  72. default_type application/octet-stream;
  73.  
  74. ##
  75. # SSL Settings
  76. ##
  77.  
  78. ssl_protocols TLSv1 TLSv1.1 TLSv1.2; # Dropping SSLv3, ref: POODLE
  79. ssl_prefer_server_ciphers on;
  80.  
  81. ##
  82. # Logging Settings
  83. ##
  84.  
  85. access_log /var/log/nginx/access.log;
  86. error_log /var/log/nginx/error.log;
  87.  
  88. ##
  89. # Gzip Settings
  90. ##
  91.  
  92. gzip on;
  93. gzip_disable "msie6";
  94.  
  95. # gzip_vary on;
  96. # gzip_proxied any;
  97. # gzip_comp_level 6;
  98. # gzip_buffers 16 8k;
  99. # gzip_http_version 1.1;
  100. # gzip_types text/plain text/css application/json application/javascript text/xml application/xml application/xml+rss text/javascript;
  101.  
  102. ##
  103. # Virtual Host Configs
  104. ##
  105.  
  106. include /etc/nginx/conf.d/*.conf;
  107. include /etc/nginx/sites-enabled/*;
  108. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement