Help with 000-default.conf files
by ozstar from LinuxQuestions.org on (#4XFVH)
Hi,
I have multiple sites in their folders in wwww/html/ and have them listed in the host file.
I am confused about the 000-default.conf file.
I have finished one with a dom and its folder but not sure what supposed to happen now! From what I have read I am not able to follow.
Is this correct?
Take the 000-default.conf file and fill it in for 1 of the sites.
Change its name to say, mysite1.conf,
then do the same again for every site I have.
1 file for each site and it is named the same as the site it represents
e.g. mysite2.conf - mysite3.conf etc.
All the files still stay in the same original sites-available Apache folder, they are not moved to the site's folder.
Then do separately....
Quote:
etc for each site then
Restart apache web server to effect the changes.
Quote:
Thanks


I have multiple sites in their folders in wwww/html/ and have them listed in the host file.
I am confused about the 000-default.conf file.
I have finished one with a dom and its folder but not sure what supposed to happen now! From what I have read I am not able to follow.
Is this correct?
Take the 000-default.conf file and fill it in for 1 of the sites.
Change its name to say, mysite1.conf,
then do the same again for every site I have.
1 file for each site and it is named the same as the site it represents
e.g. mysite2.conf - mysite3.conf etc.
All the files still stay in the same original sites-available Apache folder, they are not moved to the site's folder.
Then do separately....
Quote:
$ sudo a2dissite mysite1.conf $ sudo a2ensite mysite1.conf $ sudo a2ensite mysite2.conf |
Restart apache web server to effect the changes.
Quote:
$ sudo systemctl restart apache2 |