访问地址:http://www.xxx.com配置如下:
server{listen80;server_namewww.xxx.com;access_loglogs/xxx.access.logmain;location/{roothtml;indexindex.htmlindex.htm;}location~.*.jsp${#匹配以jsp结尾的,tomcat的网页文件是以jsp结尾indexindex.jsp;proxy_passhttp://127.0.0.1:8080;#主要在这里,设置一个代理}}}