Allow users to point their domains at a path on my Galaxy hosted app

Hi,

I’ve got an app hosted on Galaxy at e.g. www.mysite.com and I’d like to allow each customer to point their own domain to a path on my domain, e.g. www.mysite.com/somename.

I’ve got a working solution for this already, but it feels like I’m probably doing either something not ideal or just plain wrong. What I do at the moment is:

  • I’ve set up another domain at domains.mysite.com which can be used to access my site and is listed in my app’s domains on the Galaxy dashboard.
  • I ask the user to create a CNAME for their domain to point to mine, e.g. www.theirsite.comdomains.mysite.com and ask them to add their domain name to their settings in my app
  • I then manually add their domain to the acceptable domains for my app in the Galaxy dashboard.
  • when it’s loaded, my app will compare the host header in the HTTP request to the domain info stored in the database and display the correct path for the user so that www.mysite.com/theirname appears to be served from www.theirsite.com

Any hints or tips on this would be greatly appreciated!
thanks, Nick

Hi, do you want to allow your users to also access www.mysite.com/theirdomain? Otherwise you don’t need to have this path after the host. You could use only their domain.

Also, I didn’t understand what problem you are having, what is the issue that you are looking for help exactly? Something is not working as you would expect?

hey @filipenevola thanks for the reply, perhaps I didn’t explain very well!

In my first post I was trying to ask if that strategy outlined is a good one for allowing users to point their domains at an arbitrary folder on my site so that it appears to be served from their domain.

I suppose the most important point I’m looking for is whether I’m able to do this without manually adding their domain to the list of accepted domains in the ‘DOMAINS & ENCRYPTION’ section of my apps Galaxy dashboard.

Hey @nickeday ,
I’d like to know if you managed to optimise this feature and how you did it ?

1 Like