Hi, my name is Eunjae.
I'm working on a multi tenant app and stuck at a problem. The domain is "http://quill.so" and customers will have their own subdomain like "http://user1.quill.so"
If they have a domain like "http://user1.com", how can I let them connect them?
I guess in their domain registrar, they should put A record and CNAME to mine? And.. what is mine? I'm hosting this app on Vercel.
I'm wondering if I need to have a sort of name server or something like that on my own?
What do I need to learn? I'm not familiar with these.
You'll need to provide your users with a DNS target that they add in their domain dashboard.
You can use vhost then to parse the subdomain for incoming requests and get the 'user1' part and do whatever you need to do with it.
You'll need an SSL cert with a wildcard, which can be tricky once you reach over 100+ users. Heroku will manage this for you up to 100 users.
For the management of the multi-tenant aspects, you probably want to use something like Authress, which will solve SSO login and user access management.
For the domain masking, you actually need two pieces:
user1.comthat you can use to encrypt resources in your app, you'll need an additional cert for every domain you want to serve. This is fairly complicated, so my recommendation is use a TLS provider. We use AWS to request custom certs. But you could roll something with Traefik and LetsEncryptThanks for the comment. I will look into what you said and will get back here when I figure it out :)
I've solved this issue (probably in an unconventional way due to the product needs).
If you're interested:
https://buttondown.email/quill/archive/3ed93ce1-f4cd-4cd8-bae8-1bb4c0bbd73a
https://buttondown.email/quill/archive/2798abf4-a68e-4566-b0d1-e0e6ed77b98d
Hi Eunjae,
I know its not what you were expecting to hear but I strongly recommend leaving the vanity domain feature till much, much later.
I mean I access my business email from https://mail.google.com/mail/u/0/#inbox and its fine. I'm hard pressed to think of an example where my own domain when accessing an app would be a feature worth the effort.
I'm not sure what you mean. It's a website generator like wix, square space, super.so, etc. People will want to use their own domain for their website.
Our website is hosted on S3 because we pointed our domain at S3. What you describe above is features where you control subdomains and domains for people - I still don't see the urgency of that feature.
For that matter if I were implementing your app I would probably just output to S3 and let people take it from there.
I think @noahwbragg recently solved this with an indie hacker product.
We have a custom solution at https://versoly.com/ but spent 2 years perfecting it.
Hey! Thanks Volkan.
Yeah, you can do this all with vercel and their api. they handle custom domains and ssl for you. The kicker is they have a limit of 50 domains on their free and pro plans. I think you have to pay $500/mo to get more domains.
So I used this solution as Volkan mentioned: https://approximated.app. It's a reverse proxy that handles the customer domain and ssl certs. You point your customer's domains to that proxy and then the proxy can point to the vercel domains. It has and api to do this. One downer currently is you miss out on a CDN. but the creator is working on adding that as well.
Thanks for the information! I know about the limit of 50 domains at Vercel and reached out to them about more info if I need more domains, but haven't heard of them. And now I know thanks to you.
Approximated looks like exactly what I need. I guess I can live without CDN for now.
If you don't mind, can I ask you some questions?
This comment was deleted 5 years ago