felixrieseberg / Ghost-Azure

:ghost: Install Ghost on Azure with a simple click
MIT License
127 stars 210 forks source link

Ghost url not using custom domain #57

Open edwardwilson opened 7 years ago

edwardwilson commented 7 years ago

After deploying to azure I added a custom domain. I updated the setting in the azure portal to reflect my change. The setting now reads: https://edwardwilson.me. However my theme which uses the url helper in ghost still returns the azurewebsites.net url. I have restarted many times.

FlyOrDie commented 7 years ago

Same here. My custom domain works, but when i try to go to mysite.domain/ghost i am redirected to mysite.azurewebsites.net/ghost and it fails. I updated the websiteUrl to http://mysite.domain, but it doesn't still works

pliljecrantz commented 7 years ago

Same here, but when I add my custom domain to websiteUrl, save and restart the WebApp I get a HTTP 500 error until I remove the websiteUrl setting in the portal.

Selmirrrrr commented 7 years ago

Anyone with a solution here ?

FBoucher commented 7 years ago

Witch version of Ghost are you using?

Selmirrrrr commented 7 years ago

The latest, 0.11.3 just upgraded yesterday, but the issue was also there on previous versions.

pliljecrantz commented 7 years ago

Same as above, just upgraded a few days ago to 0.11.3 and the error persists since earlier versions as well.

piyushpaliwal commented 7 years ago

@FlyOrDie The reason why you get redirected to azurewebsites is because /ghost is the admin panel and you want this to be served over HTTPS thus it uses the wildcard certificate *.azurewebsites.net that Microsoft provides. In a nutshell whatever you are experiencing is absolutely ok :)

piyushpaliwal commented 7 years ago

@edwardwilson under the app setting you might want to add a new key WebsiteUrlSSL and mention your https link here and revert the WebsiteUrl back to http link of your custom domain. Finally restart the app and it should be back to normal.

Porges commented 7 years ago

Thanks, @piyushpaliwal. Setting WebsiteUrlSSL did indeed solve the problem.

kdcllc commented 7 years ago

@felixrieseberg, WebsiteUrlSSL was the same fix for me. Maybe it can be default value part of the deploy profile.

darrenshrwd commented 7 years ago

Arggh!!! :-) The readme page should be updated to mention WebsiteUrlSSL

DevOpsBoondoggles commented 7 years ago

I've added a wiki page to cover this

https://github.com/felixrieseberg/Ghost-Azure/wiki/Setup-with-Custom-Domain-on-HTTPs-(Cloudflare-for-example)