Another awesome feature of DNS is the ability to specify a wildcard (*) as the subdomain.
I use this configured with nginx running as a reverse proxy on my server, so it can direct a request depending on the subdomain the request was sent to. This allows me to dynamically generate new subdomains and I don't have to constantly update the domain records.
xyz.dragdrop.site goes to files served from the /var/www/static/xyz folder
abc.dragdrop.site goes to files served from the /var/www/static/abc folder
dragdrop.site goes to the NodeJS app running on port 8080
but all of these are guided by the same wildcard CNAME rule.
It's useful to have sites on separate subdomains because they have their own root address space for file references.
That is wicked cool.
Can you please point me to resource on how to do it?
We're a place where coders share, stay up-to-date and grow their careers.
We strive for transparency and don't collect excess data.