I have purchased a domain from the registrar (godaddy) - for example mycompany.com
When this url is entered in the browser, the browser will direct the request to the configured IP address (which is a nginx reverse proxy server that is sitting in my company onpremise).
We have developed couple of api's for various departments which we want to export via the url. There are 2 options:
mycompany.com/api/departmentA, mycompany.com/api/departmentB, ...
api.departmentA.mycompany.com, api.depoartmentB.mycompany.com
I know that the 1st option does not need any change at the registrar (godaddy) or the server (nginx).
Suppose I choose the 2nd option, then I know that I need to make nginx config changes so that - based on the url the request will be directed by nginx to the appropriate server. This question is to ask - Does domain registrar (godaddy) require any configuration to allow subdomains to be routed to the same server as that configured for the domain? For example do I need to add a CNAME record for each sub domain? or does the godaddy automatically redirect any subdomain to the IP of the domain?