mirror of
https://github.com/XTLS/Xray-examples.git
synced 2024-11-23 17:11:29 +00:00
51 lines
943 B
Nginx Configuration File
51 lines
943 B
Nginx Configuration File
|
worker_processes auto;
|
||
|
worker_cpu_affinity auto;
|
||
|
worker_rlimit_nofile 65535;
|
||
|
|
||
|
error_log logs/error.log warn;
|
||
|
|
||
|
pid logs/nginx.pid;;
|
||
|
|
||
|
events {
|
||
|
worker_connections 1024;
|
||
|
use epoll;
|
||
|
multi_accept on;
|
||
|
}
|
||
|
|
||
|
http {
|
||
|
|
||
|
include mime.types;
|
||
|
default_type application/octet-stream;
|
||
|
|
||
|
index index.html index.htm
|
||
|
|
||
|
log_format main '$remote_addr - $remote_user [$time_local] $status '
|
||
|
'"$request" $body_bytes_sent "$http_referer" '
|
||
|
'"$http_user_agent" "$http_x_forwarded_for"';
|
||
|
|
||
|
sendfile on;
|
||
|
|
||
|
#tcp_nopush on;
|
||
|
|
||
|
#keepalive_timeout 0;
|
||
|
keepalive_timeout 65;
|
||
|
|
||
|
#gzip on;
|
||
|
|
||
|
server {
|
||
|
listen 127.0.0.1:80;
|
||
|
server_name yourserver_80.com;
|
||
|
|
||
|
charset utf-8;
|
||
|
|
||
|
access_log logs/yourserver_80.access.log main;
|
||
|
|
||
|
location / {
|
||
|
root /var/www/html;
|
||
|
}
|
||
|
|
||
|
error_page 404 /404.html;
|
||
|
|
||
|
error_page 500 502 503 504 /50x.html;
|
||
|
}
|
||
|
}
|