I have 50 sites with separate databases in drupal 7 set up and manage it in terminal on centos 7 and wondering if there is a way I can avoid having to have them all listed in custom conf file because they all have the same domain name just different subdomain. Using apache in /etc/httpd/conf.d/foo.conf .. Is there a way to make it so all 50 can be sorted in one bracket of code? Considering the only difference in the directory for each is numerical. So there is foo1.foo.com foo2.foo.com and so on. Instead of having this repeated fifty times in file where I have sites foo1 to foo50:
<VirtualHost *:80>
ServerName foo1.foo.com
ServerAlias www.foo1.foo.com
ServerAdmin [email protected]
DocumentRoot "/var/www/html/foo1.foo.com"
<Directory /var/www/html/xxx.x.xxx.xxx/foo1.foo.com>
AllowOverride All
Allow from all
</Directory>
</VirtualHost>