Hubs-Foundation / hubs-cloud

Resources for self hosted Hubs Cloud instances
Mozilla Public License 2.0
152 stars 95 forks source link

Changing Primary Domain locked admin out of instance #112

Closed antpb closed 3 years ago

antpb commented 3 years ago

Hello! I have a Hubs Cloud instance that I changed the primary domain for and now I'm locked out of login and cannot create rooms due to CORS errors that are referencing the previous primary domain.

Previously domain recipe looked like the following: primary: hubs.broken.place internal: brokenplace.com link: bpxr.link

The new configuration is the following: primary: hubs.xpportal.io internal: brokenplace.com link: bpxr.link

The stack update changing the domain/ssl worked great, and I was able to configure/validate SES properly. Worth noting, the instance had a custom client pushed prior to the primary domain change. I also ensured there were no rogue parameter stores referencing the old domain. The below error happens when creating a new room after a successful stack update that changes primary domain:

phoenix-utils.js:184 Refused to connect to 'https://hubs.broken.place/api/v1/hubs' because it violates the document's Content Security Policy. Notice the url referenced is the old one.

The login form no longer is sending the login email however, using the npm run login command from my custom client locally was able to send the login email which upon clicking, was met with a content security error. Here's a screenshot of the sign in link error:

Screen Shot 2020-09-18 at 12 47 49 AM

This feels related to what I suspect to be cleanup issues in https://github.com/mozilla/hubs-cloud/issues/107

antpb commented 3 years ago

I know a fix in my case would be destroying the instance and making a new one, but I thought I would report this as I anticipate changing a primary domain to be a frequent task for some folks.

robinkwilson commented 3 years ago

Thanks for the steps. We mention in our docs that changing domains is a tear down option not an update the stack action. https://hubs.mozilla.com/docs/hubs-cloud-aws-updating-the-stack.html

I'm afriad, we're not planning on changing this anytime soon, if at all.