My solution was indeed correct. I just needed for the DNS to propagate, which took longer than usual.
add www alias to site subdomains
Pergunta
I want to add www alias to my subdomains such that www.subdomain.domain.com, points to the same content as subdomain.domain.com
In my DNS record I currently have the following A --mysiteip-- sudomain1 IN CNAME domain.com. subdomaine2 IN CNAME domain.com.
www IN A --mysiteip--
In my Apache config I create virtualhosts for each subdomains, wehre I have the following in each hosts : ServerName subdomain1.mysite.com ServerAlias www.subdomain1.mysite.com
When I access subdomain1.mysite.com, I get served the proper content.
I tried adding www.subdomain1 IN CNAME domain.com. in my DNS record, which does not seem to be working. Can anyone point me in the correct direction?
Solução
Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow