首页 > 系统相关 >nginx for windows

nginx for windows

时间:2023-01-11 20:35:38浏览次数:37  
标签:windows 10.168 nginx proxy timeout gzip fastcgi

nginx.conf

worker_processes 8;

error_log logs/ info;

events {
    worker_connections  2048;
}

http {
    include       mime.types;
    default_type  application/octet-stream;

    sendfile        on;
    tcp_nopush      on;

    keepalive_timeout  120;

    fastcgi_connect_timeout 300;
    fastcgi_send_timeout 300;
    fastcgi_read_timeout 300;
    fastcgi_buffer_size 64k;
    fastcgi_buffers 4 64k;
    fastcgi_busy_buffers_size 128k;
    fastcgi_temp_file_write_size 128k;

    gzip            on;
    gzip_min_length 1k;
    gzip_buffers 4 16k;
    gzip_http_version 1.0;
    gzip_comp_level 2;
    gzip_types text/plain application/x-javascript text/css application/xml;
    gzip_vary on;

    include vhosts/*.conf;
}

stream {
    include vstream/*.conf;
}

stream.conf

server {
    listen 33220;
    proxy_pass 127.0.0.1:33210;
    proxy_connect_timeout 1h;
    proxy_timeout 1h;
}

server {
    listen 33221;
    proxy_pass 127.0.0.1:33211;
    proxy_connect_timeout 1h;
    proxy_timeout 1h;
}
start nginx
tasklist /fi "imagename eq nginx.exe"
nginx -s stop
telnet 10.168.1.239 33220
telnet 10.168.1.239 33221
export https_proxy=http://10.168.1.239:33220 http_proxy=http://10.168.1.239:33220 all_proxy=socks5://10.168.1.239:33211

标签:windows,10.168,nginx,proxy,timeout,gzip,fastcgi
From: https://www.cnblogs.com/greene/p/17044819.html

相关文章

  • package:webview_windows 使用注意
    await_webViewController.loadUrl("F:/language/hbuilderx/code/test/test3.html");await_webViewController.loadUrl("file:///F:/language/hbuilderx/code/test/test3......
  • 在Windows上访问linux的共享文件夹
    1、https://blog.csdn.net/weixin_44147924/article/details/123692155   ......
  • nginx反向代理
     nginx反向代理location/edu{proxy_passhttps://c3wedu.hapu.net;proxy_set_headerHostc3wedu.hapu.net;proxy_set_headerX-Real-IP$re......
  • Nginx 进阶篇
    目录Nginx进阶篇五、服务配置1、配置成系统服务2、配置环境变量六、部署静态资源1、概述2、配置指令2.1listen2.2server_name2.3location2.4root2.5alias2.6i......
  • windows服务器需要输入mstsc /admin才能远程
    处理方式:删除注册表win+R,输入regedit进入注册表。HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\TerminalServer\RCM\GracePeriod......
  • thinkphp安装在子目录的nginx配置
    进行URL重写,将默认访问URL中的index.php?s=通过rewrite隐藏location/blog/{indexindex.phpindex.htmlindex.htm;if(!-e$request_filename){rewrite......
  • nginx反向代理,解决vue项目跨域问题
     nginx的配置:  把/api转到另一个域名下#PROXY-START/apilocation/api{expires12h;if($request_uri~*"(php|jsp|cgi|asp|aspx)"){expires0......
  • VUE项目的API项目的nginx配置
    #PROXY-START/apilocation/api{expires12h;if($request_uri~*"(php|jsp|cgi|asp|aspx)"){expi......
  • Windows配置NTP
    服务端Linux、Windows都可以,自行配置客户端此环境为WindowsServer2016,其他版本大同小异开始-运行-gpedit.msc,进入如下,首先配置NTP客户端启用NTP客户端更新......
  • nginx配置
    #Formoreinformationonconfiguration,see#*OfficialEnglishDocumentation:http://nginx.org/en/docs/#*OfficialRussianDocumentation:http://ngin......