When a request is received, the server first maps it to the best matching based on the local IP address and port combination only. Non-wildcards have a higher precedence. If no match based on IP and port occurs at all, the "main" server configuration is used.
If multiple virtual hosts contain the best matching IP address and port, the server selects from these virtual hosts the best match based on the requested hostname. If no matching name-based virtual host is found, then the first listed virtual host that matched the IP address will be used. As a consequence, the first listed virtual host for a given IP address and port combination is the default virtual host for that IP and port combination.
Isso basicamente significa que o primeiro VirtualHost encontrado em httpd.conf
será usado como padrão, ou se todos os Hosts Virtuais estiverem em arquivos .conf
separados (incluídos) (o que provavelmente é o seu caso), então o primeiro alfabeticamente% o arquivo.conf
será usado.
TLDR: tente renomear o arquivo .conf
contendo o host virtual example.com
para aaa.conf
(e reinicie o httpd)