你好,游客 登录 注册 搜索
背景:
阅读新闻

Nginx+Apache+SSL+SVN svn copy 出现502 Bad Gateway

[日期:2015-02-12] 来源:Linux社区  作者:john88wang [字体:大 中 小]

使用Nginx通过https方式访问SVN服务器,执行svn copy的时候出现以下错误:
svn: Server sent unexpected return value (502 Bad Gateway) in response to COPY request for

解决办法:
  location / {
        proxy_redirect    off;
        proxy_set_header  Host $host;
        proxy_set_header  X-Forwarded-Host $host;
        proxy_set_header  X-Forwarded-Server $host;
        proxy_set_header  X-Real-IP        $remote_addr;
        proxy_set_header  X-Forwarded-For  $proxy_add_x_forwarded_for;
        proxy_buffering    on;
 
        set $fixed_destination $http_destination;
        if ( $http_destination ~* ^https(.*)$ ) {
            set $fixed_destination http$1;
        }
        proxy_set_header Destination $fixed_destination;
 
        proxy_pass        http://127.0.0.1:88;
    }

主要是增加了

set $fixed_destination $http_destination;
        if ( $http_destination ~* ^https(.*)$ ) {
            set $fixed_destination http$1;
        }

Nginx 502错误触发条件与解决办法汇总 http://www.linuxidc.com/Linux/2014-08/105815.htm

502 bad gateway是什么意思?502 bad gateway怎么解决! http://www.linuxidc.com/Linux/2013-04/82075.htm

Nginx 的详细介绍:请点这里
Nginx 的下载地址:请点这里

本文永久更新链接地址:http://www.linuxidc.com/Linux/2015-02/113293.htm

linux
相关资讯       502 Bad Gateway 
本文评论   查看全部评论 (0)
表情: 表情 姓名: 字数

       

评论声明
  • 尊重网上道德,遵守中华人民共和国的各项有关法律法规
  • 承担一切因您的行为而直接或间接导致的民事或刑事法律责任
  • 本站管理人员有权保留或删除其管辖留言中的任意内容
  • 本站有权在网站内转载或引用您的评论
  • 参与本评论即表明您已经阅读并接受上述条款