V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
lintoy
V2EX  ›  DotCloud

求教DOTCLOUD上能不能做反向代理的裸域绑定

  •  
  •   lintoy · 2011-08-05 14:08:30 +08:00 · 8648 次点击
    这是一个创建于 4619 天前的主题,其中的信息可能已经有所发展或是发生改变。
    就像下面这个贴里一样的。
    http://www.v2ex.com/t/6663#reply16
    方法绑定一个域名做反向代理

    试了下面方法不行。
    创建 一个nginx.conf 配置文件

    server{

    listen 80;

    server_name bbs.mucun.tk;

    location / {

    proxy_redirect off;

    proxy_pass http://mucunbbs.appspot.com;

    proxy_set_header X-Real-IP $remote_addr;

    }

    }
    4 条回复    1970-01-01 08:00:00 +08:00
    CoX
        1
    CoX  
       2011-08-05 14:43:09 +08:00
    貌似是不行的吧
    ratazzi
        2
    ratazzi  
       2011-08-05 15:36:21 +08:00
    加个 Host 的头试下
    CoX
        3
    CoX  
       2011-08-05 17:15:59 +08:00
    现在ghs.google.com貌似可以直接用,不用再反向一次吧
    feiandxs
        4
    feiandxs  
       2011-08-05 17:51:02 +08:00
    #########
    server {
    listen xxxxxxx:80;
    server_name bbs.mucun.tk;

    location / {
    proxy_pass http://mucunbbs.appspot.com;
    proxy_set_header X-Real-IP $remote_addr;
    proxy_set_header FORWARDED-FOR $remote_addr;
    proxy_set_header Host bbs.mucun.tk;
    #set_real_ip_from xxxxxx;
    #real_ip_header X-Real-IP;
    #expires 3d;

    }

    }
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   5866 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 25ms · UTC 02:16 · PVG 10:16 · LAX 19:16 · JFK 22:16
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.