Answer the question
In order to leave comments, you need to log in
How to add a subdomain for a site, on a server under ubuntu?
Good afternoon!
There is a server on ubuntu,
it has two sites on different domains.
For one of the sites, you need to add a subdomain so that you can host a new site there.
On the server in the /etc/apache2/sites-enabled/ directory I see two .conf files (links) - virtual hosts.
Q: What do not need to be done to add another site to the subdomain?
Which files need to be changed? And what (I understand that on different systems it can be different)?
Answer the question
In order to leave comments, you need to log in
You make a third .conf file in sites-available, and add a link to it in sites-enabled
In terms of web servers, a subdomain and another domain are pretty much the same thing.
You can add a new config to any file, or even create a new one for it (within the directories readable by Apache, of course).
The config for a subdomain does not fundamentally differ from the config of the parent domain (and indeed any) - it will just have a different name.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question