在nginx中配置子目录应用程序

时间:2012-11-13 00:25:02

标签: nginx

有人可以帮我配置我的nginx:

/ app - >是本地的html页面

/ - >是https服务器,它没有应用程序文件夹

以下内容对我没有用处:(

server {
    listen              80;
    ssl_verify_client   off;
    server_name         localhost;
    location / {
        proxy_pass_header Server;
        proxy_set_header  Host $http_host;
        proxy_set_header  X-Real-IP $remote_addr;
        proxy_set_header  X-Scheme $scheme;
        proxy_pass        https://xx.xx.xx.xx/;
    }
    location /app {
      root "c:\LOCAL_PATH\app";
      index  index.html;
    }
}

1 个答案:

答案 0 :(得分:0)

扩展您的location / - 阻止以下操作:

location / { rewrite ^ https://$host$request_uri?; }
相关问题