why 发表于 2018-11-10 12:22:08

Nginx-添加echo模块

# cat nginx.conf  
#usernobody;
  
worker_processes1;
  
events {
  
    worker_connections1024;
  
}
  
http {
  
    include       mime.types;
  
    #include       conf.d/vhost.conf;
  
    default_typeapplication/octet-stream;
  
    #log_formatmain'$remote_addr - $remote_user [$time_local] "$request" '
  
    #                  '$status $body_bytes_sent "$http_referer" '
  
    #                  '"$http_user_agent" "$http_x_forwarded_for"';
  
    #access_loglogs/access.logmain;
  
    sendfile      on;
  
    tcp_nopush   on;
  
    keepalive_timeout65;
  
    gzipon;
  
    server
  
    {
  
    listen 80;
  
    server_name 127.0.0.1;
  
    location / {
  
    echo "123";
  
    }
  
    access_log logs/tomcat1_access.log;
  
    }
  
}


页: [1]
查看完整版本: Nginx-添加echo模块