---
title: "[web architect] tomcat+nginx单机"
author: "marshan"
date: "2012-12-24T18:39:37Z"
tags: []
categories: ["Web前端"]
slug: "web-architect-tomcat-nginx"
draft: false
lastmod: "2012-12-24T18:39:37Z"
id: 1753350
url: "https://feuyeux.iteye.com/blog/1753350"
---

location / {

            root   /cygdrive/d/codes/airfactory/air-restful/src/main/webapp;

            index  index.html index.htm;

        }

location /restful/ {

            proxy\_set\_header  Host $host;

proxy\_set\_header  X-Real-IP  $remote\_addr;

proxy\_set\_header   X-Forwarded-For $proxy\_add\_x\_forwarded\_for;

proxy\_pass http://localhost:8080/air-restful/restful/;

        }