proxy_cache_valid any 1m; # 对于其他任何响应状态码,设置缓存有效期为1分钟。
}
}
复制代码
4、热加载nginx配置
[root@s76 conf.d]# nginx -t
nginx: the configuration file /etc/nginx/nginx.conf syntax is ok
nginx: configuration file /etc/nginx/nginx.conf test is successful
[root@s76 conf.d]# nginx -s reload
5、禁止client访问外网
[root@s76 conf.d]# nginx -t
nginx: the configuration file /etc/nginx/nginx.conf syntax is ok
nginx: configuration file /etc/nginx/nginx.conf test is successful
[root@s76 conf.d]# nginx -s reload
13、客户端设置http代理