【问题标题】:How to redirect subdomain to a special port?如何将子域重定向到特殊端口?
【发布时间】:2017-03-28 10:51:02
【问题描述】:

就我而言,主机是我在 Digital Ocean 的实例之一,但我使用 Cloudflare 作为我的 DNS 服务器。

我尝试将我的域和子域重定向到特殊端口,但不起作用。

域 RSV 设置(无效):

Type: RSV Name: _http._tcp.mydomain.life Value: SRV 0 0 8080 mydomain.life <- ip is 128.99.12.34 TTL: Auto

子域 RSV 设置(无效):

Type: RSV Name: _http._tcp.mysub. Value: SRV 0 0 8080 othersubdomain.mydomain.life <- ip is 128.99.12.34 TTL: Auto

我已经为 mydomain.life 和 mysub.mydomain.life 创建了 A 记录。

结果是,两者都没有重定向到128.99.12.34:8080(netdata),

但只连接到 128.99.12.34(ghost)

我错过了什么吗?

或者任何其他解决方案可以帮助我将域/子域重定向到特殊端口?

【问题讨论】:

    标签: node.js cloudflare ghost netdata


    【解决方案1】:

    记录没有端口信息。

    要使用 SRV 记录,您需要一个客户端来查询 SRV 记录并使用 ip:port 执行某些操作。

    如果您想将某些内容重定向到 ip:port,您需要使用某种反向代理或 Web 服务器来处理它(nginx、haproxy、...)

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2014-05-17
      • 2014-07-02
      • 2016-03-21
      • 2023-03-13
      • 2019-05-04
      • 2020-02-23
      相关资源
      最近更新 更多