Guest User

Untitled

a guest
Jun 9th, 2023
499
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Nginx 1.87 KB | None | 0 0
  1. user www-data;
  2. worker_processes auto;
  3. pid /run/nginx.pid;
  4. include /etc/nginx/modules-enabled/*.conf;
  5.  
  6. events {
  7.         worker_connections 768;
  8.         # multi_accept on;
  9. }
  10.  
  11. http {
  12.  
  13.         ##
  14.         # Basic Settings
  15.         ##
  16.  
  17.         sendfile on;
  18.         tcp_nopush on;
  19.         types_hash_max_size 2048;
  20.         # server_tokens off;
  21.  
  22.         # server_names_hash_bucket_size 64;
  23.         # server_name_in_redirect off;
  24.  
  25.         include /etc/nginx/mime.types;
  26.         default_type application/octet-stream;
  27.  
  28.         ##
  29.         # SSL Settings
  30.         ##
  31.  
  32.         ssl_protocols TLSv1 TLSv1.1 TLSv1.2 TLSv1.3; # Dropping SSLv3, ref: POODLE
  33.         ssl_prefer_server_ciphers on;
  34.  
  35.         ##
  36.         # Logging Settings
  37.         ##
  38.  
  39.         access_log /var/log/nginx/access.log;
  40.         error_log /var/log/nginx/error.log;
  41.         fastcgi_buffers 8 16k;
  42.         fastcgi_buffer_size 32k;
  43.  
  44.         ##
  45.         # Gzip Settings
  46.         ##
  47.  
  48.         gzip on;
  49.  
  50.         # gzip_vary on;
  51.         # gzip_proxied any;
  52.         # gzip_comp_level 6;
  53.         # gzip_buffers 16 8k;
  54.         # gzip_http_version 1.1;
  55.         # gzip_types text/plain text/css application/json application/javascript text/xml application/xml application/xml+rss text/javascript;
  56.  
  57.         ##
  58.         # Virtual Host Configs
  59.         ##
  60.  
  61.         include /etc/nginx/conf.d/*.conf;
  62.         include /etc/nginx/sites-enabled/*;
  63.     server {
  64.       listen       80 default_server;
  65.           listen       [::]:80 default_server;
  66.       server_name  [FQDN];
  67.       root         /usr/share/nginx/html;
  68.  
  69.       auth_basic "Restricted Access";
  70.       auth_basic_user_file /etc/nginx/.htpasswd;
  71.  
  72.       include /etc/nginx/default.d/*.conf;
  73.  
  74.       location / {
  75.           proxy_pass http://127.0.0.1:8888/;
  76.        }
  77.  
  78.       location ~ \.php$ {
  79.         fastcgi_pass   127.0.0.1:1025;
  80.        }
  81.           }
  82. }
  83.  
Add Comment
Please, Sign In to add comment