Nginx是一款功能强大的web服务器软件,也是一款良好的反向代理服务器软件,下面我们通过实例快速配置nginx,展现其效果!!!
环境:
Web Server1:192.168.10.141
Web Server2:192.168.10.142
Nginx Server:192.168.10.145
分别访问Web Server1、Web Server2、Nginx Server



步骤一:
vi nginx.conf

###添加上图红色框图内容###
步骤二:

###修改上图红色区域内容,使其与http{}声明区域相呼应###
步骤三:
/etc/init.d/nginx restart
###重新启动nginx服务###
验证:

###至此,简单的nginx反向代理就完成的了,在接下来的篇章中我们会对其更深层次的解析!!!###
阅读(339) | 评论(0) | 转发(0) |