浏览 2.2k

按点赞数排序
按时间排序
自问自答了。看了一下代码,感觉ngx_http_compile_complex_value和ngx_http_script_compile是两套实现,前者对后者进行了封装,使用起来应该更方便。
比如,如果有一个指令需要支持复杂变量,使用ngx_http_compile_complex_value只需要定义一个ngx_http_complex_value_t变量就可以。但是使用ngx_http_script_compile需要定义flushes,lengths,variables一系列数组。。
server{
location /qy-api/ {
set $target_url https://qyapi.weixin.qq.com$request_uri;
proxy_pass http://squid_backend;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
rewrite ^/qy-api(.*) $1 break;
}
}
upstream squid_backend { server squid_server_ip:squid_server_port; }
这样配置好像不行
微信公众号
加入微信群