简体   繁体   English

将子域和root / www指向不同的Heroku应用

[英]Point subdomain and root/www to different Heroku apps

I've been trying to set up the DNS for a couple of apps using the same domain. 我一直在尝试为使用相同域的几个应用程序设置DNS。

I want www.playfade.com and playfade.com to redirect to playfade.herokuapp.com, so set up a CNAME and ALIAS respectively to point to the Heroku app. 我希望将www.playfade.com和playfade.com重定向到playfade.herokuapp.com,因此分别设置一个CNAME和ALIAS以指向Heroku应用程序。 This works fine. 这很好。

I also want beta.playfade.com to point at soundedout.herokuapp.com. 我也希望beta.playfade.com指向soundedout.herokuapp.com。 To do this, I set up a CNAME for beta.playfade.com to soundedout.herokuapp.com. 为此,我将beta.playfade.com的CNAME设置为soundedout.herokuapp.com。 This, however, doesn't work. 但是,这不起作用。 When I access beta.playfade.com, I'm redirected to www.playfade.com. 当我访问beta.playfade.com时,我被重定向到www.playfade.com。

I used MXToolbox to check beta.playfade.com and was given a few errors: 我使用MXToolbox检查beta.playfade.com,但出现了一些错误:

  Bad Glue Detected Parent server gave glue for beta.playfade.com to be soundedout.herokuapp.com but we resolve that hostname to 176.34.187.173 At least one name server failed to respond in a timely manner Failure detail: 176.34.187.173 Local NS list does not match Parent NS list 50.31.242.53 was reported by the parent, but not locally 198.241.11.53 was reported by the parent, but not locally 198.241.10.53 was reported by the parent, but not locally 50.31.243.53 was reported by the parent, but not locally 176.34.187.173 was reported locally, but not by the parent Serial numbers do not match 

I've set up the domains correctly in the heroku dashboard as well. 我也已经在heroku仪表板中正确设置了域。

Any help would be appreciated. 任何帮助,将不胜感激。

➜  ~  dig beta.playfade.com

; <<>> DiG 9.8.3-P1 <<>> beta.playfade.com
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NXDOMAIN, id: 64369
;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 1, ADDITIONAL: 0

;; QUESTION SECTION:
;beta.playfade.com.     IN  A

;; AUTHORITY SECTION:
playfade.com.       296 IN  SOA ns1.dnsimple.com. admin.dnsimple.com. 2014110501 86400 7200 604800 300

;; Query time: 668 msec
;; SERVER: 85.37.17.16#53(85.37.17.16)
;; WHEN: Thu Nov  6 10:29:27 2014
;; MSG SIZE  rcvd: 90

There is no CNAME configured for the hostname beta.playfade.com . 没有为主机名beta.playfade.com配置CNAME。 Make sure to properly configure it, and make sure you have no redirect configuration inside the app (or if you have it, tweak it accordingly). 确保正确配置它,并确保您在应用程序内部没有重定向配置(或者,如果有,请进行相应的调整)。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM