Reputation: 457
I have spent the better half of two days trying to figure out how to do what should be the easiest thing in the world. I have registered a domain with godaddy and need the appropriate method in which to use it with a application built with the laravel framework hosted on on openshift site.
I would like to know the appropriate way of doing this if anyone knows, not just some work around that could potentially have negative implications down the road be it seo or response time.
I starting to draw the conclusion that this is more suited for development of apps and not actual hosting seens how something this important it seems almost impossible to find a correct direction.
thx in advance for any guidance.
Upvotes: 1
Views: 867
Reputation: 1913
If you want to forward your domain.com
to www.domain.com
, you can use a naked domain redirect provider.
Upvotes: 0
Reputation: 457
So after much research I found out this a common this when using Paas. The problem stems from not being able to point your A host(zone apex)to a cname. You would normally point your A host to the IP addres of you application but with most Paas this IP can change unannounced. I finally settled on using a 301 redirect from my zone apex to a cname www that points to my application on openshift. This works great but does not allow for naked url in the address bar when someone goes to say example.com as everything redirects to www.example.com. No biggy just looks cleaner without the www. in the url. Currently looking into using CloudFlare CDN as I think I will be able to use my zone apex(naked domain) as a cname that points to my openshift application to accomplish the naked(non www.) address bar look.
http://blog.cloudflare.com/zone-apex-naked-domain-root-domain-cname-supp this link was great about describing the issues faced with this topic.
Thax once again jason
Upvotes: 0
Reputation: 18111
There should be just two steps to make the www url work:
Take a look at https://www.openshift.com/blogs/custom-url-names-for-your-paas-applications-host-forwarding-and-cnames-the-openshift-way
For the non-www url, from the blog post:
If you want to forward over your whole domain, such as mycompany.com and not www.mycompany.com, then you either need to use Domain Forwarding or find a DNS provider that allows "Naked" CName records. Domain forwarding uses a web server to do a redirect.
You can forward the non-www domain to the www one, where the CNAME record will work.
Upvotes: 3