Custom URL for your Openshift Application

As I started to use OpenShift more and more for my own application hosting, I was always curious to know that how do I get my OpenShift URL to look like the domain name I just bought. While it is great that openshift let you create your own <appname>-<domainname>.rhcloud.com, when you want to show your app to the world you want might your own domain name.

Now here comes the part where things get interesting. I need to associate my mycustomdomain.com (my own domain) DNS name with my OpenShift url blog-cloudbuzz.rhcloud.com. The key to understanding how to do this is to understand CName records in DNS. The basic idea with a CName record is that one name (mycustomdomain.com) points to another name (blog-cloudbuzz.rhcloud.com). If you want to forward over your whole domain, such as mycustomdomain.com and not www.mycustomdomain.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.

“Naked domains” is a term for a URL without the ‘www’. e.g. ‘mycustomdomain.com’ is a naked domain and ‘www.mycustomdomain.com.com’ is not a naked domain.

The initial setback was that ‘naked domains’ are against RFC rules; the good news however is ‘CNAME flattening‘ bypasses the restriction of RFC DNS specifications. Who does ‘CNAME flattening’ you might ask?! Well, I personaly prefer CloudFlare because its very easy to confirgure and use. Follow the below steps to get started and redeem hours and hours of pain.

Step 1

Head over to cloudflare.com and sign up.

Step 2

Type your website URL without the ‘www’ and click “Add Website”. And point your GoDaddy’s domain name’s DNS name to point to CloudFlares.

CloudFlare will add you new entry and start to scan your websites DNS records.

Once the scan has completed, click on “Continue Setup”.
Once you click on click on “Continue Setup” CloudFlare will scan your record. Wait for some time!!!

Step 3

Change the CNAME records to something similar to this. Kindly user your details like OpenShift URL and related IP address.

Step 4

Sleep, let the changes simmer over night for the changes to take affect. 24 hours minimum. Most of the cases it will be done within 30 mins but maximum is 24 hrs.

Step 5

Open  CNAME record for your domain and update name server details as follows.

How do I change (point) my nameserver settings in GoDaddy?

1. Log in to your GoDaddy account.

2. From the Products menu, click Launch next to Domains.

3. Tick the box next to the domain you are going to manage.

openshift-cloudflare-7

4. Hover over the Nameservers link in the menu and select Set Nameservers

openshift-cloudflare 8

5. Choose Custom and click on Enter custom nameservers.

6. Now you can place the mycustom domain nameservers into the two fields below. These will be chad.ns.cloudflare.com and chan.ns.cloudflare.com (might differ in your case, kindly refer your cloudflare account once)

Then click OK and then Save

Step 6

Set alias in OpenShift to mycustomdomain.com

Step 7

Make sure GoDaddy DNS record doesn’t have any conflicting cname or A record set up.

Step 8

Let it simmer for some time and all of the original desired behaviour should be working.

