ServerAlias does not work
Posted: Wed Sep 10, 2014 8:26 pm
Hello!
Recently I upgraded the code of the portal and added real multilingual support. The best solution I found is a languages on subdomains, pointing to the same file structure and the same scripts to avoid unnecessary copies. I just ordered a new VPS, installed VESTA, added mysql replication.
So, I added my domain, let it be MYDOMAIN.ua, and automatically I got the alias http://www.MYDOMAIN.ua. I added en.MYDOMAIN.ua and pl.MYDOMAIN.ua to the same field immediately (it seems they are separated with a line break)
but I found that only MYDOMAIN.ua and http://www.MYDOMAIN.ua is working, en and pl shows the
I checked the web server configs:
/home/admin/conf/web/apache2.conf
http://en.MYDOMAIN.ua:8080/index.php and I got standart
Recently I upgraded the code of the portal and added real multilingual support. The best solution I found is a languages on subdomains, pointing to the same file structure and the same scripts to avoid unnecessary copies. I just ordered a new VPS, installed VESTA, added mysql replication.
So, I added my domain, let it be MYDOMAIN.ua, and automatically I got the alias http://www.MYDOMAIN.ua. I added en.MYDOMAIN.ua and pl.MYDOMAIN.ua to the same field immediately (it seems they are separated with a line break)
but I found that only MYDOMAIN.ua and http://www.MYDOMAIN.ua is working, en and pl shows the
page. I thought something is wrong and added one more, ua.MYDOMAIN.ua: the same result for all 3 subdomains.default.domain
Powered by VESTA
I checked the web server configs:
/home/admin/conf/web/apache2.conf
/home/admin/conf/web/nginx.confServerName MYDOMAIN.ua
ServerAlias http://www.MYDOMAIN.ua en.MYDOMAIN.ua pl.MYDOMAIN.ua ua.MYDOMAIN.ua
I tried to connect to the backend directly, i.e.server_name MYDOMAIN.ua http://www.MYDOMAIN.ua en.MYDOMAIN.ua pl.MYDOMAIN.ua ua.MYDOMAIN.ua;
http://en.MYDOMAIN.ua:8080/index.php and I got standart
Everything seems to be OK in config, so what is the problem?The requested URL /index.php was not found on this server. Apache/2.2.22 (Debian) Server at en.MYDOMAIN.ua Port 8080