cul-2016 / quiz

11 stars 4 forks source link

Setting up correct DNS entries and SSL certificates #651

Open stianr opened 6 years ago

stianr commented 6 years ago

As product owner, I want my users to be able to view both the Quodl website (with information about Quodl), and log in to use the app itself.

We have two components at the moment: Quodl-the-app and Quodl-the-site. Their URLs are:

App: www.quodl.co.uk, Site: quodl-site.herokuapp.com

We want to set it up so that they are:

App: app.quodl.co.uk, Site: www.quodl.co.uk

I can update CNAME and any other DNS settings as required from my end, but at the moment I don't have access to/ownership of quodl-site on heroku, so can't update anything at that end. I'm assuming we need to add a domain name on Heroku.

I’m guessing we also need to update references within the website (particularly ‘Log In’) to refer to app.quodl.co.uk rather than www.quodl.co.uk.

stianr commented 6 years ago

In Heroku, I have set up a domain name for app.quodl.co.uk, and set up the appropriate CNAME and target (app.quodl.co.uk.herokudns.com) with my uk2 host. This works, but throws an alert because the security certificate is for www.quodl.co.uk. I'm guessing I need to update my SSL details, but won't want to risk bringing in security errors for the current location of the app www.quodl.co.uk, as it is still in use.

stianr commented 6 years ago

I've moved SSL certificate management to automatic on Heroku, and so app.quodl.co.uk all seems to be working with no errors now.

So just now need to (a) update login link on site to app.quodl.co.uk (and do we also need to update links to follow in registration emails?); (b) get www.quodl.co.uk to point to the site rather than the app.

iteles commented 6 years ago

@stianr Fantastic!

Yes, we'll need to update both the login link on the site and the links in the emails, we'll look to do this this coming week. Is there a day or days when this would make most sense? i.e. the app isn't being used?

Pointing www.quodl.co.uk to the site should be relatively straightforward (famous last words) and depending on how you have set this up already, will involve something like adding a www record to the heroku app for the site. Seeing as you have this set up already (for the app), it should be a straightforward swap of one for the other!

stianr commented 6 years ago

Thanks for your help with this @iteles. This is now updated. The only remaining issue seems to be around allowing secure connections for the site - it may be we need to get an SSL certificate for the site as well as the app? As it's specific to the site, I've logged the issue there:

https://github.com/cul-2016/site/issues/50