0

How do I dynamically create subdomains for my Node Js app hosted on AWS EC2?

For instance, I want to allow users to create their own subdomains when they register such as john.mydomain.com.

Hosting: AWS EC2 Server: Node Front-end: Angular

2 Answers2

1

You would need to wildcard your subdomains so that everything resolves to mydomain.com. There's a node.js package for handling this. https://github.com/patmood/wildcard-subdomains.

Ref - use dynamic subdomains with nodejs

denchie
  • 41
  • 2
0

you can use SDK call form nodejs to aws route53 with name.example.com with respective link to relative to path to web page