10
37 Comments
  • market trends
    June 14, 2015

    Excellent pieces. Keep writing such kind of information on your site.
    Im really impressed by your blog.
    Hello there, You have done an excellent job. I’ll certainly digg it and in my opinion recommend to my friends.

    I’m confident they’ll be benefited from this site.

  • JessikaSHoultberg
    July 5, 2015

    What’s up it’s me, I am also visiting this website on a regular
    basis, this website is truly nice and the viewers are in fact sharing nice thoughts.

  • ElseSHarshberger
    July 7, 2015

    Hi there to every one, since I am actually eager
    of reading this web site’s post to be updated regularly.
    It includes pleasant material.

  • MaryanneWNorthcut
    July 10, 2015

    Because the admin of this web page is working, no doubt
    very quickly it will be famous, due to its feature contents.

  • BretZSaddat
    July 11, 2015

    Hmm it looks like your blog ate my first comment (it was extremely long) so I guess I’ll just sum
    it up what I submitted and say, I’m thoroughly enjoying your blog.
    I too am an aspiring blog writer but I’m still new to the whole thing.
    Do you have any suggestions for novice blog writers?
    I’d definitely appreciate it.

  • IraidaGGuilstorf
    July 12, 2015

    Just desire to say your article is as astonishing. The clarity in your post is simply great and i could
    assume you are an expert on this subject. Fine with your
    permission let me to grab your RSS feed to keep updated with forthcoming post.

    Thanks a million and please carry on the gratifying work.

  • quest bars
    August 18, 2015

    Heya i’m for the primary time here. I found this board and I in finding It really helpful & it helped me out much.
    I am hoping to present something again and aid others like
    you aided me.

  • quest bars
    August 21, 2015

    Truly no matter if someone doesn’t know afterward its up to other viewers that they will help, so here
    it occurs.

  • http://thedigitalbridges.com
    September 1, 2015

    I have a powerful respect for your writing and advice.

  • michael crork
    September 2, 2015

    M2CPLY Keep up the wonderful piece of work, I read few blog posts on this internet site and I believe that your blog is rattling interesting and has got bands of superb information.

  • minecraft games
    September 10, 2015

    Remarkable! Its in fact remarkable paragraph, I have got much clear
    idea concerning from this post.

  • plenty of fish dating site of free dating
    September 24, 2015

    Appreciating the commitment you put into your blog and detailed information you present.
    It’s awesome to come across a blog every once in a while that isn’t the same old rehashed information. Excellent read!
    I’ve saved your site and I’m adding your RSS feeds to my
    Google account.

  • Health Benefits Of Coconut Oil
    September 30, 2015

    An impressive share! I have just forwarded this onto a friend
    who had been conducting a little research on this.
    And he actually ordered me lunch simply because I stumbled upon it for him…
    lol. So let me reword this…. Thanks for the meal!!
    But yeah, thanks for spending time to talk about this issue
    here on your web page.

  • Plenty Of Fish Dating Site Of Free Dating
    October 16, 2015

    We stumbled over here by a different web address and thought I might as well check things out.
    I like what I see so i am just following you.
    Look forward to checking out your web page again.

  • Pof.
    October 16, 2015

    Greetings! This is my 1st comment here so I just wanted to give a quick shout out and say I really enjoy
    reading your articles. Can you recommend any other blogs/websites/forums that cover
    the same subjects? Thanks a lot!

  • eebest8
    November 27, 2015

    Im no pro, but I suppose you just crafted a very good point point. You obviously fully understand what youre speaking about, and I can truly get behind that. Thanks for being so upfront and so truthful.

  • fiverr seo
    November 27, 2015

    This is a good tip particularly to those new to the blogosphere.

  • crork service
    November 29, 2015

    f6PIcn Thanks so much for the article.Thanks Again. Cool.

  • original site
    December 4, 2015

    I simply want to mention I am beginner to weblog and truly enjoyed you’re blog site. Probably I’m going to bookmark your site . You certainly have really good stories. Many thanks for sharing your blog site.

  • brazil
    December 28, 2015

    Thanks-a-mundo for the blog article. Cool.

  • massage
    December 29, 2015

    Im obliged for the blog article.Really thank you! Awesome.

  • FayeRMorasch
    August 8, 2016

    Howdy! Quick question that’s completely off topic.
    Have you any idea steps to make your web site mobile friendly?
    My website looks weird when browsing from
    my iphone4. I’m looking for a theme or plugin that might be able to correct this problem.
    In case you have any suggestions, please share.
    Cheers!

  • BryceYPuraty
    August 10, 2016

    I such as the helpful information you provide inside your articles.
    I will bookmark your blog and check out once again right here regularly.
    I’m quite sure I’ll be informed many new stuff proper
    right here! Best of luck for the subsequent!

  • bastcilk doptb
    August 10, 2016

    I visited a lot of website but I think this one has got something special in it in it

  • HarryUTutela
    August 14, 2016

    I used to be able to find good advice from your articles.

  • LeannYHouska
    August 16, 2016

    This is my first time go to see at here and i am genuinely pleassant to read everthing at alone place.

  • MendyKCriton
    August 17, 2016

    I have to be grateful for the efforts you’ve devote penning
    this website. I seriously hope to find out the identical high-grade content
    from you down the road too. The truth is, your creative
    writing abilities has motivated me to acquire my personal
    blog now 😉

  • GreggDHillie
    August 17, 2016

    Its as if you read my mind! You seem to learn a great deal about this,
    including you wrote the book in it or something. I feel that you just
    can do with a few p.c. to drive the content home a bit, however instead of that, this is
    magnificent blog. An incredible read. I’ll definitely be
    back.

  • LouECuttitta
    August 18, 2016

    Our company is a gaggle of volunteers and starting a completely new scheme within our community.
    Your site offered us with useful information to work on. You’ve
    done an amazing activity and our entire community may be grateful for you.

  • KurtDLaski
    August 19, 2016

    I really like looking through a post that may make people think.
    Also, many thanks for permitting me to comment!

  • KelleyEOkolo
    August 23, 2016

    Hello mates, its impressive paragraph concerning teachingand completely defined, keep it up all the time.

  • LatanyaZCane
    August 30, 2016

    Hey There. I discovered your site using msn. This is an incredibly well written article.
    I’ll ensure to bookmark it and come back to see a greater portion of your useful information. Thank
    you for the post. I’ll certainly comeback.

  • Roxane Catrambone
    August 31, 2016

    Hello.This post was extremely fascinating, especially because I was looking for thoughts on this topic last Tuesday.

  • ChadGCookson
    September 2, 2016

    Saved as a favorite, I like your website!

  • bastcilk doptb
    September 8, 2016

    Hello, you used to write wonderful, but the last few posts have been kinda boring… I miss your super writings. Past few posts are just a little bit out of track! come on!

  • MonroeZScarr
    September 9, 2016

    My coder is intending to convince me to maneuver to .net from PHP.
    We have always disliked the theory due to expenses.
    But he’s tryiong none the less. I’ve been using WordPress
    on various websites for roughly a year and am concerned about switching to
    a different platform. We have heard good aspects of blogengine.net.

    What is the way I will transfer all my wordpress
    posts with it? Any help can be greatly appreciated!

  • look here
    October 29, 2016

    I just want to say I am just newbie to blogging and site-building and definitely loved you’re web page. Almost certainly I’m going to bookmark your blog . You definitely come with amazing article content. Thanks a bunch for revealing your webpage.

Leave a Reply

Your email address will not be published. Required fields are marked *