Answer the question
In order to leave comments, you need to log in
How to set up domains and subdomains for vhost_alias?
The actual settings are like this. And everything works with the exact match of the folder.
dnsmasq address=/.loc/127.0.0.1
hosts
<VirtualHost *:80>
ServerAlias *.loc
VirtualDocumentRoot /var/www/%0/public_html
<Directory /var/www/*.loc/>
Order allow,deny
Options -Indexes
Allow from all
AllowOverride All
</Directory>
CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question