I push my app I create with Ruby on rails on heroku and I have by default myapp.herokuapp.com
I buy my domain name on OVH I do heroku domains:add www.myapp.co to redirect to myapp.herokuapp.com.
I want to have only www.myapp.co this target and keep this went I am on the app. Could you guide to configure it on OVH.
I read this https://devcenter.heroku.com/articles/custom-domains and do what they say i don't understand check my url synestasia.co
Thank your for your help. really don't understand.
Steps needed to point (redirect) your OVH root domain (eg. yourdomain.com) to your heroku application.
Go to domain section in OVH and select your domain. Then click DNS ZONE
Remove entries (you can omit this step but OVH will tell you the same when you try to add an entry): Domain: www.yourdomain.com with types of: CNAME yourdomain.com, TXT 3|welcome, TXT l|pl (but this may depend on the
language as I'm using PL language).
Add CNAME record with www subdomain and target to your heroku CNAME domain you have from heroku website eg. my-application-fcmnqo274218034.herokudns.com. Confirm clicking next and confirm next step too.
Go to the Redirection tab and click Add a redirection. Leave both fields blank (one with domain address where you need to fill subdomain and Also redirect www.yourdomain.com checkbox unchecked. Click Next.
In the next page you should see What type of target do you want to redirect yourdomain.com to? question. Select to a web address and click Next
Next page says What type of redirection do you want to use to redirect yourdomain.com ?. Select with a visible redirection. and click Next.
In the next window select Permanent (301) redirection and then you will be asked to provide your full address as in the placeholder eg. https://www.yourdomain.com, then click next and validate the redirect rule.
Domain propagation might take a while (up to ~24h but mine was ready in few minutes). To not cache domain pointing to the DNS in your browser (as this might be fooling your with your website not found but it might work for others) you might want to use some tool to check if domain points to new servers (eg. https://dnschecker.org - that's not spam, I have nothing common with them)
Thanks to this user for posting that solution: http://community.ovh.com/t/redirection-vers-app-heroku/6392/16
To serve your domain name from Heroku, you need to tell the DNS service you use where your server is hosted.
Typically, this is done by declaring an A record DNS entry: A records expect a static IP address and so you just fill in your server's IP.
The challenge with Heroku is that it uses dynamic IP addresses, so A records are not an option.
So the other option is to declare a CNAME record: a CNAME points a name to another CNAME or an A record.
Problem is: CNAMEs are NOT supposed to be used for root domains (AKA base domain or apex domain.) They will only work with subdomains.
So you could easily declare www.example.com to point to your Heroku app (on ANY DNS service, including OVH), but not example.com.
To help with this problem, some DNS services came up with their own solutions that basically let you point a root domain to another domain.
The Add a custom root domain section of the Heroku docs mentions a bunch of these providers:
ALIAS at DNSimple
ANAME at DNS Made Easy
ANAME at easyDNS
ALIAS at PointDNS
CNAME at CloudFlare -- a bit of a misnomer
OVH offers no such option (maybe unsurprisingly given most of their business comes from hosting servers.)
Bottom-line: if your domain name is provided by OVH, either use a subdomain (e.g.: www.mysite.com) or change your NS records to use a different DNS service, one that supports CNAME-like functionality at the apex.
I'm no sysadmin. I spent a lot of time on this issue too and hope this helps.
Heroku panel -> Your APP -> Settings -> Domains and certificates -> Add Domain.
Copy DNS Target
Log in OVH
WEB -> DOMAINS -> Your domain
DNS ZONE
Field: www.yourdomain.com | Type : CNAME | Target: yourdomain.com
Click " ... " -> Change Entry -> Delete Target -> Paste Heroku DNS Target + " . (dot)"
Sometimes you have to wait 24 hours.
Related
I have a domain name from whogohost. Iam currently hosting my app on heroku. The url of the website is rhemagist.herokuapp.com. I have tried to set the DNS target from heroku to whogohost. It is however giving me error. So i need some help to fix the error. Thanks in advance.
Login to your client area and Click on Domains >>> Manage DNS.
Click on Add new Zone Input your domain name without www in the field for Zone Name.
Input this IP address (174.129.25.170) in the IP address field.
Click on the Edit Icon. On the row that begins with WWW, replace your domain name with your Heroku DNS target and save.
Scroll up and click on add record. Copy and paste the shorter CNAME in the Name Field. Select CNAME in the dropdown. Then add your Heroku DNS target in the RDATA field
You can refer to this endpoint: https://www.whogohost.com/host/knowledgebase/121/How-do-I-map-my-domain-to-my-Blogspot-account.html
NB: Make sure that on Heroku, when adding your domain name, add it like this: www.domain.com and not just domain.com
When setting up my DNS my.domain.com (provided by GoDaddy) I am not sent to the correct address of my app, and the address in the URL bar is not what I expect either.
I have followed again and again the instructions outlined here: https://devcenter.heroku.com/articles/custom-domains#summary-of-steps
I have tried adding a record of type CNAME with host as www and the target URL as example-26hans7.herokudns.com
Two expectations are not met:
When I navigate to my.domain.com I am not brought to the app which I added a domain to in the Heroku CLI (my-app.herokuapp.com), but instead to an empty app page (example-26hans7.herokudns.com). The result is not the same if I navigate to my-app.herokuapp.com directly, then my app is loaded as expected.
The URL in the address bar I would like to be my.domain.com. At present it seems to be redirecting me and so the URL in the address bar becomes example-26hans7.herokudns.com. This is no good for production.
Any help in this matter greatly appreciated.
So it turns out you need to follow two steps in order for this to work with GoDaddy:
Create the CNAME as defined in the Heroku docs here: https://devcenter.heroku.com/articles/custom-domains
Enable forwarding. This can be found in the bottom right of the DNS management page. I had thought that forwarding was a redirecting option but it seems this needs to be enabled.
OPTIONAL: here you can also setup the subdomain such as example.com for www.example.com
I'm new to using Heroku so I'm a bit confused because I initially had my website hosted on GoDaddy, but when I added node to my web app I switched to Heroku.
So what is happening is when I visit my website using www. it goes to the correct, updated site, however, when I try the naked route it takes it to the older version of the website. I figured since it's still showing the older site with the naked route that there was a problem on GoDaddy, therefore, I updated one page on GoDaddy and sure enough, the page is updated via the naked route now.
That leads to my first question. If my website is now on Heroku, does it still need to be hosted on GoDaddy as well? Additionally, if the first question is yes, then how do I set up the naked route to point to the same site as the www. route?
I've already have the host as www with the 'points to' pointing to the Heroku domain name but still getting the problem above. This is why I believe the problem lies with the hosting on GoDaddy.
You don't need to host a copy of your site at Goddady.
In Godaddy, you must have a CNAME www pointing to heroku:
your_application_name.herokuapp.com
or
www.your_application_name.com.herokudns.com.
To use heroku for your naked domain, you can define a redirection for the naked domain to your www:
Go to My domains (https://dcc.godaddy.com/manage/)
Click on Manage connection
Set forwarding option (choose www.your_application_name.com, forward type permanent)
This is what helped me as of 2019. First, get to the list of your domain(s) on GoDaddy's interface. You'll see something like this:
GoDaddy's all domains page
Choose your domain. Once you're on your domain's settings, scroll to the bottom and click on 'Manage DNS'. You should see some records created, if there are any.
ACTUAL CONFIGURATION
FIRST STEP:
Create a CNAME record(there should be an 'add' button somewhere). The record should have the following parameters - Type - CNAME, Host - www, Points to - enter the link heroku created for your app.
creating a CNAME record on GoDaddy's
Sometimes when there are other old CNAME records, it'll throw an error. Erase old CNAME records and try again.
SECOND step:
Go to your terminal and enter the command 'host www.yourdomain.com'. If the CNAME record was successful, you should see the heroku domain you enter earlier. IMPORTANT - You should also see a bunch IP addresses which we will need.
THIRD step:
Create 'A' records for all the IP addresses provided on the 'host www.yourdomain.com' terminal command. They should have the following parameters: Type - A, Host - #, Points to - IP address, choose TTL custom and type 600 seconds.
This should do it
I have a client with three websites, each with separate c-panels for their hosting and dns management.
I need to point a subdomain from website-1 and website-2 to website-3, and then have their root be a subfolder on website-3.
I was able to set up a simple subdomain for website-3, and set it's root to the subfolder that I needed, but am having trouble pointing the other two sites.
It seems (from googling around) that the issue is caused by the site's all sharing an IP address, since they're all on the same server.
On website-3 where the subfolder is, I've tried setting up an "add-on domain" of test.website-1.com but get an error stating:
website-1.com is already configured. Sorry, that domain is already setup (remove it from httpd.conf)
I get a similar error trying to use the park a domain settings in the cpanel. I don't have access to the server in a way that lets me httpd.conf (unless there's a way through the cpanel).
Is there any other way to set this up that I'm missing?
If you are using IIS, you can create a website (Add Web site under Sites folder in IIS) in IIS and point to any folder. For example, if you are trying to point a subdomain mysubdomain.website-1.com to a particular folder, create a website in IIS that points to that subfolder, then in bindings, bind it to mysubdomain.website-1.com. In your domain registry, simply point the sub domain to the same IP of Website-1. I believe that should work.
Unfortunately, my knowledge is limited to IIS. If you are not using IIS, you may find other resources to configure a subdomain.
If all your primary domains are using same IP , you will not be able to point the subdomains as you have mentioned since all the subdomains also using the same IPs.
Instead of pointing the subdomain 1 subdomain 2 to subdomain 3 ... just set up redirects directly to subdomain 3 for each subdomain from their primary domain's cpanel.
You can easily set the redirects from Redirects option in cpanel
I've perused numerous posts on the subject and still do not have anything working. Currently:
I've registered my domain (intertexti.com) with Network Solutions.
NS created A Records that I cannot delete.
When I try to create a C Record with the alias "www", it complains that an A Record already exists.
Somewhere I read something that web forwarding was needed, so I signed up for web forwarding, forwarding the A Records to proxy.heroku.com
I've also added my custom domains in Heroku, both "intertext.com" and "www.intertexti.com"
The app itself can be found at: radiant-basin-3170.herokuapp.com
So, what I am looking for are clear and concise instructions on what I need to do with Network Solutions A and C Records to get this properly working. I think at this point Heroku is set up correctly.
Thanks in advance, I realize this has been asked before, but none of the suggestions I have tried have worked.
Marc
I realize this is an old post and you've probably arrived at a working solution by now. Given the lack of documentation for the NS and Heroku combination, I wanted to record what worked for me.
My goal was to allow users to type the naked root domain or the www third-level name (eg: intertext.com and www.intertext.com) and access the heroku project site (eg. "radiant-basin-3170.herokuapp.com").
Various options seemed plausible. I found a useful page at dnsimple.com that provided some background on "differences-between-a-cname-alias-url".
The specific solution was:
On the Heroku side I followed the instructions at: https://devcenter.heroku.com/articles/custom-domains
And then read this page at NS even though it was for blogs:
http://www.networksolutions.com/support/how-to-forward-your-network-solutions-domain-name-to-a-free-blog-service/
With that background, I did this at NS:
Logged in to the NS account via the "Manage Account" button in the
upper right of the home page.
Selected "My Domain Names" then "Edit Advanced DNS Records" for the domain.
Selected "Edit A Records".
Set the #(none) record to 205.178.189.129 Checked the delete box for the www and *(All Others) rows. Selected "Continue" at the bottom of the form.
Selected "Edit CNAME Records"
Created a record with the "alias box" set to www Left the TTL at 7200 and selected the "Other Host" button. In the "Other Host" box entered the heroku project address (e.g. radiant-basin-3170.herokuapp.com.) Note the ending period, it was significant. Selected "Continue".
Initially the page did not reflect the edits. I clicked "return to domain details" and re-clicked the "Edit Advanced DNS Records".
I had to repeat steps 2-7 a couple of times until the records showed
A records: www and * as blank and # set to 205.178.189.129 and a
CNAME for www as the Heroku project address.
Note for step #4: The IP address (205.178.189.129) is the NS "Under construction" page. It's from the NS blog forwarding link.
I managed to get my network solutions dns resolve to my heroku app. Not saying that this is 'the' way but this is what I did.
Sign up for a free account at zerigo https://www.zerigo.com/
In network solutions click on Edit DNS and remove the two network solutions entries, mine were,
NS53.WORLDNIC.COM
NS54.WORLDNIC.COM
I deleted these and then added the Zerigo servers
A.NS.ZERIGO.NET
B.NS.ZERIGO.NET
C.NS.ZERIGO.NET
D.NS.ZERIGO.NET
E.NS.ZERIGO.NET
Step 3. In Heroku go to the Add-ons https://addons.heroku.com/zerigo_dns
Step 4. Click on the Zerigo Basic and then select your heroku app domain and click on the 'Add Zerigo Basic for Free' *
Step 5. In the Heroku App Settings domains add the network solutions domain, I added two entries
mydomain.com
www.mydomain.com (substitute mydomain for the name of your domain)
The same process is described in the heroku dev center articles 'zerigo_dns#configure-dns-servers' - although they mention using the command line to install the addon and also add the domains to heroku. I didn't follow the steps under 'Managing MX and other host records' as the domain i have does not have mail. If step 3 does not work for you then try adding the add on using the command line.